Hello friends. I need your help.
I want to insert a graphics card into the guest machine (passthru) in vm-bhyve and I have problems, the guest machine does not start.
My host machine:
So the settings of the guest machine:
Without configuration strings:
the guest machine works fine.
In the log file there is logging about an error when I passthru:
What do you advise?
I want to insert a graphics card into the guest machine (passthru) in vm-bhyve and I have problems, the guest machine does not start.
My host machine:
root@srv01:~ # uname -a
FreeBSD srv01 14.1-RELEASE-p5 FreeBSD 14.1-RELEASE-p5 GENERIC amd64
root@srv01:~ # cat /boot/loader.conf
kern.geom.label.disk_ident.enable="0"
kern.geom.label.gptid.enable="0"
cryptodev_load="YES"
zfs_load="YES"
vmm_load="YES"
nmdm_load="YES"
hw.vmm.amdvi.enable=1
pptdevs="1/0/0 1/0/1"
root@srv01:~ # pciconf -lv | grep -B 1 -A 3 NVI
ppt0@pci0:1:0:0: class=0x030000 rev=0xa2 hdr=0x00 vendor=0x10de device=0x0a65 subvendor=0x1462 subdevice=0x8094
vendor = 'NVIDIA Corporation'
device = 'GT218 [GeForce 210]'
class = display
subclass = VGA
ppt1@pci0:1:0:1: class=0x040300 rev=0xa1 hdr=0x00 vendor=0x10de device=0x0be3 subvendor=0x1462 subdevice=0x8094
vendor = 'NVIDIA Corporation'
device = 'High Definition Audio Controller'
class = multimedia
subclass = HDA
root@srv01:~ # vm passthru | grep ppt
ppt0 1/0/0 Yes GT218 [GeForce 210]
ppt1 1/0/1 Yes High Definition Audio Controller
So the settings of the guest machine:
Code:
root@srv01:~ # cat /zroot/vms/win10vm/win10vm.conf
loader="uefi"
priority="-10"
graphics="yes"
graphics_port="5910"
graphics_wait="no"
xhci_mouse="yes"
cpu="8"
cpu_sockets="1"
cpu_cores="8"
cpu_threads="1"
memory="8G"
passthru0="1/0/0=9:0"
passthru1="1/0/1=9:1"
debug="yes"
# put up to 8 disks on a single ahci controller.
# without this, adding a disk pushes the following network devices onto higher slot numbers,
# which causes windows to see them as a new interface
ahci_device_limit="8"
# ideally this should be changed to virtio-net and drivers installed in the guest
# e1000 works out-of-the-box
#network0_type="e1000"
network0_type="virtio-net"
network0_switch="public"
#disk0_type="ahci-hd"
disk0_type="nvme"
#disk0_type="virtio-blk"
disk0_name="disk0.img"
#disk0_opts="maxq=16,qsz=8,ioslots=1,sectsz=512,ser=ABCDEFGH"
#passthru0="4/0/0"
#disk1_type="ahci-cd"
#disk1_dev="custom"
#disk1_name="/zroot/vms/.iso/virtio-win.iso"
#disk1_type="nvme"
#disk1_name="disk1.img"
# windows expects the host to expose localtime by default, not UTC
utctime="no"
uuid="13f7f290-9161-11ef-b5e7-e0d55ed3490e"
network0_mac="58:9c:fc:0f:fc:51"
passthru0="1/0/0=9:0"
passthru1="1/0/1=9:1"
the guest machine works fine.
In the log file there is logging about an error when I passthru:
Oct 30 19:01:02: booting
Oct 30 19:01:02: [bhyve options: -c 8,sockets=1,cores=8,threads=1 -m 8G -Hwl bootrom,/usr/local/share/uefi-fi
rmware/BHYVE_UEFI.fd -U 13f7f290-9161-11ef-b5e7-e0d55ed3490e -S]
Oct 30 19:01:02: [bhyve devices: -s 0,hostbridge -s 31,lpc -s 4:0,nvme,/zroot/vms/win10vm/disk0.img -s 5:0,vi
rtio-net,tap0,mac=58:9c:fc:0f:fc:51 -s 9:0,passthru,1/0/0 -s 9:1,passthru,1/0/1 -s 7:0,fbuf,tcp=0.0.0.0:5910 -
s 8:0,xhci,tablet]
Oct 30 19:01:02: [bhyve console: -l com1,/dev/nmdm-win10vm.1A]
Oct 30 19:01:02: starting bhyve (run 1)
Oct 30 19:01:05: bhyve exited with status 4
Oct 30 19:01:05: destroying network device tap0
Oct 30 19:01:05: stopped
What do you advise?