Invalid net test and unresponsive during the first connection
Host environment
- Operating system: Alpine 3.18
- OS/kernel version: Linux 3f0228816600 5.19.0-41-generic #42~22.04.1-Ubuntu SMP PREEMPT_DYNAMIC
- Architecture: x86_64
- QEMU flavor: qemu-system-x86_64
- QEMU version: QEMU emulator version 8.0.3
- QEMU command line:
/usr/bin/qemu-kvm
-name guest=feeb770c-fec4-44a4-8f7f-0038572af851,debug-threads=on
-S
-object '{"qom-type":"secret","id":"masterKey0","format":"raw","file":"/var/lib/libvirt/qemu/domain-79-feeb770c-fec4-44a4-8/master-key.aes"}'
-machine pc-i440fx-8.0,usb=off,vmport=off,dump-guest-core=off,memory-backend=pc.ram,hpet=off,acpi=on
-accel kvm
-cpu host,migratable=on
-m 500
-object '{"qom-type":"memory-backend-ram","id":"pc.ram","size":524288000}'
-overcommit mem-lock=off
-smp 1,sockets=1,dies=1,cores=1,threads=1
-uuid 96544c76-ee57-42fe-85cd-d73a6962b8cc
-no-user-config
-nodefaults
-chardev socket,id=charmonitor,fd=43,server=on,wait=off
-mon chardev=charmonitor,id=monitor,mode=control
-rtc base=utc,driftfix=slew
-global kvm-pit.lost_tick_policy=delay
-no-shutdown
-global PIIX4_PM.disable_s3=1
-global PIIX4_PM.disable_s4=1
-boot menu=off,strict=on
-device '{"driver":"ich9-usb-ehci1","id":"usb","bus":"pci.0","addr":"0x6.0x7"}'
-device '{"driver":"ich9-usb-uhci1","masterbus":"usb.0","firstport":0,"bus":"pci.0","multifunction":true,"addr":"0x6"}'
-device '{"driver":"ich9-usb-uhci2","masterbus":"usb.0","firstport":2,"bus":"pci.0","addr":"0x6.0x1"}'
-device '{"driver":"ich9-usb-uhci3","masterbus":"usb.0","firstport":4,"bus":"pci.0","addr":"0x6.0x2"}'
-device '{"driver":"ahci","id":"sata0","bus":"pci.0","addr":"0x7"}'
-device '{"driver":"virtio-serial-pci","id":"virtio-serial0","bus":"pci.0","addr":"0x8"}'
-blockdev '{"driver":"file","filename":"/isard/templates/3054302f-2fdd-4a9d-8e6a-8d4d0b69285b.qcow2","node-name":"libvirt-2-storage","auto-read-only":true,"discard":"unmap"}'
-blockdev '{"node-name":"libvirt-2-format","read-only":true,"driver":"qcow2","file":"libvirt-2-storage","backing":null}'
-blockdev '{"driver":"file","filename":"/isard/groups/f9104b4f-1531-43d2-aa42-543bb4df104b.qcow2","node-name":"libvirt-1-storage","auto-read-only":true,"discard":"unmap"}'
-blockdev '{"node-name":"libvirt-1-format","read-only":false,"driver":"qcow2","file":"libvirt-1-storage","backing":"libvirt-2-format"}'
-device '{"driver":"ide-hd","bus":"sata0.0","drive":"libvirt-1-format","id":"sata0-0-0","bootindex":1}'
-netdev '{"type":"tap","fd":"44","vhost":true,"vhostfd":"46","id":"hostnet0"}'
-device '{"driver":"virtio-net-pci","netdev":"hostnet0","id":"net0","mac":"52:54:00:1a:2f:0d","bus":"pci.0","addr":"0x3"}'
-netdev '{"type":"tap","fd":"47","vhost":true,"vhostfd":"48","id":"hostnet1"}'
-device '{"driver":"virtio-net-pci","netdev":"hostnet1","id":"net1","mac":"52:54:00:5f:ee:af","bus":"pci.0","addr":"0x4"}'
-chardev pty,id=charserial0
-device '{"driver":"isa-serial","chardev":"charserial0","id":"serial0","index":0}'
-chardev socket,id=charchannel0,fd=42,server=on,wait=off
-device '{"driver":"virtserialport","bus":"virtio-serial0.0","nr":1,"chardev":"charchannel0","id":"channel0","name":"org.qemu.guest_agent.0"}'
-chardev spicevmc,id=charchannel1,name=vdagent
-device '{"driver":"virtserialport","bus":"virtio-serial0.0","nr":2,"chardev":"charchannel1","id":"channel1","name":"com.redhat.spice.0"}'
-device '{"driver":"usb-tablet","id":"input0","bus":"usb.0","port":"1"}'
-audiodev '{"id":"audio1","driver":"spice"}'
-spice port=5912,tls-port=5913,addr=0.0.0.0,x509-dir=/etc/pki/libvirt-spice,image-compression=auto_glz,jpeg-wan-compression=always,zlib-glz-wan-compression=always,playback-compression=off,streaming-video=all,seamless-migration=on
-vnc 0.0.0.0:14,websocket=5704,password=on,audiodev=audio1
-device '{"driver":"qxl-vga","id":"video0","max_outputs":1,"ram_size":67108864,"vram_size":67108864,"vram64_size_mb":0,"vgamem_mb":16,"bus":"pci.0","addr":"0x2"}'
-device '{"driver":"intel-hda","id":"sound0","bus":"pci.0","addr":"0x5"}'
-device '{"driver":"hda-duplex","id":"sound0-codec0","bus":"sound0.0","cad":0,"audiodev":"audio1"}'
-chardev spicevmc,id=charredir0,name=usbredir
-device '{"driver":"usb-redir","chardev":"charredir0","id":"redir0","bus":"usb.0","port":"2"}'
-chardev spicevmc,id=charredir1,name=usbredir
-device '{"driver":"usb-redir","chardev":"charredir1","id":"redir1","bus":"usb.0","port":"3"}'
-device '{"driver":"virtio-balloon-pci","id":"balloon0","bus":"pci.0","addr":"0x9"}'
-object '{"qom-type":"rng-random","id":"objrng0","filename":"/dev/urandom"}'
-device '{"driver":"virtio-rng-pci","rng":"objrng0","id":"rng0","bus":"pci.0","addr":"0xa"}'
-sandbox on,obsolete=deny,elevateprivileges=deny,spawn=deny,resourcecontrol=deny
-msg timestamp=on
Emulated/Virtualized environment
- Operating system: Any
- OS/kernel version: Any
- Architecture: x86_64
Description of problem
After starting a VM the first connection to spice logs this errors (other connections after the first one stay connected without problems):
2023-07-25T16:00:47.497042Z qemu-system-x86_64: warning: Spice: main:0 (0x7f1a3fca5b90): invalid net test stage, ping id 0 test id 0 stage 4
2023-07-25T16:00:47.497170Z qemu-system-x86_64: warning: Spice: main:0 (0x7f1a3fca5b90): invalid net test stage, ping id 0 test id 0 stage 0
And after 60 seconds the spice viewer is closed with this error:
2023-07-25T16:01:47.384207Z qemu-system-x86_64: warning: Spice: main:0 (0x7f1a3fca5b90): rcc 0x7f1a1968cb60 has been unresponsive for more than 30000 ms, disconnecting
Steps to reproduce
- Start vm with spice
- Connect to spice
- Wait for at least 60 seconds and the viewer will close
- Connect again and there is no ping logs and the connection stays