bhyve vm-bhyve debian.raw efi disk image import on Freebsd 14.4

I have been searching around but I just haven't found the post to crack my problem yet. I need to run a Debian efi .raw image I have converted to .raw ( via qemu img).
I have made a Debian test install using the graphical installer from a .iso for debian13.4 via the vnc so I am comfortable with that part. I just haven't found the trick for booting from established .raw images. It probably has something to do with crafting the linux.conf file in /vm/.templates just right.
Also any advice on locking down VNC over SSH would be amazing if. Thank you.
I will stop here and not ask for a pony.
 
How I got Home Assistant running might give you some ideas to try.

Save this as a template, uefi-boot.conf for example:
Code:
loader="uefi"
uefi_vars="yes"
cpu=1
memory=2048M
network0_type="virtio-net"
network0_switch="public"
disk0_type="virtio-blk"
disk0_dev="sparse-zvol"
disk0_name="disk0.img"

Then create a VM using this template, or modify your existing VM. Important are loader and uefi_vars, those will get the VM to UEFI boot. You may need to add graphics="yes" because lots of Linux images nowadays don't enable a serial console out-of-the-box. Then simply dd(1) your raw image over that disk0.img "disk" that got created for the VM. Start the VM. It should boot.

Also any advice on locking down VNC over SSH would be amazing if.
Set graphics_listen to 127.0.0.1. That will bind VNC to localhost. Then use SSH port forwarding, -L 5900:localhost:5900 for example. Connect your VNC client to 127.0.0.1:5900.
 
Back
Top