spice-vdagentd does not work

Bug #1633609 reported by Grzegorz Żur
62
This bug affects 11 people
Affects Status Importance Assigned to Milestone
spice-vdagent (Ubuntu)
Fix Released
Undecided
Unassigned

Bug Description

After upgrade to Ubuntu 16.10, the Ubuntu system inside Quemu/KVM virtual machine stopped to resize screen whenever Spice client window size changes.

I found out the following message in /var/log/spice-vdagent.log:
spice-vdagentd: err: Error getting session for pid 3506: No such device or address

Revision history for this message
Launchpad Janitor (janitor) wrote :

Status changed to 'Confirmed' because the bug affects multiple users.

Changed in spice-vdagent (Ubuntu):
status: New → Confirmed
Revision history for this message
Tony Arnold (tony-arnold) wrote :

Just to confirm that I am seeing exactly the same symptoms as Grzegorz has reported.

Revision history for this message
Jonathan Ganc (jonganc) wrote :

I also can confirm the symptoms. Just to clarify one thing:
The problems occur with a 16.10 guest but disappears if I revert back to a 16.04.1 guest.

I am using a Ubuntu 16.10 host.

Revision history for this message
Grzegorz Żur (grzegorz-zur) wrote :

Both versions 16.04 and 16.10 uses version 0.15 of spice-vdagent. I tried installing version 0.17 from Ubuntu 17.04 on 16.10. It failed the same way.

I traced the problem to the function session_info_session_for_pid in file systemd-login.c.

It seems that the problem is related to systemd.

Revision history for this message
Grzegorz Żur (grzegorz-zur) wrote :

Meanwhile systemd changed from version 229 in Ubuntu 16.04 to version 231 in Ubuntu 16.10.

Revision history for this message
Grzegorz Żur (grzegorz-zur) wrote :

I found a partial workaround.

To make things work. Add "-X" to the daemon spice-vdagentd in "/lib/systemd/system/spice-vdagent.service" file.

This option disables systemd-login integration. The virtual machine is now able to set correct screen size but USB still integration fails for me.

Revision history for this message
Sebastian Geiger (lanoxx) wrote :

I can confirm that Grzegorz Zur workaround works for me. This is a highly annoying bug that cost me several hours of time today. Please fix this soon. Thank you.

Revision history for this message
Grzegorz Żur (grzegorz-zur) wrote :

Thanks to the answer on askbuntu.com I improved the workaround.

In /etc/default/spice-vdagentd

put the following line

SPICE_VDAGENTD_EXTRA_ARGS=-X

then run

service spice-vdagent restart

This disables systemd-logind integration.

It is actually described in 'man spice-vdagentd'.

http://askubuntu.com/questions/880074/configuration-for-spice-vdagentd/884950#884950

Revision history for this message
Grzegorz Żur (grzegorz-zur) wrote :

The bug also affects version 17.04 but the workaround still works in this version.

Revision history for this message
Maxlen (maxlen) wrote :

I tested with Ubuntu 10.07 worked perfectly, without the need for tweaking, but I was not successful with 16.04 and 17.10

Revision history for this message
Pavel Borecki (pavel-borecki) wrote :

Workaround is functional on Ubuntu 18.04 daily build - without it, BOOT PROCESS WILL FREEZE! after install spice-vdagent package on starting spice-vdagent(d) service.

But as spice-vdagentd in result hasn't information about sessions, so there is (in man documented) limitation on one instance of spice-vdagent client.

And there are two instances running - one for gdm, one for each user. Service spice-vdagent is complaining:

spice-vdagentd[540]: multiple agents in o ne session, disabling agent to avoid potential information leak
spice-vdagentd[540]: closed vdagent virtio channel

Workaround is to sudo killall spice-vdagent and then run spice-vdagent as a current user.

It would be very helpful to fix spice-vdagentd collision with systemd-logind, because it is destroying Ubuntu guest experience (seemingly unbootable system and even then very tricky to get decent interaction with vm working).

Revision history for this message
Rolf Leggewie (r0lf) wrote :

Found this in "journalctl | grep spice"

Aug 24 01:12:10 work gnome-session-binary[1973]: WARNING: App 'spice-vdagent.desktop' exited with code 1

Possibly related?

Revision history for this message
Grzegorz Żur (grzegorz-zur) wrote :

The error is raised against the daemon package 'spice-vdagentd'. Application 'spice-vdagent' is another package. Most probably it is a different issue.

Changed in spice-vdagent (Ubuntu):
status: Confirmed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.