Spice problems

19topgun93

Member
Apr 5, 2021
14
0
6
31
Hello everyone,

https://forum.proxmox.com/threads/disable-tls-for-spice-connections.139199/ this post is almost exactly my question.

I have a VM running the spice agent and I'm using Remmina to connect via Spice. At first, it didn’t work. Then it worked for one evening, and now it's not working again. I suspect TLS might be the issue:

Code:
device virtserialport,chardev=vdagent,name=com.redhat.spice.0 -spice tls-port=61001,addr=127.0.0.1,tls-ciphers=HIGH,

My vm.conf

Code:
agent: 1

audio0: device=AC97,driver=spice

boot: order=ide2;scsi0

cores: 6

cpu: x86-64-v2-AES

ide2: none,media=cdrom

memory: 14294

meta: creation-qemu=8.1.5,ctime=1721403451

name: firebot

net0: virtio=BC:24:11:A6:03:41,bridge=vmbr0,firewall=1

numa: 0

onboot: 0

ostype: l26

protection: 1

scsi0: local-lvm:vm-101-disk-0,iothread=1,size=65G,ssd=1

scsi1: yt-storage:101/vm-101-disk-0.qcow2,iothread=1,size=978656953K

scsihw: virtio-scsi-single

smbios1: uuid=360ee1bf-a118-45c6-a185-6fd1338b178f

sockets: 1

spice_enhancements: videostreaming=all

unused0: local-lvm:vm-101-disk-1

vga: qxl

vmgenid: 72c9652c-2663-43ff-b192-885be38fdece

But there is no TLS configuration anywhere. With ChatGPT, I tried to edit the configuration and added:

Code:
spice: spice,port=5900,disable-ticketing

Unfortunately, QEMU doesn’t seem to recognize this syntax:

Code:
vm 101 - unable to parse value of 'spice' - unknown setting 'spice'

There should also be a reference to the CA file in the configuration, if I understand it correctly. If someone could explain both, how to disable TLS or how to properly set up certificates in Proxmox, I’d be very grateful.
 
Hi!

You can't disable TLS, in our case spice is running over the spiceproxy[0], so ChatGPT suggested the configuration if you were using KVM/QEMU directly without spiceproxy.

Honestly, I don't think TLS is the issue, otherwise you wouldn't have ever got it to work in the first place. Are you aware, that you have to get a new spice.vv file when creating a remote session?


DISCLAIMER: Please be cautious when running 3rd party scripts, we don't check/monitor posted projects ourselves.
There are a couple of community solutions[1] to avoid going through the web-GUI every time you would like to access a VM through spice



[0] https://pve.proxmox.com/pve-docs/spiceproxy.8.html
[1] https://forum.proxmox.com/threads/remote-spice-access-without-using-web-manager.16561/ - Be cautious!
 
Hi,

I don't want use a custom script in the first place. I'm very fine with the GUI.

Honestly, I don't think TLS is the issue, otherwise you wouldn't have ever got it to work in the first place. Are you aware, that you have to get a new spice.vv file when creating a remote session?
Yeah. I download the Spice file and want to run it on my Garuda Linux. With Remote Viewer is the error, that it cannot connect. With Remmina there is the Error, that it is invalid, unreadable or not found. Every time I want to open my VM I have to download the new file from the Proxmox Gui.

