November 2010; last edited May 2011

With occasionally a few issues, I managed to install OpenBSD 4.7 on my Asus K51AC laptop a few weeks ago. I made some notes and wrote them down here for you.
My laptop originally had three Operating Systems installed: Microsoft Windows & (preinstalled by manufacturer), Ubuntu 10.10 and FreeBSD 8.1. Altough I didn’t had any complaints about FreeBSD, I was curious and wanted to know how OpenBSD exactly works and performs. Before installing and configuring OpenBSD I did a lot of research using manuals and guides.
Installation and booting the new system
I installed from a CD, install47.iso, which I downloaded over FTP, see this list for some FTP servers. I installed the 64-bit version, amd64.
My laptop is a multiboot system, so I had to do some things with fdisk. I never did before, but the OpenBSD documentation [1] is very clear. It’s strongly recommend to create a backup if you have some data on your PC you care about!
I’ve chosen the Auto layout option while creating partitions for OpenBSD, I think it’s fine for me. I installed all the file sets. Those sets are installed from CD[2].
After the installation was complete, I rebooted my laptop into OpenBSD. In the bootloader, only OpenBSD was listed, but I also wanted to boot Ubuntu or MicroSoft Windows. So I had to fix this. Well, the OpenBSD FAQ refers to a file called INSTALL.linux[3], which describes dual-booting with GRUB or GRUB2. Since Ubuntu 10.10 is also on my machine, I booted Ubuntu 10.10 with Super Grub Disk[4], and installed GRUB2 on the hard disk. After that, I had to create a file in /etc/grub.d on my Ubuntu installation. It looks like this:
#!/bin/sh
exec tail -n +3 $0
# This file provides an easy way to add custom menu entries. Simply type the
# menu entries you want to add after this comment. Be careful not to change
# the 'exec tail' line above.
menuentry "OpenBSD 4.7 amd64" {
set root=(hd0,2)
chainloader +1
}
Don’t forget to make the file executable, and run sudo update-grub after that to apply the changes.
Static IP address[5]
By default, the IP address is set up via DHCP. If you want to change this, you have to edit /etc/hostname.* files. If your network interface is called ale0, your may experience this:
$ cat /etc/hostname.ale0
dhcp
To change it to an static IP, change it to the following:
inet 192.168.0.8 255.255.255.0 NONE
Where 192.168.0.8 is the IP address, 255.255.255.0 the submet mask and NONE means that there isn’t a broadcast address specified. Maybe you also have to look at /etc/mygate. After this, reboot.
Installing Gnome
I installed Gnome with the pkg_add tool.
# export PKG_PATH=ftp://ftp.nluug.nl/pub/OpenBSD/4.7/packages/amd64/ # Please take a mirror near you
# pkg_add gnome-session-2.28.0p7
After this, read /usr/local/share/doc/gnome-session/README.OpenBSD for further instructions.
Ports
If you want to use the ports[6] system for some reason, execute the following commands to fetch the ports tree, and extract them to /usr/ports.
$ cd /tmp
$ ftp ftp://ftp.openbsd.org/pub/OpenBSD/4.7/ports.tar.gz
$ cd /usr
$ sudo tar xzf /tmp/ports.tar.gz
Hardware features
| Basics | |
|---|---|
| Boot with GENERIC kernel | OK |
| LAN | OK |
| Hard disk | OK |
| DVD/CD writer | OK |
| Extra features | |
| WiFi | OK |
| Sound | OK |
| Xorg | OK |
| Touchpad (mouse) | OK |
| Keyboard's hotkeys | Not tested yet |
Upgrading to 4.8
On November 1, 2010, OpenBSD 4.8 is released[7]. Of course, I wanted to upgrade. So I did. I read the Upgrade Guide[8], and performed the upgrade. It’s very simple if you know what you have to do, I had no trouble with it.
Because my laptop isn’t highly modified, so I merged /etc with a patch file. Also, I skipped the Checking the kernel step, because I am running GENERIC.
Some small tips
- Mount an OpenBSD partition on Linux?
# mount -t ufs -o ufstype=44bsd -o ro /dev/sda16 /media/ufshome/ - Burn an ISO image:
# cdio -f cd0c blank # cdio -f cd0c tao img.iso
References
- Custom fdisk(8) layout
- Choosing installation media and file sets]
- Multibooting OpenBSD/i386
- Super Grub Disk homepage
- Network configuration
- Working with ports
- The OpenBSD 4.8 Release
- Upgrade Guide: 4.7 to 4.8
About this document
At the first place, I created this document as a reference for my self. Some kind a ‘online note’. Also, I hope that it’s useful for others.
Please note that a lot of these tips are already documented by the OpenBSD team. For example, by typing man afterboot, you can find a lot of useful information.
As you can see, my English is not excellent. If you have some comments (on the document or on my level of English), feel free to contact me.