-
kevinpastor started following ARM VMs (Raspberry Pi emulation) and Raspberry PI in a VM using QEMU for ARM
-
Raspberry PI in a VM using QEMU for ARM
Maybe this thread could help you. I'm on 6.10 and can't get it to work. It seems like libvirt or qemu has a bug (that has been fixed in a newer version) that makes it impossible to work.
-
ARM VMs (Raspberry Pi emulation)
I'm on Unraid 6.11.5 and things have changed since @ghost82 posted his config back in November 2021. It seems like qemu-system-aarch64 is the new default. It includes raspi3b as an available machine. I was wondering if anybody got it to work with this new emulator. I'm getting an error about the property raspi3b-machine.acpi missing when trying to start the VM. I've also tried with versatile-pb, but I'm getting a similar error. After looking at some StackOverflow question, it looks like libvirt has a bug (reference), but I'm not sure if this is the cause of the error I'm getting. I'm not sure if the bugfix on that closed issue arrived on my machine. I've arrived to my current configuration by starting with the first one on this thread and reading this article. I've obtained the kernel and the dtb file from Raspberry Pi firmware repo. Here's my configuration: <?xml version='1.0' encoding='UTF-8'?> <domain type='qemu'> <name>rpi</name> <uuid>[REDACTED]</uuid> <memory unit='KiB'>262144</memory> <currentMemory unit='KiB'>262144</currentMemory> <vcpu placement='static'>4</vcpu> <os> <type arch='aarch64' machine='raspi3b'>hvm</type> <kernel>/mnt/user/domains/rpi/kernel8.img</kernel> <dtb>/mnt/user/domains/rpi/bcm2710-rpi-3-b-plus.dtb</dtb> <cmdline>root=/dev/sda2 rootfstype=ext4 rw</cmdline> <boot dev='hd'/> </os> <cpu mode='custom' match='exact' check='none'> <model fallback='forbid'>arm1176</model> </cpu> <clock offset='utc'/> <on_poweroff>destroy</on_poweroff> <on_reboot>restart</on_reboot> <on_crash>destroy</on_crash> <devices> <emulator>/usr/bin/qemu-system-aarch64</emulator> <disk type='file' device='disk'> <driver name='qemu' type='raw'/> <source file='/mnt/user/domains/rpi/2020-02-13-raspbian-buster.img'/> <backingStore/> <target dev='sda' bus='scsi'/> <address type='drive' controller='0' bus='0' target='0' unit='0'/> </disk> <controller type='pci' index='0' model='pci-root'/> <controller type='scsi' index='0' model='lsilogic'> <address type='pci' domain='0x0000' bus='0x00' slot='0x01' function='0x0'/> </controller> <interface type='bridge'> <mac address='52:54:00:ed:eb:c7'/> <source bridge='virbr0'/> <model type='virtio'/> <address type='pci' domain='0x0000' bus='0x00' slot='0x06' function='0x0'/> </interface> <graphics type='vnc' port='-1' autoport='yes' websocket='-1' listen='0.0.0.0' keymap='en-us'> <listen type='address' address='0.0.0.0'/> </graphics> <audio id='1' type='none'/> <video> <model type='cirrus' vram='16384' heads='1' primary='yes'/> <address type='pci' domain='0x0000' bus='0x00' slot='0x02' function='0x0'/> </video> </devices> </domain> Here's the full log of the failing startup: 2023-04-13 14:53:43.017+0000: starting up libvirt version: 8.7.0, qemu version: 7.1.0, kernel: 5.19.17-Unraid, hostname: Vault LC_ALL=C \ PATH=/bin:/sbin:/usr/bin:/usr/sbin \ HOME=/var/lib/libvirt/qemu/domain-26-rpi \ XDG_DATA_HOME=/var/lib/libvirt/qemu/domain-26-rpi/.local/share \ XDG_CACHE_HOME=/var/lib/libvirt/qemu/domain-26-rpi/.cache \ XDG_CONFIG_HOME=/var/lib/libvirt/qemu/domain-26-rpi/.config \ /usr/bin/qemu-system-aarch64 \ -name guest=rpi,debug-threads=on \ -S \ -object '{"qom-type":"secret","id":"masterKey0","format":"raw","file":"/var/lib/libvirt/qemu/domain-26-rpi/master-key.aes"}' \ -machine raspi3b,usb=off,dump-guest-core=off,memory-backend=ram \ -accel tcg \ -cpu arm1176 \ -m 256 \ -object '{"qom-type":"memory-backend-ram","id":"ram","size":268435456}' \ -overcommit mem-lock=off \ -smp 4,sockets=4,cores=1,threads=1 \ -uuid [REDACTED] \ -no-user-config \ -nodefaults \ -chardev socket,id=charmonitor,fd=38,server=on,wait=off \ -mon chardev=charmonitor,id=monitor,mode=control \ -rtc base=utc \ -no-shutdown \ -no-acpi \ -boot strict=on \ -kernel /mnt/user/domains/rpi/kernel8.img \ -append 'root=/dev/sda2 rootfstype=ext4 rw' \ -dtb /mnt/user/domains/rpi/bcm2710-rpi-3-b-plus.dtb \ -device '{"driver":"lsi","id":"scsi0","bus":"pci","addr":"0x1"}' \ -usb \ -blockdev '{"driver":"file","filename":"/mnt/user/domains/rpi/2020-02-13-raspbian-buster.img","node-name":"libvirt-1-storage","auto-read-only":true,"discard":"unmap"}' \ -blockdev '{"node-name":"libvirt-1-format","read-only":false,"driver":"raw","file":"libvirt-1-storage"}' \ -device '{"driver":"scsi-hd","bus":"scsi0.0","scsi-id":0,"device_id":"drive-scsi0-0-0","drive":"libvirt-1-format","id":"scsi0-0-0","bootindex":1}' \ -netdev tap,fd=39,id=hostnet0 \ -device '{"driver":"virtio-net-pci","netdev":"hostnet0","id":"net0","mac":"52:54:00:ed:eb:c7","bus":"pci","addr":"0x6"}' \ -audiodev '{"id":"audio1","driver":"none"}' \ -vnc 0.0.0.0:1,websocket=5701,audiodev=audio1 \ -k en-us \ -device '{"driver":"cirrus-vga","id":"video0","bus":"pci","addr":"0x2"}' \ -sandbox on,obsolete=deny,elevateprivileges=deny,spawn=deny,resourcecontrol=deny \ -msg timestamp=on 2023-04-13T14:53:43.082319Z qemu-system-aarch64: Property 'raspi3b-machine.acpi' not found As I'm not an expert with the setup of a VM, I'd love if anybody could help or share their current setup.
kevinpastor
Members
-
Joined
-
Last visited