View Single Post
  #4   (View Single Post)  
Old 23rd July 2008
phoenix's Avatar
phoenix phoenix is offline
Risen from the ashes
 
Join Date: May 2008
Posts: 696
Default

My notes from setting up a serial console on FreeBSD 5+ to use the remote management cards in our servers:

Enabling a Serial Console
The following will allow you to use the Tyan SMDC hardware and Tyan TSO software to remotely connect to a FreeBSD box and control it as if you were sitting in front of it. It works at the hardware level, giving you remote access to the boot sequence, BIOS messages, hardware monitoring, and a serial console (over TCP/IP).

You'll need to configure the OS to use a serial console in order to see anything once the boot loader and kernel take over. The following instructions will get things working on FreeBSD:

Edit /boot/loader.conf to enable output to serial and video consoles simultaneously:
Code:
hint.sio.1.flags="0x30" 
console="comconsole vidconsole" 
comconsole_speed="19200" 
boot_multicons="yes"
Edit /etc/make.conf to set the serial console speed (used when we recompile the boot blocks):
Code:
BOOT_COMCONSOLE_PORT=0x2F8 
BOOT_COMCONSOLE_SPEED=19200
Edit /etc/ttys to enable the serial console and set the console speed used:
Code:
ttyd1 "/usr/libexec/getty std.19200" vt100 on secure
Rebuild the boot loader
Code:
# cd /usr/src/sys/boot 
# make clean 
# make depend 
# make 
# make install
Install the new boot blocks
Note: replace ad4 with the boot device node
Code:
bsdlabel -B /dev/ad4s1
Reboot
Code:
shutdown -r now
Voila!

All output will now go to the serial console and the video console simultaneously. Once the init process starts, a separate getty process will be loaded for the serial console. Connecting via the serial console will display a login screen, same as connecting via the video console, SSH, telnet, etc.
__________________
Freddie

Help for FreeBSD: Handbook, FAQ, man pages, mailing lists.
Reply With Quote