the OpenBSD on Virtual PC project
dedicated to getting a full-bodied OpenBSD flavor out of Virtual PC

table of contents


background

Virtual PC provides a great solution for those needing more machines, but wanting less baggage. With OpenBSD not officially supported under Virtual PC, this frequent traveller's solution used to be carrying two laptops. Nowadays, unless the ability to perform traffic analysis with OpenBSD kernel-land is a requirement, there is no reason Virtual PC cannot be as effective a substitute for real Intel hardware with OpenBSD as it is with Windows for client-side applications.

For the most part, OpenBSD/i386 works very well with Virtual PC with little modification from the original OpenBSD codebase. So long as you're running version 5 or up, you should be able to grab a floppy image, boot, and install without any patching, even over the network. Bootable Virtual PC hard disk images are provided below to facilitate network installations and automate the installation of Virtual PC fixes.

Despite minor issues, what's posted here is both usable and functional. Improvements will continue to be posted here as issues are resolved, or until the project ceases to be useful or interesting. Though this page will focus on OpenBSD, experimentation has led to limited support and information below for FreeBSD, Solaris, and other Unix.


installation

The following directions are for OpenBSD and Virtual PC on the Macintosh, and assume familiarity with the installation and use of both. Note that if you have OpenBSD CDs, you may boot off the i386 CD, perform the installation (don't configure the network if using Virtual PC 4), and use the source patches below to fix the network and/or floppy disk drivers. Please refer to either the OpenBSD/i386 installation documentation or the Virtual PC documentation in case of questions, as documenting the installation of either is beyond the scope of this project.

  1. Grab the latest installer hard disk image from the files section of this page.
  2. Create a Virtual PC hard disk image file of the size you want your OpenBSD hard disk to be, at least a gigabyte if you want to unpack the source tree and have a usable system. However, you can get away with a hard disk as small as 300MB or so for a complete installation.
  3. Create a Virtual PC configuration with the new hard disk image as the secondary IDE drive and the installer image as the primary.
  4. The installer hard disk image will boot a modified ramdisk kernel with the network and floppy drivers fixed. Install OpenBSD any available way onto wd1 just like it was attached to a real piece of Intel hardware. Do not reboot when finished.
  5. Make sure that the new root device is unmounted with umount /mnt.
  6. After installation finishes, mount /dev/wd0a /mnt and then run /mnt/postinstall.sh. On OpenBSD 3.4 below, mount /dev/wd0a /mnt2 and run /mnt2/postinstall.sh. You must mount wd0a on /mnt and your root must be (unmounted) on wd1a because postinstall.sh is not that bright. With OpenBSD 3.2 and 3.3, you may have to umount /dev/wd1a first. /mnt/postinstall.sh will install fixed kernels and synctime, configure X11, fix /etc/rc.local and /etc/fstab, and puts everything else in /vpc for later use.
  7. Shut down the virtual machine ... you may now set up the new OpenBSD root device as the primary IDE drive and trash the installer image. Welcome to OpenBSD: The proactively secure Unix-like operating system.

files

source diffs

XFree86 config files

ultra-lightweight kernel config files

binaries


other unix

FreeBSD

I have noticed no problems running any version of FreeBSD with any recent version of Virtual PC.

Solaris

Solaris refuses to recognize the Virtual PC CPU on versions 5 and up, however a workaround exists (see Amit Singh's site below). Solaris 2.6 through 8 run just fine on Virtual PC 4 and 5, however the virtual ethernet card has been somehow broken in Virtual PC 6.
OpenStep

NEXTstep and OpenStep work just fine on Virtual PC 4 and 5, however, just like with Solaris, support for the virtual ethernet card has been broken under Virtual PC 6.


screenshots



known issues

resolved
fixable or hopefully fixable probably unfixable, except by the vendor

project history

[02/03/01] emulated de NIC working from David Hornsby's NetBSD 1.3.2 hacks
[02/07/01] XFree86 and MAC spoofing working on the virtual machine
[03/02/01] Stephane Matis de hack discovered
[03/05/01] minimal kernel options process-of-elimination complete
[04/20/01] finally got this page up, with hard disk image and synctime
[05/05/01] caps lock key fix and button chord workaround
[05/22/01] installation images capable of network installations without CDs
[06/15/01] support for OpenBSD 2.9
[07/18/01] floppy driver fix posted
[11/24/01] OpenBSD 3.0 support, make workaround, shared IP mode, new installers
[12/11/01] Virtual PC 5.0 testing update
[02/05/02] Solaris and FreeBSD support, new screenshot
[07/25/02] OpenBSD 3.1 support
[11/12/02] OpenBSD 3.2 support
[02/20/03] Virtual PC acquired from Connectix by Microsoft
[05/27/03] OpenBSD 3.3 support
[08/01/03] more info on other Unix
[12/09/03] OpenBSD 3.4 support
[12/29/03] Solaris workaround
[08/08/04] OpenBSD 3.5 support ... sorry for the delay!


prospective projects

The following are listed in likely order of precedence, but I will likely not be getting to these anytime soon. Please feel free to chip in any free time; any help is appreciated.

credits


links


contact info

this page compiled by
peter bartoli (
pgp key)
and last updated 8/6/04