OpenBSD on my Soekris net4801

I finally got OpenBSD installed on my Soekris net4801. The problems I'd had was because I for some reason thought it was 9600 baud serial console, when in fact it is 19200 baud. Setting the speed wrong gives a lot of gibberish on the screen.

Here's the outline:

  1. Set up a OpenBSD PXE boot environment.
  2. Get a serial console to the Soekris.
  3. Install OpenBSD.
  4. Geek out!

OpenBSD PXE Environment

You need a server running dhcpd(8) and tftpd(8). I have my OpenBSD gateway on, and this is the relevant parts of my configuration in dhcpd.conf(5):

shared-network LAN {
    option domain-name "";
    option domain-name-servers;
    option routers;
    option ntp-servers;
    # For PXE booting clients.  Will be ignored otherwise.
    filename "pxeboot";

    # Default.
    subnet netmask {

Edit IPs to fit your network setup. I also have static leases configured for all my other clients, but they're not relevant in this context.

Setting up tftpd(8) is very easy. Make sure you have inetd(8) running, then add this line to inetd.conf(5): dgram udp wait root /usr/libexec/tftpd tftpd -ls /tftpboot

Then ‘pkill -HUP inetd’. Of course you should change to whatever is relevant in your network setup.

Create the /tftpboot directory and copy the bsd.rd and pxeboot files from the closest OpenBSD mirror into it. Then create a etc directory in /tftpboot and create the file /tftpboot/etc/boot.conf containing these three lines:

set tty com0
stty com0 19200
boot bsd.rd

That's it.

Get a Serial Console

I will describe how to do it on Mac OS X using a Keyspan USA-19HS USB→Serial adapter, if you're using something else details will certainly vary.

  1. Install Keyspan drivers.
  2. Connect cables, USB→Serial→Soekris, and connect the 1st Soekris network interface to the LAN.
  3. Open a and execute ‘sudo cu -l /dev/tty.USA19Hfa13P1.1 -s 19200’. The exact /dev/tty.USA19*.
  4. Power on the Soekris and type Control-P when prompted to enter monitor.
  5. In the Soekris monitor, enter the command ‘boot f0’ to PXE boot.

Update BIOS

You can find the BIOS files on the soekris download page, and some help for the update on the wiki. There are a few differences depending on the OS you use when updating, so be sure to read the wiki entry.

The cu(1) command is a part of Mac OS X, the lsx command is part of lrzsz, which I just installed with Homebrew.

Terminal transcript of soekris net4801 comBIOS update (using Mac OS X tools)
comBIOS ver. 1.27  20041122  Copyright (C) 2000-2004 Soekris Engineering.


0128 Mbyte Memory                        CPU Geode 266 Mhz 

Pri Mas  SanDisk SDCFH-008G              LBA Xlt 974-255-63  7824 Mbyte

Slot   Vend Dev  ClassRev Cmd  Stat CL LT HT  Base1    Base2   Int 
0:00:0 1078 0001 06000000 0107 0280 00 00 00 00000000 00000000 
0:06:0 100B 0020 02000000 0107 0290 00 3F 00 0000E101 A0000000 10
0:07:0 100B 0020 02000000 0107 0290 00 3F 00 0000E201 A0001000 10
0:08:0 100B 0020 02000000 0107 0290 00 3F 00 0000E301 A0002000 10
0:18:2 100B 0502 01018001 0005 0280 00 00 00 00000000 00000000 
0:19:0 0E11 A0F8 0C031008 0117 0280 08 38 00 A0003000 00000000 11

 5 Seconds to automatic boot.   Press Ctrl-P for entering Monitor.

comBIOS Monitor.   Press ? for help.

> download -

Start sending file using XMODEM/CRC protocol.
~+lsx -X ~/4801.bin
Sending /Users/m/4801.bin, 608 blocks: Give your local XMODEM receive command now.
Bytes Sent:  77824   BPS:1754                            

Transfer complete

File downloaded succesfully, size 608 Blocks.

> flashupdate
Updating BIOS Flash ,,,,,,,,,,,,,,,,,,,,,,,,..,,,,.. Done.

> reboot?

POST: 012345689bcefghipsajklnopqr,,,tvwxy

After the Ctrl-P to enter Monitor I only enter download -, ~+lsx -X ~/4801.bin (renamed BIOS file), flashupdate and reboot (not the ‘?’), the rest is system output.

Then it boots with a new, fresh comBIOS.

Install OpenBSD

It is very easy, just follow the instructions. In my opinion OpenBSD have the best installer of any operating system I've tried, easy, simple, fast and easily customizable if you need to.

Of course you have no use for the x*.tgz packages on a headless system with only a serial console, but I am sure you can install it if you want to.

Geek Out!

So far I have geeked out on my NET4801 kernel configuration file and pared the kernel down to 1.9 MB instead of the normal 6.5 MB.

$ uname -ap
OpenBSD 4.5 NET4801#1 i386 Geode(TM) Integrated Processor by National Semi ("Geode by NSC" 586-class)
$ ls -l /bsd
-rw-r--r--  1 root  wheel  2014242 Apr  4 18:50 /bsd

Have fun.