Hello, I’m having issues with audio through Looking Glass B6. I can pass sound from my guest OS to my host with the build-in viewer in virt-manager, but once I start the LG client and the virt-manager viewer disconnects, everything works (video, mouse & keyboard) except sound.
I believe I followed the LG installation correctly; my guest sound card is configured as it appears in the guide, except a pci address is specified. I’ve tried removing the address line, but it is added back each time I start the VM. If this is causing the issue, how can I stop the line from being added?
<sound model='ich9'>
<audio id='1'/>
<address type='pci' domain='0x0000' bus='0x00' slot='0x1b' function='0x0'/>
</sound>
<audio id='1' type='spice'/>
I’ve also tried this with Windows 11 and still had no audio, so I assume its something about my host OS. Even though LG is functional, the host log contains many errors, so there might be something wrong with the IVSHMEM setup. Any troubleshooting tips, ideas on what might be wrong, or possible solutions are greatly appreciated. Some relevant info about my setup/host OS and the XML for my Windows 10 VM is below:
Host OS: Kubuntu 22.04
KDE Plasma 5.24.7
Linux Kernel 6.5.0
Pulse Audio 15.99.1
Host GPU: AMD RX 550
Looking Glass Host/Client B6
Guest OS: Windows 10 22H2
Passthrough GPU: Nvidia GTX 1660 TI
Nvidia Drivers 537.42
Virt-IO Drivers 0.1.240
Guest XML
<domain type="kvm">
<name>win10-offline</name>
<uuid>3cf52937-85f6-4943-b403-2c2dc9bc5196</uuid>
<metadata>
<libosinfo:libosinfo xmlns:libosinfo="http://libosinfo.org/xmlns/libvirt/domain/1.0">
<libosinfo:os id="http://microsoft.com/win/10"/>
</libosinfo:libosinfo>
</metadata>
<memory unit="KiB">25391104</memory>
<currentMemory unit="KiB">25391104</currentMemory>
<vcpu placement="static">12</vcpu>
<cputune>
<vcpupin vcpu="0" cpuset="0"/>
<vcpupin vcpu="1" cpuset="1"/>
<vcpupin vcpu="2" cpuset="2"/>
<vcpupin vcpu="3" cpuset="3"/>
<vcpupin vcpu="4" cpuset="4"/>
<vcpupin vcpu="5" cpuset="5"/>
<vcpupin vcpu="6" cpuset="12"/>
<vcpupin vcpu="7" cpuset="13"/>
<vcpupin vcpu="8" cpuset="14"/>
<vcpupin vcpu="9" cpuset="15"/>
<vcpupin vcpu="10" cpuset="16"/>
<vcpupin vcpu="11" cpuset="17"/>
</cputune>
<os>
<type arch="x86_64" machine="pc-q35-6.2">hvm</type>
<loader readonly="yes" type="pflash">/usr/share/OVMF/OVMF_CODE_4M.fd</loader>
<nvram>/var/lib/libvirt/qemu/nvram/win10-offline_VARS.fd</nvram>
</os>
<features>
<acpi/>
<apic/>
<hyperv mode="custom">
<relaxed state="on"/>
<vapic state="on"/>
<spinlocks state="on" retries="8191"/>
<vendor_id state="on" value="123456789123"/>
</hyperv>
<kvm>
<hidden state="on"/>
</kvm>
<vmport state="off"/>
<ioapic driver="kvm"/>
</features>
<cpu mode="host-passthrough" check="none" migratable="on">
<topology sockets="1" dies="1" cores="6" threads="2"/>
</cpu>
<clock offset="localtime">
<timer name="rtc" tickpolicy="catchup"/>
<timer name="pit" tickpolicy="delay"/>
<timer name="hpet" present="no"/>
<timer name="hypervclock" present="yes"/>
</clock>
<on_poweroff>destroy</on_poweroff>
<on_reboot>restart</on_reboot>
<on_crash>destroy</on_crash>
<pm>
<suspend-to-mem enabled="no"/>
<suspend-to-disk enabled="no"/>
</pm>
<devices>
<emulator>/usr/bin/qemu-system-x86_64</emulator>
<disk type="file" device="disk">
<driver name="qemu" type="qcow2"/>
<source file="/home/[user]/vms/win10-gaming-offline/win10-os.qcow2"/>
<target dev="sda" bus="sata"/>
<boot order="1"/>
<address type="drive" controller="0" bus="0" target="0" unit="0"/>
</disk>
<controller type="usb" index="0" model="qemu-xhci" ports="15">
<address type="pci" domain="0x0000" bus="0x01" slot="0x00" function="0x0"/>
</controller>
<controller type="pci" index="0" model="pcie-root"/>
<controller type="pci" index="1" model="pcie-root-port">
<model name="pcie-root-port"/>
<target chassis="1" port="0x10"/>
<address type="pci" domain="0x0000" bus="0x00" slot="0x02" function="0x0" multifunction="on"/>
</controller>
<controller type="pci" index="2" model="pcie-root-port">
<model name="pcie-root-port"/>
<target chassis="2" port="0x11"/>
<address type="pci" domain="0x0000" bus="0x00" slot="0x02" function="0x1"/>
</controller>
<controller type="pci" index="3" model="pcie-root-port">
<model name="pcie-root-port"/>
<target chassis="3" port="0x12"/>
<address type="pci" domain="0x0000" bus="0x00" slot="0x02" function="0x2"/>
</controller>
<controller type="pci" index="4" model="pcie-root-port">
<model name="pcie-root-port"/>
<target chassis="4" port="0x13"/>
<address type="pci" domain="0x0000" bus="0x00" slot="0x02" function="0x3"/>
</controller>
<controller type="pci" index="5" model="pcie-root-port">
<model name="pcie-root-port"/>
<target chassis="5" port="0x14"/>
<address type="pci" domain="0x0000" bus="0x00" slot="0x02" function="0x4"/>
</controller>
<controller type="pci" index="6" model="pcie-root-port">
<model name="pcie-root-port"/>
<target chassis="6" port="0x15"/>
<address type="pci" domain="0x0000" bus="0x00" slot="0x02" function="0x5"/>
</controller>
<controller type="pci" index="7" model="pcie-root-port">
<model name="pcie-root-port"/>
<target chassis="7" port="0x16"/>
<address type="pci" domain="0x0000" bus="0x00" slot="0x02" function="0x6"/>
</controller>
<controller type="pci" index="8" model="pcie-root-port">
<model name="pcie-root-port"/>
<target chassis="8" port="0x17"/>
<address type="pci" domain="0x0000" bus="0x00" slot="0x02" function="0x7"/>
</controller>
<controller type="pci" index="9" model="pcie-root-port">
<model name="pcie-root-port"/>
<target chassis="9" port="0x18"/>
<address type="pci" domain="0x0000" bus="0x00" slot="0x03" function="0x0" multifunction="on"/>
</controller>
<controller type="pci" index="10" model="pcie-root-port">
<model name="pcie-root-port"/>
<target chassis="10" port="0x19"/>
<address type="pci" domain="0x0000" bus="0x00" slot="0x03" function="0x1"/>
</controller>
<controller type="pci" index="11" model="pcie-root-port">
<model name="pcie-root-port"/>
<target chassis="11" port="0x1a"/>
<address type="pci" domain="0x0000" bus="0x00" slot="0x03" function="0x2"/>
</controller>
<controller type="pci" index="12" model="pcie-root-port">
<model name="pcie-root-port"/>
<target chassis="12" port="0x1b"/>
<address type="pci" domain="0x0000" bus="0x00" slot="0x03" function="0x3"/>
</controller>
<controller type="pci" index="13" model="pcie-root-port">
<model name="pcie-root-port"/>
<target chassis="13" port="0x1c"/>
<address type="pci" domain="0x0000" bus="0x00" slot="0x03" function="0x4"/>
</controller>
<controller type="pci" index="14" model="pcie-root-port">
<model name="pcie-root-port"/>
<target chassis="14" port="0x1d"/>
<address type="pci" domain="0x0000" bus="0x00" slot="0x03" function="0x5"/>
</controller>
<controller type="pci" index="15" model="pcie-root-port">
<model name="pcie-root-port"/>
<target chassis="15" port="0x1e"/>
<address type="pci" domain="0x0000" bus="0x00" slot="0x03" function="0x6"/>
</controller>
<controller type="pci" index="16" model="pcie-to-pci-bridge">
<model name="pcie-pci-bridge"/>
<address type="pci" domain="0x0000" bus="0x0a" slot="0x00" function="0x0"/>
</controller>
<controller type="sata" index="0">
<address type="pci" domain="0x0000" bus="0x00" slot="0x1f" function="0x2"/>
</controller>
<controller type="virtio-serial" index="0">
<address type="pci" domain="0x0000" bus="0x02" slot="0x00" function="0x0"/>
</controller>
<serial type="pty">
<target type="isa-serial" port="0">
<model name="isa-serial"/>
</target>
</serial>
<console type="pty">
<target type="serial" port="0"/>
</console>
<channel type="spicevmc">
<target type="virtio" name="com.redhat.spice.0"/>
<address type="virtio-serial" controller="0" bus="0" port="1"/>
</channel>
<input type="mouse" bus="virtio">
<address type="pci" domain="0x0000" bus="0x09" slot="0x00" function="0x0"/>
</input>
<input type="keyboard" bus="virtio">
<address type="pci" domain="0x0000" bus="0x08" slot="0x00" function="0x0"/>
</input>
<input type="keyboard" bus="ps2"/>
<input type="mouse" bus="ps2"/>
<graphics type="spice" autoport="yes">
<listen type="address"/>
<gl enable="no"/>
</graphics>
<sound model="ich9">
<audio id="1"/>
<address type="pci" domain="0x0000" bus="0x00" slot="0x1b" function="0x0"/>
</sound>
<audio id="1" type="spice"/>
<video>
<model type="vga" vram="16384" heads="1" primary="yes"/>
<address type="pci" domain="0x0000" bus="0x00" slot="0x01" function="0x0"/>
</video>
<hostdev mode="subsystem" type="pci" managed="yes">
<source>
<address domain="0x0000" bus="0x01" slot="0x00" function="0x0"/>
</source>
<rom file="/usr/share/vgabios/1660ti-edited.rom"/>
<address type="pci" domain="0x0000" bus="0x03" slot="0x00" function="0x0"/>
</hostdev>
<hostdev mode="subsystem" type="pci" managed="yes">
<source>
<address domain="0x0000" bus="0x01" slot="0x00" function="0x1"/>
</source>
<address type="pci" domain="0x0000" bus="0x04" slot="0x00" function="0x0"/>
</hostdev>
<hostdev mode="subsystem" type="pci" managed="yes">
<source>
<address domain="0x0000" bus="0x01" slot="0x00" function="0x2"/>
</source>
<address type="pci" domain="0x0000" bus="0x05" slot="0x00" function="0x0"/>
</hostdev>
<hostdev mode="subsystem" type="pci" managed="yes">
<source>
<address domain="0x0000" bus="0x01" slot="0x00" function="0x3"/>
</source>
<address type="pci" domain="0x0000" bus="0x06" slot="0x00" function="0x0"/>
</hostdev>
<redirdev bus="usb" type="spicevmc">
<address type="usb" bus="0" port="2"/>
</redirdev>
<redirdev bus="usb" type="spicevmc">
<address type="usb" bus="0" port="3"/>
</redirdev>
<memballoon model="none"/>
<shmem name="looking-glass">
<model type="ivshmem-plain"/>
<size unit="M">32</size>
<address type="pci" domain="0x0000" bus="0x10" slot="0x01" function="0x0"/>
</shmem>
</devices>
</domain>
Screenshot of LG Host Log
LG Client Output
[I] 12242846803 main.c:1785 | main | Looking Glass (B6)
[I] 12242846822 main.c:1786 | main | Locking Method: Atomic
[I] 12242847155 cpuinfo.c:37 | lgDebugCPU | CPU Model: AMD Ryzen 9 7900X 12-Core Processor
[I] 12242847158 cpuinfo.c:38 | lgDebugCPU | CPU: 1 sockets, 12 cores, 24 threads
[I] 12242860378 main.c:1162 | lg_run | Using font: /usr/share/fonts/truetype/dejavu/DejaVuSansMono.ttf
[I] 12242860554 ivshmem.c:128 | ivshmemOpenDev | KVMFR Device : /dev/shm/looking-glass
[I] 12242864140 audio.c:159 | audio_init | Using AudioDev: PipeWire
[I] 12242864216 ps.c:245 | purespice_connect | Connecting to socket 127.0.0.1:5900
[I] 12242870995 rsa.c:178 | rsa_encryptPassword | Using Nettle
[I] 12242871614 ps.c:268 | purespice_connect | Connected
[I] 12242871688 channel_main.c:167 | onMessage_mainName | Guest name: win10-offline
[I] 12242871730 channel_main.c:183 | onMessage_mainUUID | Guest UUID: 3cf52937-85f6-4943-b403-2c2dc9bc5196
[I] 12242876156 ps.c:644 | ps_connectChannel | RECORD channel connected
[I] 12242882045 ps.c:644 | ps_connectChannel | PLAYBACK channel connected
[I] 12242914540 ps.c:644 | ps_connectChannel | INPUTS channel connected
[I] 12242914592 channel.c:312 | onMessage_notify | [notify] keyboard channel is insecure
[I] 12242914647 egl.c:267 | egl_initialize | Double buffering is off
[I] 12242914673 main.c:1116 | tryRenderer | Using Renderer: EGL
[I] 12242915534 x11.c:230 | x11CheckEWMHSupport | EWMH-complient window manager detected: KWin
[I] 12242915663 x11.c:463 | x11Init | X11 XInput 2.0 in use
[I] 12242924196 x11.c:1433 | x11GetEGLDisplay | Using eglGetPlatformDisplayEXT
[I] 12242964526 egl.c:745 | egl_renderStartup | Multisampling enabled, max samples: 4
[I] 12242965073 egl.c:828 | egl_renderStartup | Single buffer mode
[I] 12242966601 egl.c:855 | egl_renderStartup | EGL : 1.5
[I] 12242966628 egl.c:856 | egl_renderStartup | Vendor : AMD
[I] 12242966651 egl.c:857 | egl_renderStartup | Renderer: AMD Radeon RX 550 / 550 Series (polaris12, LLVM 15.0.7, DRM 3.54, 6.5.0-14-generic)
[I] 12242966676 egl.c:858 | egl_renderStartup | Version : OpenGL ES 3.2 Mesa 23.0.4-0ubuntu1~22.04.1
[I] 12242966703 egl.c:859 | egl_renderStartup | EGL APIs: OpenGL OpenGL_ES
[I] 12242966736 egl.c:930 | egl_renderStartup | Debug messages disabled, enable with egl:debug=true
[I] 12242993491 eglutil.c:35 | swapWithDamageInit | Using EGL_KHR_swap_buffers_with_damage
[I] 12243190281 main.c:1467 | lg_run | ================================================================================
[I] 12243190319 main.c:1468 | lg_run | The host application seems to not be running
[I] 12243190343 main.c:1469 | lg_run | Waiting for the host application to start…
[I] 12244198547 ps.c:644 | ps_connectChannel | DISPLAY channel connected
[I] 12244202787 main.c:896 | spice_surfaceCreate | Create SPICE surface: id: 0, size: 1024x768
[I] 12244206288 ps.c:644 | ps_connectChannel | CURSOR channel connected
[I] 12272207889 main.c:1474 | lg_run | ================================================================================
[I] 12272207933 main.c:1488 | lg_run | Check the host log in your guest at %ProgramData%\Looking Glass (host)\looking-glass-host.txt
[I] 12272207961 main.c:1489 | lg_run | Continuing to wait…
Thank you!