guest - flak
Flaakle

OpenBSD and VMWare Player

First off, don’t use VirtualBox. It’s terrible for running OpenBSD. I’ve had zero problems with VMWare Player. I installed using an OS type of FreeBSD, though it doesn’t seem to matter much. (This post was written against Player 4. Player 5 may sort out the networking issues. It provides a few more options in the machine configurator.)

First order of business, install the vmwh package and configure xterm to use the right clipboard. Put XTerm*selectToClipboard:true in .Xdefaults. I also put xrandr -s 1366x768 in .xinitrc. It makes the VMWare window fit nicely within my laptop screen (full screen mode is annoying to switch in and out of) and also fits two 84 column xterms side by side on the inside.

Second, sort out networking. I use three network interfaces, all em. vic should work, but it’s more fiddling to set up. I have one guest interface bridged to each host interface (wired and wireless) and one private host only interface. This takes a little work.

Out of the box, Player lacks the tools necessary to setup or configure two bridge interfaces. Run the setup program again on the command line, passing ”/e somefolder”. This extracts all the files. Look for a program named vmnetcfg.exe and copy it to the installation folder under Program Files. Run it. By default, VMWare is configured to automatically select the interface to bridge to. I found this somewhat unreliable, as it seemed to always pick the VirtualBox interface (obvious alternative solution: delete VirtualBox), and therefore passed no traffic. Manually set it to the wired interface. Add a new interface, vmnet2, and bridge that to the wireless interface. Back in Player, edit the VM config and add a new interface attached to vmnet2 (type host only, whatever). Save and quit. Now find the vmx file in the VM directory and edit with a text editor. Find the ethernet1 device section or whatever it is, change the connectionType to custom, and delete the IP address. Now when you start the VM again, you should have two bridged interfaces. VMWare has some magic rules about how interfaces are numbered, for example trying to alter vmnet8 and make it bridged doesn’t appear to work.

At this point, you can use OpenBSD to trunk the interfaces or manage them manually. One of the cool things you can do, in my opinion, is have OpenBSD continue using the wireless network while Windows by default switches to wired. I did this briefly to run some diagnostics between two internet uplinks.

I also run samba bound to a third host only interface to export my home directory, but without making it available to the whole network. By default, I think everything is configured to export home directories, you just need to run smbpasswd and add a username/password combo.

Finally, if the host is a laptop that you’re going to suspend, this messes with the guest’s clock because it doesn’t notice the missing time. For now, this requires a patch, which will sync the guest clock to whatever the host clock is if they drift more than a minute apart.

Posted 2012-08-21 21:46:25 by tedu Updated: 2013-03-15 02:28:03
Tagged: computers openbsd review software