Note: This bug is displayed in read-only format because the product is no longer active in Red Hat Bugzilla.
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 923514

Summary: screensaver does not activate when using virt-viewer
Product: Red Hat Enterprise Linux 6 Reporter: John Newbigin <jn>
Component: gnome-screensaverAssignee: Ray Strode [halfline] <rstrode>
Status: CLOSED DUPLICATE QA Contact: Desktop QE <desktop-qa-list>
Severity: high Docs Contact:
Priority: unspecified    
Version: 6.4CC: an.euroford, tpelka
Target Milestone: rc   
Target Release: ---   
Hardware: x86_64   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2013-06-05 12:26:59 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Attachments:
Description Flags
Log showing failure none

Description John Newbigin 2013-03-20 02:41:31 UTC
Description of problem:
When virt-viewer has the input focus, the host screen saver will not activate.

When the focus is released, the screensaver activates immediately.

Version-Release number of selected component (if applicable):
gnome-screensaver-2.28.3-24
virt-viewer-0.5.2-18

How reproducible:
Every time

Steps to Reproduce:
1. On EL6 host, set the screen saver timeout to 1m
2. Open virt-viewer and connect to a running guest
3. wait 1 min
  
Actual results:
After 1 min the screen is not locked

Expected results:
the screen is locked


Additional info:
You can also test with
sleep 10; gnome-screensaver-command -l
and then click onto virt-viewer
the screen should lock in 10 seconds but does not.

Comment 1 euroford 2013-03-21 04:52:41 UTC
when choose glx video, gnome-screensaver works fine. but when use the default video cirrus, gnome-screensaver will break.

THis bug is just effect in rhel6.4, the early versions do not have this bug.

the log in ~/.xsession-errors:
Gdk-ERROR **: The program 'gnome-screensaver' received an X Window System error.
This probably reflects a bug in the program.
The error was 'BadValue (integer parameter out of range for operation)'.
  (Details: serial 236 error_code 2 request_code 149 minor_code 15)
  (Note to programmers: normally, X errors are reported asynchronously;
   that is, you will receive the error a while after causing it.
   To debug your program, run it with the --sync command line
   option to change this behavior. You can then get a meaningful
   backtrace from your debugger if you break on the gdk_x_error() function.)
aborting...
gnome-session[2323]: WARNING: Detected that screensaver has left the bus

Comment 2 John Newbigin 2013-03-22 08:47:36 UTC
My situation is different to that of euroford.

This is the log from gnome-screensaver --no-daemon --debug


[listener_service_deleted] gs-listener-dbus.c:1042 (19:41:57):	 DBUS service deleted: 
[gs_manager_set_lock_active] gs-manager.c:423 (19:41:57):	 Setting lock active: 1
[gs_grab_grab_root] gs-grab-x11.c:529 (19:41:57):	 Grabbing the root window
[gs_grab_get_keyboard] gs-grab-x11.c:172 (19:41:57):	 Grabbing keyboard widget=24C
[gs_grab_get_keyboard] gs-grab-x11.c:187 (19:41:57):	 Couldn't grab keyboard!  (AlreadyGrabbed)
[gs_grab_get_keyboard] gs-grab-x11.c:172 (19:41:58):	 Grabbing keyboard widget=24C
[gs_grab_get_keyboard] gs-grab-x11.c:187 (19:41:58):	 Couldn't grab keyboard!  (AlreadyGrabbed)
[gs_grab_get_keyboard] gs-grab-x11.c:172 (19:41:59):	 Grabbing keyboard widget=24C
[gs_grab_get_keyboard] gs-grab-x11.c:187 (19:41:59):	 Couldn't grab keyboard!  (AlreadyGrabbed)
[gs_grab_get_keyboard] gs-grab-x11.c:172 (19:42:00):	 Grabbing keyboard widget=24C
[gs_grab_get_keyboard] gs-grab-x11.c:187 (19:42:00):	 Couldn't grab keyboard!  (AlreadyGrabbed)
[gs_grab_nuke_focus] gs-grab-x11.c:410 (19:42:01):	 Nuking focus
[gs_grab_get_keyboard] gs-grab-x11.c:172 (19:42:01):	 Grabbing keyboard widget=24C
[gs_grab_get_keyboard] gs-grab-x11.c:187 (19:42:01):	 Couldn't grab keyboard!  (AlreadyGrabbed)
[gs_grab_get_keyboard] gs-grab-x11.c:172 (19:42:02):	 Grabbing keyboard widget=24C
[gs_grab_get_keyboard] gs-grab-x11.c:187 (19:42:02):	 Couldn't grab keyboard!  (AlreadyGrabbed)
[gs_grab_get_keyboard] gs-grab-x11.c:172 (19:42:03):	 Grabbing keyboard widget=24C
[gs_grab_get_keyboard] gs-grab-x11.c:187 (19:42:03):	 Couldn't grab keyboard!  (AlreadyGrabbed)
[gs_grab_get_keyboard] gs-grab-x11.c:172 (19:42:04):	 Grabbing keyboard widget=24C
[gs_grab_get_keyboard] gs-grab-x11.c:187 (19:42:04):	 Couldn't grab keyboard!  (AlreadyGrabbed)
[gs_grab_get_mouse] gs-grab-x11.c:208 (19:42:05):	 Grabbing mouse widget=24C
[gs_grab_release_mouse] gs-grab-x11.c:271 (19:42:05):	 Ungrabbing pointer
[listener_active_changed_cb] gs-monitor.c:234 (19:42:05):	 Unable to set manager active: 1
[gs_listener_set_active] gs-listener-dbus.c:418 (19:42:05):	 Active-changed signal not handled
[gs_manager_set_lock_active] gs-manager.c:423 (19:42:05):	 Setting lock active: 0
[gs_monitor_lock_screen] gs-monitor.c:182 (19:42:05):	 Unable to lock the screen
[listener_service_deleted] gs-listener-dbus.c:1042 (19:42:05):	 DBUS service deleted: :1.535


Sometimes the screen does lock but only after I move the mouse in virt-viewer. Typically if I leave the computer and come back say 1 hour later, the screen saver has not activated. When I move the mouse, the screen saver immediatly kicks in. I have not got a log from that ATM but I will try and capture it.

Comment 3 John Newbigin 2013-03-23 02:31:07 UTC
When left alone to activate naturally, the screen failed to lock and when I started to use the computer again, then the screen locked.

The log file is 15Meg. I will upload a trimmed copy.

Comment 4 John Newbigin 2013-03-23 02:35:09 UTC
Created attachment 714903 [details]
Log showing failure

Comment 5 euroford 2013-03-25 01:33:52 UTC
hi John, 
Could you paste your ~/.xsession-errors?

When you could lock the screen in VM, you will meet another bug, if the host screen was locked, you chould not enter you passwd, the gnome-screensaver in VM catched you kerboard.

Comment 7 Ray Strode [halfline] 2013-06-05 12:26:59 UTC
This is hard to fix in gnome-screensaver given the architecture of X, but possible to work around in virt-manager.

Duping with a similar virt-manager bug report.

*** This bug has been marked as a duplicate of bug 927357 ***