How can I setup Serial-Over-Lan (SOL) on FreeBSD with a SuperMicro X9-SCM-F motherboard? There are a few resources out there but they contradict each other, are unclear, and don’t actually allow me to get SOL working past the boot loader.
How can I setup Serial-Over-Lan (SOL) on FreeBSD with a SuperMicro X9-SCM-F motherboard? There are a few resources out there but they contradict each other, are unclear, and don’t actually allow me to get SOL working past the boot loader.
This was originally tested on FreeBSD 10.0-RELEASE, but will likely work on FreeBSD 9.x, and is known to work up to at least 13.0-RELEASE. Different motherboards may have slightly different configuration, but this may still prove a useful reference.
BIOS Configuration
Open the BIOS settings and navigate to “Advanced → Serial Port Console Redirection” and ensure “SOL Console Redirection” is set to “Enabled” (you do not need to enable COM1 or COM2 or Out-of-Band management).
Open the “SOL Console Redirection Settings” and configure as follows:
You should only have to change “Terminal Type” to VT-UTF8 and “Bits per second” to 115200 to achieve the above configuration. Not changing the Terminal Type resulting in some issues when copy-pasting into the SOL session.
FreeBSD Configuration
Boot FreeBSD and add the following lines to
/boot/loader.conf
:0x3E8
is the port for COM3 (“SOL” in the BIOS settings). You can discover the possible values by inspectingdmesg
like so:If you wish to be get a login prompt (and thus be able to login) via SOL, edit
/etc/ttys
changing the following line:to
We change
ttyu2
because this corresponds to COM3 (since TTYs are zero-indexed and COM is not) which is what our SOL uses. If you don’t need to login (because, for example, you just need to enter a password for GELI during boot), you can leave/etc/ttys
as-is.Notes
Above is the minimum required to get this working. Various people (see “References” below) recommended or stated that they “needed” a slew of other settings which, for me, were not needed but did not impair SOL functionality either. Again, the following should not be needed, and is included for reference only.
In
/boot/loader.conf
:In
/boot.config
:or
Despite what the FreeBSD handbook seems to say, you should not need to compile a custom kernel.
References
Please note that many of these are wrong, out-of-date, or overzealous in setting options not actually needed. Despite that, they were helpful in arriving at the final implementation described above.
Not enough rep to comment on the answer above, so:
I run FreeBSD 9.2 and Andrew's configuration above enables SOL on COM 3 for me on X8SIL-F / X8SIE-F, from BIOS to login prompt. It is completely based on his above answer but tested on 9.2 with GENERIC kernel--thank you, Andrew!
A few notes:
It seems to be the order of 'comconsole' or 'vidconsole' in the line "console=..." in
/boot/loader.conf
, that determines which becomes the boot console proper, and thus where the console messages (and single user prompt) appears. I could not get/boot.config
to influence that, neither probing for keyboard, -P, or double console, -D, seeboot(8)
, had any effect--so I do not have a/boot.config
.The X8SIL's BIOS settings for COM3 were spot on. I only changed the terminal type to VT-UTF8 as suggested, even though ANSI and VT100 works, too--I tested them.
It was not necessary for me to set the irq for
uart2
in/boot/loader.conf
. For the flags, seeuart(8)
.In
/dev/ttys
, I setttyu2
to 'insecure', because I don't want root to login over SOL (single user mode will still get you root). I suggest to set the console insecure as well.If someone's still unable to get the SOL output - reset the BMC, this might be the case.
Not enough rep to comment, but this saved my day.
I did however need to add these to
/boot/device.hints
as without it, FreeBSD does not see the uart2 device for the SOL console. I have a Supermicro X9SRi-3F, and the SOL console runs on COM3. There is no way to change this, even if you disable the other two onboard serial ports.I had to add these to fully unlock serial console support on FreeBSD 12.2