RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.
Bug 1623947 - Cannot transfer file to guest VM with logged-in user, which have never been logged out
Summary: Cannot transfer file to guest VM with logged-in user, which have never been l...
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 7
Classification: Red Hat
Component: spice-vdagent
Version: 7.6
Hardware: Unspecified
OS: Unspecified
medium
medium
Target Milestone: rc
: ---
Assignee: Victor Toso
QA Contact: SPICE QE bug list
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2018-08-30 14:09 UTC by Radek Duda
Modified: 2018-10-30 10:52 UTC (History)
4 users (show)

Fixed In Version: spice-vdagent-0.14.0-16.el7
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2018-10-30 10:51:49 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)
spice-debug-log-snippet (1.13 KB, text/plain)
2018-08-30 14:09 UTC, Radek Duda
no flags Details
spice-vdagent-log (564 bytes, text/plain)
2018-08-30 14:13 UTC, Radek Duda
no flags Details


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2018:3175 0 None None None 2018-10-30 10:52:27 UTC

Description Radek Duda 2018-08-30 14:09:15 UTC
Created attachment 1479820 [details]
spice-debug-log-snippet

Description of problem:
client+host(rhel7.6):

Version-Release number of selected component (if applicable):

qemu-kvm-rhev-2.9.0-16.el7_4.16.x86_64
spice-server-0.14.0-6.el7.x86_64
spice-gtk3-0.35-2.el7.x86_64
spice-glib-0.35-2.el7.x86_64
virt-viewer-5.0-11.el7.x86_64

guest(rhel7.6):
spice-vdagent-0.14.0-15.el7.x86_64
kernel-3.10.0-940.el7.x86_64
gdm-3.28.2-7.el7.x86_64
dbus-1.10.24-12.el7.x86_64

How reproducible:
always

Steps to Reproduce:
1. Create new VM, add user and log-in. Do not log-out this user.
2. Transfer some file from client to guest VM (drag'n'drop)


Actual results:
File is not transferred. Message 'An error caused the following file transfers to fail: $filename' appears.

Expected results:
File is transferred from client to guest

Additional info:
Files could be transferred if user is at least once logged-out (by restarting Vm, shutting it down, or simply user log-out) and then logged-in. If Vm is shutdown forcibly, and then (after VM boots up) is user logged-in, file transfer will not work.

Comment 2 Radek Duda 2018-08-30 14:13:33 UTC
Created attachment 1479822 [details]
spice-vdagent-log

Comment 4 Victor Toso 2018-08-31 07:02:41 UTC
Hi Radek,

Could you please clarify the step "1. Create new VM, add user and log-in. Do not log-out this user." on what you do exactly?

If I try to switch user in GNOME interface, file transfer works as expected so I'm guessing you are doing something else.

As the regression flag is set, it is also nice to know the prior version that this situation did not happen.

Comment 5 Radek Duda 2018-08-31 09:18:26 UTC
(In reply to Victor Toso from comment #4)
> Hi Radek,
> 
> Could you please clarify the step "1. Create new VM, add user and log-in. Do
> not log-out this user." on what you do exactly?
> 
see Additional info of #c0 - I think it is quite explanatory :
'Files could be transferred if user is at least once logged-out (by restarting Vm, shutting it down, or simply user log-out) and then logged-in. '

"Do not log out this user" - I mean user account should not go through log-out procedure - ever (to reproduce this bug).

Now I found that if I restart /usr/bin/spice-vdagent (instead of log-out + log-in), I cannot reproduce this.

> If I try to switch user in GNOME interface, file transfer works as expected
> so I'm guessing you are doing something else.
> 
> As the regression flag is set, it is also nice to know the prior version
> that this situation did not happen.

I cannot reproduce this on rhel7.5 guest (kernel-3.10.0-862.el7, gdm-3.26.2.1-5.el7, dbus-1.10.24-7.el7). There is the same version of spice-vdagent (spice-vdagent-0.14.0-15.el7), so maybe the bug is elsewhere.

Comment 6 Victor Toso 2018-08-31 09:44:09 UTC
Trying to reproduce. Talked with Radek, it is a bit tricky to get spice-vdagent logs as that would always imply rebooting or restarting the agent and bug would not be reproducible anymore.

Downloading image where this happens.

Situation that this issue happens seems very limited and easy workaround, removing the blocker flag.

Comment 8 Victor Toso 2018-08-31 14:38:37 UTC
> journalctl -r -t spice-vdagent
> spice-vdagent[4058]: warning could not get file xfer save dir, file transfers will be disabled

So the file transfer was disabled in the agent because it could set a target directory for file transfers to be stored.

That's happening because g_get_user_special_dir () is returning NULL for either G_USER_DIRECTORY_DESKTOP or G_USER_DIRECTORY_DOWNLOAD.

That seems to be happening due a race between spice-vdagent and xdg-user-dirs as both can be started in parallel due .desktop settings being X-GNOME-Autostart-Phase=Initialization

Many thanks to Ray Strode on clarifying this :)

Comment 10 Victor Toso 2018-09-04 09:02:03 UTC
Patch posted [0], note that this is a regression introduced by rhbz#1412762, it seems (7.5)

[0] https://lists.freedesktop.org/archives/spice-devel/2018-September/045511.html
[1] https://bugzilla.redhat.com/show_bug.cgi?id=1412762

Comment 14 errata-xmlrpc 2018-10-30 10:51:49 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHBA-2018:3175


Note You need to log in before you can comment on or make changes to this bug.