Spiceproxy is running on the host. Spice Agent runs inside the VM. On the host I haven't errors for spice, on the VM I haven't errors for spice. I don't have an error on my computer. (journalctl -xe) So I don't know, where I can search for a solution besides of journalctl. And I don't know why it doesn't run, then it runs (I think I doesn't change anything), and then it fails again.

I only want run Spice for Audio xD And maybe later on on another VM with GPU passthroug.

Could you post, where it could be logged why it fails?

EDIT:

I doesn't see a Task log in the PVE GUI with the Type spiceproxy or spiceshell. Only vncproxy is listed. That cannot be right, too or?
 
Last edited:
I doesn't see a Task log in the PVE GUI with the Type spiceproxy or spiceshell. Only vncproxy is listed. That cannot be right, too or?

This is correct, Spice connections (or download) doesn't show up.

For troubleshooting the host side I'ld recommend checking the access.logs first:

Code:
grep spice /var/log/pveproxy/access.log

If everything is ok, a connection should look like this (port can be 61000 or higher):

Code:
::ffff:<host-ip> - - [15/10/2024:13:02:55 +0200] "CONNECT pvespiceproxy:<another-id>:<VM-ID>:<hostname>::<some-id>:61001 HTTP/1.0" 200 -
::ffff:<host-ip> - - [15/10/2024:14:12:55 +0200] "CONNECT pvespiceproxy:<another-id>:<VM-ID>:<hostname>::<some-id>:61001 HTTP/1.0" 200 -
::ffff:<host-ip> - - [15/10/2024:14:12:55 +0200] "CONNECT pvespiceproxy:<another-id>:<VM-ID>:<hostname>::<some-id>:61001 HTTP/1.0" 200 -
::ffff:<host-ip> - - [15/10/2024:14:12:55 +0200] "CONNECT pvespiceproxy:<another-id>:<VM-ID>:<hostname>::<some-id>:61001 HTTP/1.0" 200 -

Just to check if it's an authentication or connection issue (if there are no connections whatsoever) in the first place.

Debug client side (for virt-viewer[0], not sure how to do this for other clients):

Code:
remote-viewer --spice-debug <file>.vv


[0] https://www.spice-space.org/spice-user-manual.html - See debugging
 
So... It is very strange I would say xD

/var/log/pveproxy/access.log

There is nothing with pvespiceproxy or the status "CONNECT".

With remote-viewer --spice-debug and the file (without .vv because the Files have no ending) I doesn't have an output. But with the spice user manual I have another logs.

Spice logs: journalctl -t spice-vdagentd -t spice-vdagent

Code:
Okt 10 00:22:12 debian-firebot spice-vdagent[3324]: No guest output map, using output index as display id
Okt 10 00:29:50 debian-firebot spice-vdagent[3324]: Received Graphics Device Info:
Okt 10 00:29:50 debian-firebot spice-vdagent[3324]: Device /dev/dri/card0 is at /sys/devices/pci0000:00/0000:00:02.0/drm/card0
Okt 10 00:29:50 debian-firebot spice-vdagent[3324]: Found card '/sys/devices/pci0000:00/0000:00:02.0/drm/card0' with Vendor ID 0x100, Device ID 0x1b36
Okt 10 00:29:50 debian-firebot spice-vdagent[3324]: Mapping connector Virtual-1 to display #0
Okt 10 00:29:50 debian-firebot spice-vdagent[3324]: Device /dev/dri/card0 is at /sys/devices/pci0000:00/0000:00:02.0/drm/card0
Okt 10 00:29:50 debian-firebot spice-vdagent[3324]: Found card '/sys/devices/pci0000:00/0000:00:02.0/drm/card0' with Vendor ID 0x100, Device ID 0x1b36
Okt 10 00:29:50 debian-firebot spice-vdagent[3324]: Found matching X Output: name=Virtual-1 id=66
Okt 10 00:29:50 debian-firebot spice-vdagent[3324]: Found matching X Output: name=Virtual-1 id=66
Okt 10 00:29:50 debian-firebot spice-vdagent[3324]: Adding graphics device info: channel_id: 0 monitor_id: 0 device_address: pci/0000/02.0, device_display_id: 0 xrandr outpu>
Okt 10 00:29:50 debian-firebot spice-vdagent[3324]: Device /dev/dri/card0 is at /sys/devices/pci0000:00/0000:00:02.0/drm/card0
Okt 10 00:29:50 debian-firebot spice-vdagent[3324]: Found card '/sys/devices/pci0000:00/0000:00:02.0/drm/card0' with Vendor ID 0x100, Device ID 0x1b36
Okt 10 00:29:50 debian-firebot spice-vdagent[3324]: Mapping connector Virtual-2 to display #1
Okt 10 00:29:50 debian-firebot spice-vdagent[3324]: Device /dev/dri/card0 is at /sys/devices/pci0000:00/0000:00:02.0/drm/card0
Okt 10 00:29:50 debian-firebot spice-vdagent[3324]: Found card '/sys/devices/pci0000:00/0000:00:02.0/drm/card0' with Vendor ID 0x100, Device ID 0x1b36
Okt 10 00:29:50 debian-firebot spice-vdagent[3324]: Found matching X Output: name=Virtual-2 id=67
Okt 10 00:29:50 debian-firebot spice-vdagent[3324]: Adding graphics device info: channel_id: 0 monitor_id: 1 device_address: pci/0000/02.0, device_display_id: 1 xrandr outpu>
Okt 10 00:29:50 debian-firebot spice-vdagent[3324]: Device /dev/dri/card0 is at /sys/devices/pci0000:00/0000:00:02.0/drm/card0
Okt 10 00:29:50 debian-firebot spice-vdagent[3324]: Found card '/sys/devices/pci0000:00/0000:00:02.0/drm/card0' with Vendor ID 0x100, Device ID 0x1b36
Okt 10 00:29:50 debian-firebot spice-vdagent[3324]: Mapping connector Virtual-3 to display #2
Okt 10 00:29:50 debian-firebot spice-vdagent[3324]: Device /dev/dri/card0 is at /sys/devices/pci0000:00/0000:00:02.0/drm/card0
Okt 10 00:29:50 debian-firebot spice-vdagent[3324]: Found card '/sys/devices/pci0000:00/0000:00:02.0/drm/card0' with Vendor ID 0x100, Device ID 0x1b36
Okt 10 00:29:50 debian-firebot spice-vdagent[3324]: Found matching X Output: name=Virtual-3 id=68
Okt 10 00:29:50 debian-firebot spice-vdagent[3324]: Adding graphics device info: channel_id: 0 monitor_id: 2 device_address: pci/0000/02.0, device_display_id: 2 xrandr outpu>
Okt 10 00:29:50 debian-firebot spice-vdagent[3324]: Device /dev/dri/card0 is at /sys/devices/pci0000:00/0000:00:02.0/drm/card0
Okt 10 00:29:50 debian-firebot spice-vdagent[3324]: Found card '/sys/devices/pci0000:00/0000:00:02.0/drm/card0' with Vendor ID 0x100, Device ID 0x1b36
Okt 10 00:29:50 debian-firebot spice-vdagent[3324]: Mapping connector Virtual-4 to display #3
Okt 10 00:29:50 debian-firebot spice-vdagent[3324]: Device /dev/dri/card0 is at /sys/devices/pci0000:00/0000:00:02.0/drm/card0
Okt 10 00:29:50 debian-firebot spice-vdagent[3324]: Found card '/sys/devices/pci0000:00/0000:00:02.0/drm/card0' with Vendor ID 0x100, Device ID 0x1b36
Okt 10 00:29:50 debian-firebot spice-vdagent[3324]: Found matching X Output: name=Virtual-4 id=69
Okt 10 00:29:50 debian-firebot spice-vdagent[3324]: Adding graphics device info: channel_id: 0 monitor_id: 3 device_address: pci/0000/02.0, device_display_id: 3 xrandr outpu>
Okt 10 00:29:50 debian-firebot spice-vdagent[3324]: display: failed to call GetCurrentState from mutter over DBUS
Okt 10 00:29:50 debian-firebot spice-vdagent[3324]:    error message: Die Methode kann nicht aufgerufen werden; Der Proxy ist fürden allgemein bekannten Namen org.gnome.Mutt>
Okt 10 00:29:52 debian-firebot spice-vdagent[3324]: vdagent_audio_playback_sync mute=no nchannels=2
Okt 10 00:29:52 debian-firebot spice-vdagent[3324]: vdagent-audio: (playback-left) 65535 (100,00%)
Okt 10 00:29:52 debian-firebot spice-vdagent[3324]: vdagent-audio: (playback-right) 65535 (100,00%)
Okt 10 00:29:52 debian-firebot spice-vdagent[3324]: vdagent_audio_record_sync mute=no nchannels=2
Okt 10 00:29:52 debian-firebot spice-vdagent[3324]: vdagent-audio: (capture-left) 65535 (100,00%)
Okt 10 00:29:52 debian-firebot spice-vdagent[3324]: vdagent-audio: (capture-right) 65535 (100,00%)
-- Boot 446c885fea5746e29e9daad42af9d30b --


You can see, that it has function and then there are the Errors:

[CODE]Okt 15 20:42:43 debian-firebot systemd[1]: Listening on spice-vdagentd.socket - Activation socket for spice guest agent daemon.
░░ Subject: A start job for unit spice-vdagentd.socket has finished successfully
░░ A start job for unit spice-vdagentd.socket has finished successfully.
Okt 15 20:42:50 debian-firebot spice-vdagent[1863]: vdagent started
Okt 15 20:42:50 debian-firebot systemd[1]: Starting spice-vdagentd.service - Agent daemon for Spice guests...
░░ Subject: A start job for unit spice-vdagentd.service has begun execution
░░ A start job for unit spice-vdagentd.service has begun execution.
Okt 15 20:42:50 debian-firebot spice-vdagent[1863]: display: failed to call GetCurrentState from mutter over DBUS
Okt 15 20:42:50 debian-firebot spice-vdagent[1863]:    error message: Die Methode kann nicht aufgerufen werden; Der Proxy ist fürden allgemein bekannten Namen org.gnome.Mutter.DisplayConfig ohne Besitzer, und der Proxy wurde mit dem Flag »G_DBUS_PROXY_FLAGS_DO_NOT_AUTO_START« erstellt
Okt 15 20:42:50 debian-firebot spice-vdagent[1863]: No guest output map, using output index as display id

Okt 15 20:42:50 debian-firebot systemd[1]: Started spice-vdagentd.service - Agent daemon for Spice guests.                                                                 
░░ Subject: A start job for unit spice-vdagentd.service has finished successfully                                                                                           
░░ A start job for unit spice-vdagentd.service has finished successfully.                                                                                                   
Okt 15 20:42:50 debian-firebot spice-vdagentd[1883]: opening vdagent virtio channel                                                                                         
Okt 15 20:42:50 debian-firebot kernel: input: spice vdagent tablet as /devices/virtual/input/input6                                                                         
Okt 15 20:42:50 debian-firebot spice-vdagent[1863]: display: failed to call GetCurrentState from mutter over DBUS                                                           
Okt 15 20:42:50 debian-firebot spice-vdagent[1863]:    error message: Die Methode kann nicht aufgerufen werden; Der Proxy ist fürden allgemein bekannten Namen org.gnome.Mutter.DisplayConfig ohne Besitzer, und der Proxy wurde mit dem Flag »G_DBUS_PROXY_FLAGS_DO_NOT_AUTO_START« erstellt                                                             
                                                         
Okt 15 20:42:50 debian-firebot spice-vdagent[1863]: display: failed to call GetCurrentState from mutter over DBUS                                                           
Okt 15 20:42:50 debian-firebot spice-vdagent[1863]:    error message: Die Methode kann nicht aufgerufen werden; Der Proxy ist fürden allgemein bekannten Namen org.gnome.Mutter.DisplayConfig ohne Besitzer, und der Proxy wurde mit dem Flag »G_DBUS_PROXY_FLAGS_DO_NOT_AUTO_START« erstellt                                                             
Okt 15 20:42:50 debian-firebot spice-vdagent[1863]: No guest output map, using output index as display id                                                                   
                                                                 
Okt 15 20:42:50 debian-firebot kernel: input: spice vdagent tablet as /devices/virtual/input/input7
What I've tried is to install the gnome component, and tried to go to the gnome desktop enviroment. But it doesn't help. My brain is working, what I have change, but, I don't know.

The PCI device confuse me in the logs.
The VM is Debian 12 with LXQT.
Bildschirmfoto vom 2024-10-15 21-31-05.png
 
Last edited:
Hm...... I have also tried to install mutter, but I think that confilcts with the other Video-Device. It is install, and it starts, but it has to fall back.
 
OK we need some sanity checks here :) because this doesn't quite add up.

1. You're starting spice like this? https://pve.proxmox.com/mediawiki/images/e/e0/Screen-start-spice-viewer.png
1.1. Please confirm with ls -la that your file doesn't have an extension, because I couldn't find out why there wouldn't be
1.2. You tried remote-viewer --spice-debug <file>.vv from your client, correct? Was there any other error message?
2. You checked grep spice /var/log/pveproxy/access.log on your Proxmox VE host? If there's any connection attempt, there has to be a log entry
3. Have you tried setting up a different VM? Is your Debian in your VM up to date? Which desktop environment are you using(X11 or Wayland)? Have you tried starting Spice before or after logging in? Which Display Manager are you using? https://wiki.debian.org/DisplayManager
 

About

The Proxmox community has been around for many years and offers help and support for Proxmox VE, Proxmox Backup Server, and Proxmox Mail Gateway.
We think our community is one of the best thanks to people like you!

Get your subscription!

The Proxmox team works very hard to make sure you are running the best software and getting stable updates and security enhancements, as well as quick enterprise support. Tens of thousands of happy customers have a Proxmox subscription. Get yours easily in our online shop.

Buy now!