Need help?

Our experts have had an average response time of 11.7 minutes in August 2021 to fix urgent issues.

We will keep your servers stable, secure, and fast at all times for one fixed price.

Install OpenBSD As Guest Operating System – using KVM virt-install

by | Mar 10, 2021

Wondering how to install OpenBSD As Guest Operating System using KVM? We can help you.

OpenBSD is a UNIX like system based on Berkeley Software Distribution (BSD). It does not compromise position on software licensing while providing quality code and documentation.

OpenBSD is also well known for its focus on security features such as Memory protection, cryptography, randomization, and much more in default base installation.

Here at Bobcares we often get requests from our customers to install OpenBSD on KVM as a part of our Server Management Services.

Today let’s see how our Support Engineers troubleshoot KVM Virtualization Problem with log files in Linux for our customers.

How to install OpenBSD as guest operating system while using KVM

Now we will see the steps which our Support Engineers follow to install OpenBSD as a guest operating system for our clients having KVM.

1. First, we will download OpenBSD iso image from the URL:

We can use the wget command or FTP command or curl command to grab the ISO image.

2. The following commands can be used to download OpenBSD v6.3 64 bit (AMD64) iso file on a CentOS 7 or Ubuntu 18.4/16.04 LTS or Debian Linux 9.x server:

# cd /var/lib/libvirt/boot/
# wget
# wget
# chown qemu:qemu install63.iso

3. To Verify SHA256 (256-bit) checksums for install63.iso we can use the following commands:

# grep install63.iso SHA256 > /tmp/x
# sha256sum -c /tmp/x
# rm /tmp/x

3. After that we can install OpenBSD 6.3 AMD64 VM on Linux KVM by typing the following command to install OpenBSD 6.3 64 bit with minimum 2GB RAM, 2 vcpu, 40GB disk space and virbr0 network interface:

# virt-install \
--name=openbsd \
--virt-type=kvm \
--memory=2048,maxmemory=4096 \
--vcpus=2,maxvcpus=4 \
--cpu host \
--os-variant=openbsd5.8 \
--cdrom=/var/lib/libvirt/boot/install63.iso \
--network=bridge=virbr0,model=virtio \
--graphics=vnc \
--disk path=/var/lib/libvirt/images/openbsd.qcow2,size=40,bus=virtio,format=qcow2

4. We can use our local vnc viewer or type the following at server itself to view installer screen:

# vncviewer

5. To configure vnc, login from another terminal over ssh and type:

# virsh dumpxml openbsd | grep vnc
<graphics type='vnc' port='5903' autoport='yes' listen=''>

Keep in mind to note down the port value (i.e. 5903).

6. We need to SSH client to set up the tunnel and a VNC client to access the remote vnc server by typing the following SSH port forwarding command from our client/desktop:

$ ssh [email protected] -L 5903:

Once we have ssh tunnel established, we can point our VNC client at our own (localhost) address and port 5903 to continue with OpenBSD 6.3 installation.

7. Now, just follow the on-screen installation instructions to install OpenBSD as per our requirements.

8. We have to ensure OpenBSD VM starts when the Linux KVM box restarts.

# virsh autostart openbsd

OpenBSD Guest Hangs At Starting tty Flags in Linux KVM – How to fix

OpenBSD version 4.5 and above made changes in the kernel which prevents it from booting OpenBSD using KVM technology.

OpenBSD 4.4 runs with mbbios enabled. However, due to some sort of bug in KVM, it does not boot and hangs while displaying a message which reads as “Starting tty flags”.

We can fix this if we can disable mpbios by using the following procedure:

 1. Boot OpenBSD With -c Option

At boot> prompt type the following command:

bsd -c
disable mpbios

Now OpenBSD will boot without any problem. Login as root and type the following command to disable mpbios permanently:

# config -ef /bsd
disable mpbios

Here we have modified the kernel to boot without mpbios support.

[Still facing issue? – We can help you]

OpenBSD Running in KVM Does Not Accept FTP Traffic – How to fix

After setting up OpenBSD under KVM at times we may face issues regarding ftp protocol. We can fix this either by configuring iptables to allow all traffic to be forwarded across the bridge from KVM gues or by disabling it on bridges.

1. Configure Iptables

Type the following command as root user on KVM host (RHEL/CentOS host system):

/sbin/iptables -I FORWARD -m physdev --physdev-is-bridged -j ACCEPT
/sbin/service iptables save
/sbin/service iptables restart
2. Disable Iptables On Bridges

This can be done by editing /etc/sysctl.conf as given below:

# vi /etc/sysctl.conf

Append the following config directives:

# Disable iptables on bridges so that ftp will work
net.bridge.bridge-nf-call-ip6tables = 0
net.bridge.bridge-nf-call-iptables = 0
net.bridge.bridge-nf-call-arptables = 0

Save and close the file. Reload the changes:

# sysctl -p

 [Still facing issue? – We can help you]


To conclude, we saw how our Support Engineers install OpenBSD as guest operating while using KVM.


Never again lose customers to poor server speed! Let us help you.

Our server experts will monitor & maintain your server 24/7 so that it remains lightning fast and secure.


var google_conversion_label = "owonCMyG5nEQ0aD71QM";


Submit a Comment

Your email address will not be published. Required fields are marked *

Privacy Preference Center


Necessary cookies help make a website usable by enabling basic functions like page navigation and access to secure areas of the website. The website cannot function properly without these cookies.

PHPSESSID - Preserves user session state across page requests.

gdpr[consent_types] - Used to store user consents.

gdpr[allowed_cookies] - Used to store user allowed cookies.

PHPSESSID, gdpr[consent_types], gdpr[allowed_cookies]


Statistic cookies help website owners to understand how visitors interact with websites by collecting and reporting information anonymously.

_ga - Preserves user session state across page requests.

_gat - Used by Google Analytics to throttle request rate

_gid - Registers a unique ID that is used to generate statistical data on how you use the website.

smartlookCookie - Used to collect user device and location information of the site visitors to improve the websites User Experience.

_ga, _gat, _gid
_ga, _gat, _gid


Marketing cookies are used to track visitors across websites. The intention is to display ads that are relevant and engaging for the individual user and thereby more valuable for publishers and third party advertisers.

IDE - Used by Google DoubleClick to register and report the website user's actions after viewing or clicking one of the advertiser's ads with the purpose of measuring the efficacy of an ad and to present targeted ads to the user.

test_cookie - Used to check if the user's browser supports cookies.

1P_JAR - Google cookie. These cookies are used to collect website statistics and track conversion rates.

NID - Registers a unique ID that identifies a returning user's device. The ID is used for serving ads that are most relevant to the user.

DV - Google ad personalisation

IDE, test_cookie, 1P_JAR, NID, DV, NID
IDE, test_cookie


These are essential site cookies, used by the google reCAPTCHA. These cookies use an unique identifier to verify if a visitor is human or a bot.