Enable serial console

From TykWiki
Revision as of 02:03, 12 April 2010 by Tykling (talk | contribs) (Created page with 'A headless FreeBSD server will often need a serial console. The FreeBSD handbook has an excellent [[http://www.freebsd.org/doc/en_US.ISO8859-1/books/handbook/serialconsole-setup.…')
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigationJump to search

A headless FreeBSD server will often need a serial console. The FreeBSD handbook has an excellent [article] on it, the summary can be summarized as such: Add the following line to /boot/loader.conf:

console="comconsole"

And change the following line in /etc/ttys:

# Serial terminals
# The 'dialup' keyword identifies dialin lines to login, fingerd etc.
ttyd0   "/usr/libexec/getty std.9600"   dialup  off secure

To:

# Serial terminals
# The 'dialup' keyword identifies dialin lines to login, fingerd etc.
ttyd0   "/usr/libexec/getty std.9600"   vt100  on secure

A few things to remember:

  • The serial console allows root logins - to avoid this, remove the word secure from the line above.
  • Worth noting if the server has a normal VGA/keyboard console: The console is either VGA or serial - when you reboot after enabling the serial console you will no longer get any output on the VGA console.
  • FreeBSD defaults to a serial console port setting of 9600/8/n/1/off - that is, speed 9600, 8 bits, no parity, 1 stop bit, no flowcontrol.