{"id":563,"date":"2026-10-23T11:09:43","date_gmt":"2026-10-23T11:09:43","guid":{"rendered":"https:\/\/daq-design.co.uk\/blog\/?p=563"},"modified":"2026-10-25T11:34:20","modified_gmt":"2026-10-25T11:34:20","slug":"openbsd-v8-0-on-a-qemu-host","status":"publish","type":"post","link":"https:\/\/daq-design.co.uk\/blog\/?p=563","title":{"rendered":"OpenBSD V8.0 on a qemu host"},"content":{"rendered":"\n<figure class=\"wp-block-image size-full is-resized\"><img loading=\"lazy\" decoding=\"async\" width=\"599\" height=\"198\" src=\"https:\/\/daq-design.co.uk\/blog\/wp-content\/uploads\/2026\/10\/image-1.png\" alt=\"\" class=\"wp-image-594\" style=\"aspect-ratio:4.869918699186992;width:599px;height:auto\" srcset=\"https:\/\/daq-design.co.uk\/blog\/wp-content\/uploads\/2026\/10\/image-1.png 599w, https:\/\/daq-design.co.uk\/blog\/wp-content\/uploads\/2026\/10\/image-1-300x99.png 300w\" sizes=\"auto, (max-width: 599px) 100vw, 599px\" \/><\/figure>\n\n\n\n<p class=\"wp-block-paragraph\">I&#8217;ve recently started to look at the *BSDs again. i have a love\/hate repationship with FreeBSD which is now on a much more love basis as in the past a dirty shutdown would more often than not would lead to an fsck which screwed the whole system up. I&#8217;m not certain but I think they use a different filesystem now and it tends to be much more reliable even when it crashes in a desktop environment. Anyway, I wander as this is about OpenBSD but this issue will come back later!<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">So, first thing to do is to create a qcow2 filesystem<\/p>\n\n\n\n<p class=\"wp-block-paragraph\"><\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>qemu-img create -f qcow2 OpenBSD.img 20G<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">with that created initiate the VM<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>qemu-system-x86_64 -machine q35 -accel kvm -cpu host -m 4096 -smp 2 -vga virtio --full-screen -nic bridge,br=virbr0,model=virtio-net-pci -device intel-hda -device hda-duplex -bios \/usr\/share\/ovmf\/x64\/OVMF.fd --hda ~\/OpenBSD.img --cdrom ~\/Downloads\/install80.iso \n<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">I am not going to walk you through the installer, it is pretty intuitive for a TUI. The only change I made was to do a custom disk layout by selecting a GPT disk and then adding a root (\/) partition first then a swap partition for the remainder of the disk. If you accept the defaults, you will run out of space installing kde-plasma and other applications.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">OK, with that done you now want to add a few applications. Login as root and use the pkg_add command to install a few favorites for me this is nano and a basic plasma install.<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>pkg_add nano kde-plasmsa<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">This will take a few minutes so go and make a brew! Once complete enable the messagebus daemon and reboot<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>rcctl enable messagebus\nreboot<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">Login back in as root and make a couple of configuration changes.<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>usermod -L kde myuser<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">Replace myuser with your regular user account.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Now, without a complete debrief which will bore the hell out of you (background here) plasma will not start correctly. loads of locale errors, file handler errors, plasmashell core dumps, black screen and general plasma hell will prevent your session from running. I did ask for help on the <a href=\"https:\/\/floss.social\/deck\/@gregsie\/117478063577011346\" target=\"_blank\" rel=\"noopener\">fediverse<\/a> and a few people did give some good pointers which are incorporated in my post, especially <a href=\"https:\/\/mastodon.bsd.cafe\/@RootMoose\/117480626201320622\" target=\"_blank\" rel=\"noopener\">this<\/a> one as it verified the behaviour I was seeing and that&#8217;s normally a good thing as I wasn&#8217;t going mad!  but  it did not resolve the problem. Details at the end of this post or you&#8217;ll never forgive me for wandering again.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Now that your user is in the KDE login class, I still found the limits a bit on the low side so I increased the limits as shown below.<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>nano \/etc\/login.conf\/kde\nkde:\\\n        :datasize=8192M:\\\n        :openfiles-cur=2048:\\\n        :openfiles-max=2048:\\\n        :tc=default:<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">This should now give you sufficient file handles to run plasma. now on to the .xinitrc file.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">The following .xinitc file was put together using the pkg-install readmes for DBUS and kde-plasma in the \/usr\/local\/share\/doc\/pkg-readme directory <\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>.xinitrc\nexport LC_CTYPE=en_GB.UTF-8\nexport XDG_RUNTIME_DIR=\/tmp\/run\/$(id -u)\nif &#91; ! -d $XDG_RUNTIME_DIR ]; then\n    mkdir -m 700 -p $XDG_RUNTIME_DIR\nfi\n\nif &#91; -x \/usr\/local\/bin\/dbus-launch -a -z \"${DBUS_SESSION_BUS_ADDRESS}\" ]; then\n    eval `dbus-launch --sh-syntax --exit-with-session`\nfi\nkscreen-doctor output.556.enable\n\/usr\/local\/bin\/ck-launch-session \/usr\/local\/bin\/startplasma-x11 &gt; plasmalog.txt 2&gt;&amp;1<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">without the kscreen-doctor line this is the cause of all the nightmares I had over 2 days working on this problem. The core reason the standard script doesn&#8217;t work is that for whatever reason plasma doesn&#8217;t enable the default output device (all those no screens found errors etc) The number varies by OpenSBD version, root V normal user, if vgaaperture setting is enabled in sysctl.conf. To find your magic number just startx without the .xinitrc file and you&#8217;ll default to TWM and run the following command<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>kscreen-doctor -o\n<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">and make a note for the .xinitrc file. Now you&#8217;re ready!<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">type startx and enjoy some wonderful plasam on OpenBSD on qemu!<\/p>\n\n\n\n<figure data-wp-context=\"{&quot;imageId&quot;:&quot;6ae430323753a&quot;}\" data-wp-interactive=\"core\/image\" data-wp-key=\"6ae430323753a\" class=\"wp-block-image size-large wp-lightbox-container\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"576\" data-wp-class--hide=\"state.isContentHidden\" data-wp-class--show=\"state.isContentVisible\" data-wp-init=\"callbacks.setButtonStyles\" data-wp-on--click=\"actions.showLightbox\" data-wp-on--load=\"callbacks.setButtonStyles\" data-wp-on--pointerdown=\"actions.preloadImage\" data-wp-on--pointerenter=\"actions.preloadImageWithDelay\" data-wp-on--pointerleave=\"actions.cancelPreload\" data-wp-on-window--resize=\"callbacks.setButtonStyles\" src=\"https:\/\/daq-design.co.uk\/blog\/wp-content\/uploads\/2026\/10\/Screenshot-HP-2026-10-23-at-12.38.32-1024x576.jpg\" alt=\"\" class=\"wp-image-570\" srcset=\"https:\/\/daq-design.co.uk\/blog\/wp-content\/uploads\/2026\/10\/Screenshot-HP-2026-10-23-at-12.38.32-1024x576.jpg 1024w, https:\/\/daq-design.co.uk\/blog\/wp-content\/uploads\/2026\/10\/Screenshot-HP-2026-10-23-at-12.38.32-300x169.jpg 300w, https:\/\/daq-design.co.uk\/blog\/wp-content\/uploads\/2026\/10\/Screenshot-HP-2026-10-23-at-12.38.32-768x432.jpg 768w, https:\/\/daq-design.co.uk\/blog\/wp-content\/uploads\/2026\/10\/Screenshot-HP-2026-10-23-at-12.38.32-1536x864.jpg 1536w, https:\/\/daq-design.co.uk\/blog\/wp-content\/uploads\/2026\/10\/Screenshot-HP-2026-10-23-at-12.38.32-800x450.jpg 800w, https:\/\/daq-design.co.uk\/blog\/wp-content\/uploads\/2026\/10\/Screenshot-HP-2026-10-23-at-12.38.32.jpg 1920w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><button\n\t\t\tclass=\"lightbox-trigger\"\n\t\t\ttype=\"button\"\n\t\t\taria-haspopup=\"dialog\"\n\t\t\tdata-wp-bind--aria-label=\"state.thisImage.triggerButtonAriaLabel\"\n\t\t\tdata-wp-init=\"callbacks.initTriggerButton\"\n\t\t\tdata-wp-on--click=\"actions.showLightbox\"\n\t\t\tdata-wp-style--right=\"state.thisImage.buttonRight\"\n\t\t\tdata-wp-style--top=\"state.thisImage.buttonTop\"\n\t\t>\n\t\t\t<svg xmlns=\"http:\/\/www.w3.org\/2000\/svg\" width=\"12\" height=\"12\" fill=\"none\" viewBox=\"0 0 12 12\">\n\t\t\t\t<path fill=\"#fff\" d=\"M2 0a2 2 0 0 0-2 2v2h1.5V2a.5.5 0 0 1 .5-.5h2V0H2Zm2 10.5H2a.5.5 0 0 1-.5-.5V8H0v2a2 2 0 0 0 2 2h2v-1.5ZM8 12v-1.5h2a.5.5 0 0 0 .5-.5V8H12v2a2 2 0 0 1-2 2H8Zm2-12a2 2 0 0 1 2 2v2h-1.5V2a.5.5 0 0 0-.5-.5H8V0h2Z\" \/>\n\t\t\t<\/svg>\n\t\t<\/button><\/figure>\n\n\n\n<figure data-wp-context=\"{&quot;imageId&quot;:&quot;6ae4303237c92&quot;}\" data-wp-interactive=\"core\/image\" data-wp-key=\"6ae4303237c92\" class=\"wp-block-image size-large wp-lightbox-container\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"576\" data-wp-class--hide=\"state.isContentHidden\" data-wp-class--show=\"state.isContentVisible\" data-wp-init=\"callbacks.setButtonStyles\" data-wp-on--click=\"actions.showLightbox\" data-wp-on--load=\"callbacks.setButtonStyles\" data-wp-on--pointerdown=\"actions.preloadImage\" data-wp-on--pointerenter=\"actions.preloadImageWithDelay\" data-wp-on--pointerleave=\"actions.cancelPreload\" data-wp-on-window--resize=\"callbacks.setButtonStyles\" src=\"https:\/\/daq-design.co.uk\/blog\/wp-content\/uploads\/2026\/10\/Screenshot-HP-2026-10-23-at-12.43.31-1024x576.jpg\" alt=\"\" class=\"wp-image-573\" srcset=\"https:\/\/daq-design.co.uk\/blog\/wp-content\/uploads\/2026\/10\/Screenshot-HP-2026-10-23-at-12.43.31-1024x576.jpg 1024w, https:\/\/daq-design.co.uk\/blog\/wp-content\/uploads\/2026\/10\/Screenshot-HP-2026-10-23-at-12.43.31-300x169.jpg 300w, https:\/\/daq-design.co.uk\/blog\/wp-content\/uploads\/2026\/10\/Screenshot-HP-2026-10-23-at-12.43.31-768x432.jpg 768w, https:\/\/daq-design.co.uk\/blog\/wp-content\/uploads\/2026\/10\/Screenshot-HP-2026-10-23-at-12.43.31-1536x864.jpg 1536w, https:\/\/daq-design.co.uk\/blog\/wp-content\/uploads\/2026\/10\/Screenshot-HP-2026-10-23-at-12.43.31-800x450.jpg 800w, https:\/\/daq-design.co.uk\/blog\/wp-content\/uploads\/2026\/10\/Screenshot-HP-2026-10-23-at-12.43.31.jpg 1920w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><button\n\t\t\tclass=\"lightbox-trigger\"\n\t\t\ttype=\"button\"\n\t\t\taria-haspopup=\"dialog\"\n\t\t\tdata-wp-bind--aria-label=\"state.thisImage.triggerButtonAriaLabel\"\n\t\t\tdata-wp-init=\"callbacks.initTriggerButton\"\n\t\t\tdata-wp-on--click=\"actions.showLightbox\"\n\t\t\tdata-wp-style--right=\"state.thisImage.buttonRight\"\n\t\t\tdata-wp-style--top=\"state.thisImage.buttonTop\"\n\t\t>\n\t\t\t<svg xmlns=\"http:\/\/www.w3.org\/2000\/svg\" width=\"12\" height=\"12\" fill=\"none\" viewBox=\"0 0 12 12\">\n\t\t\t\t<path fill=\"#fff\" d=\"M2 0a2 2 0 0 0-2 2v2h1.5V2a.5.5 0 0 1 .5-.5h2V0H2Zm2 10.5H2a.5.5 0 0 1-.5-.5V8H0v2a2 2 0 0 0 2 2h2v-1.5ZM8 12v-1.5h2a.5.5 0 0 0 .5-.5V8H12v2a2 2 0 0 1-2 2H8Zm2-12a2 2 0 0 1 2 2v2h-1.5V2a.5.5 0 0 0-.5-.5H8V0h2Z\" \/>\n\t\t\t<\/svg>\n\t\t<\/button><\/figure>\n","protected":false},"excerpt":{"rendered":"<p>I&#8217;ve recently started to look at the *BSDs again. i have a love\/hate repationship with FreeBSD which is now on a much more love basis as in the past a dirty shutdown would more often than not would lead to &hellip; <a href=\"https:\/\/daq-design.co.uk\/blog\/?p=563\">Continue reading <span class=\"meta-nav\">&rarr;<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":594,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[39],"tags":[37,38,36],"class_list":["post-563","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-openbsd","tag-computing","tag-mastodon","tag-openbsd"],"_links":{"self":[{"href":"https:\/\/daq-design.co.uk\/blog\/index.php?rest_route=\/wp\/v2\/posts\/563","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/daq-design.co.uk\/blog\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/daq-design.co.uk\/blog\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/daq-design.co.uk\/blog\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/daq-design.co.uk\/blog\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=563"}],"version-history":[{"count":11,"href":"https:\/\/daq-design.co.uk\/blog\/index.php?rest_route=\/wp\/v2\/posts\/563\/revisions"}],"predecessor-version":[{"id":595,"href":"https:\/\/daq-design.co.uk\/blog\/index.php?rest_route=\/wp\/v2\/posts\/563\/revisions\/595"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/daq-design.co.uk\/blog\/index.php?rest_route=\/wp\/v2\/media\/594"}],"wp:attachment":[{"href":"https:\/\/daq-design.co.uk\/blog\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=563"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/daq-design.co.uk\/blog\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=563"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/daq-design.co.uk\/blog\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=563"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}