From nobody Tue Jul 16 15:56:10 2024 X-Original-To: virtualization@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WNkFV4pgCz5RWVv for ; Tue, 16 Jul 2024 15:56:14 +0000 (UTC) (envelope-from polarian@polarian.dev) Received: from mail.polarian.dev (mail.polarian.dev [IPv6:2001:8b0:57a:2385::8]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 4WNkFT6SyXz4ZBp for ; Tue, 16 Jul 2024 15:56:13 +0000 (UTC) (envelope-from polarian@polarian.dev) Authentication-Results: mx1.freebsd.org; dkim=pass header.d=polarian.dev header.s=polarian header.b=kR3w++m1; dmarc=pass (policy=quarantine) header.from=polarian.dev; spf=pass (mx1.freebsd.org: domain of polarian@polarian.dev designates 2001:8b0:57a:2385::8 as permitted sender) smtp.mailfrom=polarian@polarian.dev Received: from PolarianBSD (_gateway [192.168.2.1]) by mail.polarian.dev (Postfix) with ESMTPSA id 20C7D10A1554 for ; Tue, 16 Jul 2024 15:56:11 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=simple/relaxed; d=polarian.dev; s=polarian; t=1721145371; bh=0yuIB25D2zmeKltMZRuCTgYQD65Lk86Mju6HiW5k2ts=; h=Date:From:To:Subject:In-Reply-To:References; b=kR3w++m1Uuud9R/BZeayX0cdPYbPjZ7CgXC4OJ1K+8s2KFKsRd+F4MBgLMqUkxkO8 FZ0O/53MBsIV0oD+Va7WHwY6N1ncNiwRddjN4HPRMCt7m/j0WchAViNWBUG/jkPCPp YkzwkejRvTjXpV9cNq1JJ01MODavuSEJvqQBaXMA= Date: Tue, 16 Jul 2024 16:56:10 +0100 From: Polarian To: virtualization@freebsd.org Subject: Re: nmdm issues with bhyve Message-ID: <20240716165610.5c0066fb@PolarianBSD> In-Reply-To: <2137018B-1F61-423F-B17A-6EF8CC60314F@iitbombay.org> References: <20240716153851.60c1ea61@PolarianBSD> <2137018B-1F61-423F-B17A-6EF8CC60314F@iitbombay.org> X-Mailer: Claws Mail 3.20.0 (GTK+ 2.24.33; amd64-portbld-freebsd14.0) List-Id: Discussion List-Archive: https://lists.freebsd.org/archives/freebsd-virtualization List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: freebsd-virtualization@freebsd.org Sender: owner-freebsd-virtualization@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-Spamd-Bar: --- X-Spamd-Result: default: False [-3.50 / 15.00]; NEURAL_HAM_MEDIUM(-1.00)[-1.000]; NEURAL_HAM_LONG(-1.00)[-1.000]; NEURAL_HAM_SHORT(-1.00)[-1.000]; DMARC_POLICY_ALLOW(-0.50)[polarian.dev,quarantine]; MID_RHS_NOT_FQDN(0.50)[]; R_SPF_ALLOW(-0.20)[+ip6:2001:8b0:57a:2385::8]; R_DKIM_ALLOW(-0.20)[polarian.dev:s=polarian]; MIME_GOOD(-0.10)[text/plain]; RCVD_TLS_ALL(0.00)[]; TO_MATCH_ENVRCPT_ALL(0.00)[]; RCPT_COUNT_ONE(0.00)[1]; DKIM_TRACE(0.00)[polarian.dev:+]; FROM_HAS_DN(0.00)[]; ASN(0.00)[asn:20712, ipnet:2001:8b0::/32, country:GB]; ARC_NA(0.00)[]; TO_DN_NONE(0.00)[]; FROM_EQ_ENVFROM(0.00)[]; RCVD_COUNT_ONE(0.00)[1]; PREVIOUSLY_DELIVERED(0.00)[virtualization@freebsd.org]; RCVD_VIA_SMTP_AUTH(0.00)[]; MLMMJ_DEST(0.00)[virtualization@freebsd.org]; MIME_TRACE(0.00)[0:+] X-Rspamd-Queue-Id: 4WNkFT6SyXz4ZBp Hello, I will reply to both emails here. Mario: > In short words,what's nmdm used for ? thanks. nmdm(4) (null modem) allows to connect two devices through serial communication. The nmdm device simply allows two devices, A and B to pass data to one another. What I am trying to do is get bhyve to redirect the output from com1 to a nmdm device, which would allow me to cu to read the output from com1 on the host (instead of using stdio or vnc). Therefore allowing configuration of the virtual machine over ssh instead of having to use vnc which has security implications when used remotely. For more information on null modem see the man page, or [1]. Bakul: > I use the B device here, as in /dev/nmdm3B I do not believe this would make a difference but I will give it a go anyways, thanks :) > They seem to get generated on demand. e.g if you do >=20 > cu -l /dev/nmdm3A >=20 > Both A and B devices will get generated. Yes, nmdm(4) already states this: "The nmdm driver implements =E2=80=9Con-demand device creation=E2=80=9D so = simply accessing a given instance in /dev will create it." However that is not the issue, the issue is that bhyve SHOULD have created it, if there is data from com1 going to a nmdm device as specified in the bhyve command, then the devices should be appearing, but they are not, that is what I can't figure out. Thank you, --=20 Polarian GPG signature: 0770E5312238C760 Jabber/XMPP: polarian@icebound.dev [1] https://en.wikipedia.org/wiki/Null_modem