Setup OpenBSD

Last Updated: Tue, Dec 2, 2014
Archived content

This article is outdated and may not work correctly for current operating systems or software.

Installing OpenBSD on a VULTR instance is fairly straightforward, with a couple of minor caveats. These instructions are tested with OpenBSD 5.5 and 5.6, and should work with other versions.

For the most part, we will simply follow the OpenBSD installation guide at the official OpenBSD website.

The only issue you're likely to encounter is the static route required if you choose to use VULTR's nameservers, or if you use DHCP. I recommend against using DHCP on custom OS's in VULTR's environment, simply because it requires extra configuration steps, which defeats the purpose of DHCP in my opinion.

You'll need a browser that can run VULTR's noVNC console.

It is recommended to review this Vultr doc before proceeding.

The steps required for OpenBSD are similar to the instructions for FreeBSD at the above link. We'll cover the differences below.

  1. On VULTR's Deploy screen, choose a 64-bit VULTR plan that meets your needs. A 64-bit plan is required for a custom OS at the time of this writing. You are free to install i386 arch OpenBSD on your 64-bit instance if you want to make more efficient use of RAM. Select "Custom" for your OS.

  2. Find the URL of the OpenBSD installation media of your choice from the mirrors listed in the official OpenBSD installation guide. Try to pick a mirror close to your datacenter. The URL should end in installXX.iso or cdXX.iso, where XX is the OpenBSD version of your choice. Use this URL in VULTR's Upload/Manage ISO feature, which appears when you select "Custom" OS.

  3. Spin up your VM with the "Place Order" button. Don't worry about providing an SSH key; this is not supported for a custom OS. Select "My Servers->Manage->IPv4" and make a note of your IP address, subnet mask, and gateway. Then select "View Console", where you should see the OpenBSD installer booting.

  4. When the installer is booted, hit Ctrl-Z or Ctrl-C to get a shell prompt. In the shell, add your static route. OpenBSD differs from FreeBSD in that you'll use your IP address instead of the interface name. This allows you to use the VULTR nameserver,

    # route add -net -iface <your IP address>
  5. Foreground the OpenBSD installer and hit Enter, or run install (or upgrade if you are upgrading an existing installation). Refer to the official OpenBSD install documentation for the rest of the installation.

  6. After the install, you will get a shell prompt. Now you will want to configure your network interface to set up the static route on boot. Edit /mnt/etc/hostname.vio0, and add the following line at the end. If you forget this step, you can edit /etc/hostname.vio0 after booting into the new system.

    !route add -net -iface <your IP address>
  7. Reboot and enjoy.

Keep in mind that, as a security-focused project, the OpenBSD developers do not encourage virtualization. Do not allow the fact that you're running OpenBSD lull you into a false sense of security. That being said, an inexpensive KVM instance can be a good platform to get some experience with OpenBSD and have fun in the process. I have yet to run into problems related to virtualization in VULTR's environment.

Want to contribute?

You could earn up to $600 by adding new articles.