Description of problem: virt-qemu-run can not parse root dir containing space char Version-Release number of selected component (if applicable): libvirt-daemon-7.0.0-2.module+el8.4.0+9520+ef609c5f.x86_64 How reproducible: 100% Steps to Reproduce: 1.# virt-qemu-run -d -v /tmp/vm3.xml -r /tmp/test\ test/ virt-qemu-run: 78: initializing libvirt 3511 virt-qemu-run: 2380: initializing signal handlers virt-qemu-run: 2411: preparing event loop thread virt-qemu-run: 2488: opening qemu:///embed?root=/tmp/test test/ virt-qemu-run: cannot open qemu:///embed?root=/tmp/test test/: internal error: Unable to parse URI qemu:///embed?root=/tmp/test test/ 2. 3. Actual results: Expected results: Additional info:
Patch proposed upstream: https://listman.redhat.com/archives/libvir-list/2021-February/msg00772.html
Merged upstream as: 859f7e2072 qemu_shim: URI escape root directory v7.0.0-448-g859f7e2072
Verified with libvirt-daemon-7.3.0-1.module+el8.5.0+11004+f4810536.x86_64. Test steps: 1.Start a guest by 'vrit-qemu-run' with a root dir containing space char: # virt-qemu-run -v /root/vm1.xml -r /tmp/test\ test/ virt-qemu-run: 79: initializing libvirt 8910 virt-qemu-run: 2668: initializing signal handlers virt-qemu-run: 2783: preparing event loop thread virt-qemu-run: 2873: opening qemu:///embed?root=%2Ftmp%2Ftest%20test%2F virt-qemu-run: 39346: fetching guest config /root/vm1.xml virt-qemu-run: 39457: starting guest /root/vm1.xml virt-qemu-run: 1086625: guest running, Ctrl-C to stop now 2.Check the qemu process and could see the qemu process started by step 1: # ps aux | grep -i qemu-kvm qemu 8935 95.0 1.2 5397352 797228 ? SLl 04:19 0:36 /usr/libexec/qemu-kvm -name guest=vm1,debug-threads=on -S -object {"qom-type":"secret","id":"masterKey0","format":"raw","file":"/tmp/test test//lib/qemu/domain-1-vm1/master-key.aes"} -machine pc-q35-rhel8.4.0,accel=kvm,usb=off,smm=on,dump-guest-core=off,...
Since the problem described in this bug report should be resolved in a recent advisory, it has been closed with a resolution of ERRATA. For information on the advisory (virt:av bug fix and enhancement update), and where to find the updated files, follow the link below. If the solution does not work for you, open a new bug report. https://access.redhat.com/errata/RHBA-2021:4684