Bugzilla – Bug 302413
Gnome power manager does not display suspend/hibernate
Last modified: 2007-09-12 17:22:14 UTC
left clicking g-p-m only shows laptop battery levels and does not show suspend-hibernate. Also, clicking general-system settings gives an error about yast2 module power-management not existing (no such client module). This is a fresh install of beta1 upgraded to FACTORY with both oss and non-oss repositories active. if i run pm-suspend or pm-hibernate the system suspends and resumes successfully every time. florin-laptop:~ # lshal |grep can power_management.can_hibernate = true (bool) power_management.can_standby = false (bool) power_management.can_suspend = true (bool) power_management.can_suspend_hybrid = false (bool) power_management.can_suspend_to_disk = true (bool) power_management.can_suspend_to_ram = true (bool) florin@florin-laptop:~> gconftool-2 -R /apps/gnome-power-manager |grep can can_hibernate = true can_suspend = true Any other info i can provide?
Holger is this a duplicate of all the other "does not show suspend" bugs?
Hm, maybe, but I'm not aware about what gnome-power-manager is doing regarding PolicyKit. Maybe it has to be adjusted, too. (In reply to comment #0 from Samareanu Florin) > suspend-hibernate. Also, clicking general-system settings gives an error about > yast2 module power-management not existing (no such client module). This is a > fresh install of beta1 upgraded to FACTORY with both oss and non-oss > repositories active. Rodrigo, the YaST2 power management module got dropped. Can you please remove the referring patch from gpm? > Any other info i can provide? Can you please attach the output of polkit-list-actions as user, thanks.
Created attachment 159029 [details] polkit-list-actions 1>polkit-list-actions.stdout.log
i`m sorry for the off-bug question, but yast power management module is now replaced by ... what? should only g-p-m be used on a laptop machine? also, the requested log file is now attached to this bug.
Thanks, for the log. It seems healthy. The YaST2 module didn't have any noticeable functionality which can't be controlled from within the desktop. You can use kpowersave, gnome-power-manager or any other desktop applet popping up in the future. A fallback for servers is still /etc/powersave and the powersave daemon.
aditional info: Aug 22 16:18:11 florin-laptop gnome-power-manager: (florin) Hibernating computer because System idle Aug 22 16:18:11 florin-laptop gnome-power-manager: (florin) cannot hibernate as not allowed from policy Aug 22 16:18:11 florin-laptop gnome-power-manager: (florin) hibernate failed Aug 22 16:18:11 florin-laptop gnome-power-manager: (florin) cannot suspend as not allowed from policy Aug 22 16:18:11 florin-laptop gnome-power-manager: (florin) suspend failed
any news on this?
This bug makes the GNOME desktop unusable on Laptops. Raising severity...
*** Bug 304245 has been marked as a duplicate of this bug. ***
ping?
Still with Beta2?
yes with the last update from sunday. i`ll try to upgrade the system to the current factory, but since i`m on a very poor connection, this could take a while. Will try to report in the morning. Thanks.
Hm, gnome-power-manager didn't change since Beta1 at least. So if is a g-p-m issue, it's not fixed.
after today`s updates, g-p-m does not even start, complaining about an incorrect schema installed. the problem persists with a new user created after the update. Manually trying to launch g-p-m gives the following in a terminal: florin@florin-laptop:~> gnome-power-manager --debug all *** ERROR *** [main] gpm-main.c:217 (10:02:19): Could not daemonize: No such device Saving to syslog: Could not daemonize: No such deviceflorin@florin-laptop:~> florin@florin-laptop:~>
after importing the schemas (see bug 307013), g-p-m runs again, but the suspend/hibernate options are still not shown. Any ideeas?
still here after the 10.3 beta3 upgrade (as reported by /etc/SuSE-release).
Yes, still broken in beta3. I didn't find a way to suspend my laptop from outside of commandline, so I think this should be a critical bug. By the way, where can I configure that closing the notebook lid should suspend to RAM? I think this is what was configured in the yast module before, although I'm not sure. In gnome-power-preferences I can select only between 'do nothing' and 'blank screen' for the 'when laptop lid is closed' action - maybe 'suspend' should be listed there too and it's related to the gnome-power-manager breakage?
did you do a fresh install of beta3 or upgraded a previous release? since i cannot reinstall the system (since it is the system i currently work on), it would be interesting to see if the bug is still here on a clean install.
I did a fresh install.
[hal_device_condition_cb] gpm-button.c:390 (14:32:33): condition=ButtonPressed, details=sleep [emit_button_pressed] gpm-button.c:334 (14:32:33): emitting button-pressed : sleep [button_pressed_cb] gpm-manager.c:928 (14:32:33): Button press event type=sleep [manager_policy_do] gpm-manager.c:428 (14:32:33): policy: /apps/gnome-power-manager/buttons/suspend Saving to syslog: Suspending computer because the suspend button has been pressed[gpm_info_event_log] gpm-info.c:591 (14:32:33): Adding 5 to the event log *** WARNING *** [gpm_polkit_is_user_privileged] gpm-polkit.c:73 (14:32:33): not connected Saving to syslog: cannot suspend as not allowed from policySaving to syslog: suspend failed*** WARNING *** [gpm_notify_create] gpm-notify.c:125 (14:32:33): libnotify: Power Manager : Your computer failed to suspend. Check the help file for common problems. [gpm_info_event_log] gpm-info.c:591 (14:32:33): Adding 10 to the event log [button_pressed_cb] gpm-srv-screensaver.c:167 (14:32:33): Button press event type=sleep [button_pressed_cb] gpm-backlight.c:512 (14:32:33): Button press event type=sleep [button_pressed_cb] gpm-info.c:695 (14:32:33): Button press event type=sleep this is the debug output from g-p-m
My initial guess is that this: [gpm_polkit_is_user_privileged] gpm-polkit.c:73 (14:32:33): not connected Saving to syslog: cannot suspend as not allowed from policySaving to syslog: suspend failed*** WARNING *** is the problem.
i`m fresh out of ideeas . i checked and double checked polkit and the gconf values and still no joy. Any other things i can test?
> Rodrigo, the YaST2 power management module got dropped. Can you please remove > the referring patch from gpm? > gnome-power-manager-yast-settings.patch removed
I think we already know what the problem is. The first sentence from comment #2. PolicyKit got updated, so gpm has to be adjusted AFAIK.
What exactly needs to be updated?
I'm not that familiar with gpm code, but AFAICS, everything which is in gpm-polkit.c. The PolicyKit desing changed, so for example, calling "IsUserPrivileged" on a now nonexistant PolicyKit daemon doesn't work anymore ;-)
Fedora also has a newer policykit, they are explicitly turning off policy kit support --disable-policykit. The gpm support seems to be tied to the last official release i can find, 0.3. However it looks like all we really need to do is to link to libpolkit-grant and use the API there to query privileges.
*** Bug 309723 has been marked as a duplicate of this bug. ***
Seems g-p-m is not ported to the current policykit, so we might just want to disable it too.
Yes, that's what upstream suggested for now, so policykit disabled now in the package
(In reply to comment #28 from JP Rosevear) > Fedora also has a newer policykit, they are explicitly turning off policy kit > support --disable-policykit. The gpm support seems to be tied to the last > official release i can find, 0.3. > > However it looks like all we really need to do is to link to libpolkit-grant > and use the API there to query privileges. It should be easier to use simply libhal to query the policies via: libhal_device_is_caller_privileged(...). This function handle also all the ConsoleKit/session handling. This was what we did for example in KPowersave.