Date: Thu, 3 Oct 2013 19:00:28 -0700 From: Craig Rodrigues <rodrigc@FreeBSD.org> To: Peter Grehan <grehan@freebsd.org> Cc: "freebsd-virtualization@freebsd.org" <freebsd-virtualization@freebsd.org> Subject: Re: Problems with missing ttyv devices in BHyve? Message-ID: <CAG=rPVcjg17OnjLmdDspsMp%2B70dBWaxnDrsqENfSeONKdP7ThA@mail.gmail.com> In-Reply-To: <522B5010.1080105@freebsd.org> References: <CAG=rPVfLMvqfbPvdu2kOzOVyBNBF7GjGRk8oN3E3EnjadX_ZnQ@mail.gmail.com> <522B5010.1080105@freebsd.org>
next in thread | previous in thread | raw e-mail | index | archive | help
On Sat, Sep 7, 2013 at 9:10 AM, Peter Grehan <grehan@freebsd.org> wrote: > Hi Craig, > > > Does anyone have any ideas what the fix for this should be? >> > > You'll have to edit the /etc/ttys file and > > -ttyu2 "/usr/libexec/getty std.9600" dialup off secure > +ttyu2 "/usr/libexec/getty std.9600" vt100 on secure > > bhyve is ttyu2 rather than ttyu0 since it emulates a PCI serial port. > > Maybe this could go into the FreeNAS repo - I've never really understood > the aversion to having logins open on the serial ports by default. Seems a > relic of 1980's Unix dialup modems. > > Thanks Peter, thats worked. With some other changes that I have done, I have been able to successfully install and boot the latest FreeNAS code inside BHyve. It's very cool, and extremely useful for testing FreeNAS. A few questions for you. (1) I want to get the same FreeNAS image working inside Bhyve and on real hardware. In the source code for /sbin/init, when it parses /etc/ttys, if the entry does not exist, it prints out an error message about not being able to find the tty entry to open it. Do you know if there is a way to specify an entry for /dev/ttyu2, only if it exists, and not print out an error message otherwise? That way, I can get the same image to boot on real hardware, which has ttyv console devices, but does not have /dev/ttyu2, and also in BHyve, and /sbin/init won't print any errors. (2) Is it possible to connect to the console of the BHyve VM via /dev/ttyu2 or some other mechanism? I would like to be able to connect to the BHyve VM and use something like Expect or py-expect to execute console commands in the VM, for automated testing. Thanks. -- Craig
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?CAG=rPVcjg17OnjLmdDspsMp%2B70dBWaxnDrsqENfSeONKdP7ThA>