You are not logged in.
Pages: 1
I have a qemu virtual machine which runs in libvirt user session (qemu:///session).
I want the sound from this VM to play on the host without the need to have virt-viewer window open.
By default, libvirt sends audio through spice to virt-viewer on the host. This means that, from host OS point of view, the sound is actually being played by virt-viewer. While virt-viewer is running, the sound plays, but as soon as I close the libvirt window the sound stops even though the VM is still running in the background and producing sound.
In my domain.xml I've changed
<audio id='1' type='spice'/>to
<audio id='1' type='pulseaudio'/>But when I try to start the VM, I get
qemu-system-x86_64: XDG_RUNTIME_DIR not set
Why does this happen? If I look in /proc/xxxx/environ for virtqemud, the XDG_RUNTIME_DIR is there and its value is correct.
Last edited by bachtiar (2026-01-21 20:08:19)
Offline
I've worked around by switching audio to pipewire on the host, and using
<audio id='1' type='pipewire'/>.
Offline
Pages: 1