:: [devuan-dev] bug#479: xcfe4-power-m…
トップ ページ
このメッセージを削除
このメッセージに返信
著者: Michaela Merz
日付:  
To: Mark Hindley
題目: [devuan-dev] bug#479: xcfe4-power-manager: Can't configure laptop lid
Mark:

I installed vanilla Devuan Beowulf and noticed, that the power-manager
didn't give me an option to suspend on laptop lid. There also was no option
to suspend in the system settings. I installed pm-utis and rebooted and on
the first try, the power-manager offered "suspend" on laptop-lid, but it
didn't do anything. Subsequent calls to power manager had the "suspend"
options removed again.

I called it a day and installed acpid because it allows me to run scripts
on events. I created a laptop-lif script script that echo "mem" >>
/sys/power/state and, though a bit hacky, it works fine.

Here's the requested output:

** (xfce4-power-manager:9707): WARNING **: 18:43:58.202: Failed to get name
owner: GDBus.Error:org.freedesktop.DBus.Error.NameHasNoOwner: Could not get
owner of name 'org.freedesktop.PowerManagement': no such name


** (xfce4-power-manager:9707): WARNING **: 18:43:58.202: Failed to get name
owner: GDBus.Error:org.freedesktop.DBus.Error.NameHasNoOwner: Could not get
owner of name 'org.xfce.PowerManager': no such name


(xfce4-power-manager:9707): GLib-GObject-WARNING **: 18:43:58.215:
../../../gobject/gsignal.c:2523: signal 'Changed' is invalid for instance
'0x55599ae301b0' of type 'GDBusProxy'

(xfce4-power-manager:9707): xfce4-power-manager-WARNING **: 18:43:58.235:
could not map keysym 1008ffa8 to keycode

TRACE[xfpm-main.c:205] xfpm_start(): Starting the power manager
TRACE[xfpm-xfconf.c:165] xfpm_xfconf_load(): Using default configuration
for lock-screen-suspend-hibernate
TRACE[xfpm-xfconf.c:165] xfpm_xfconf_load(): Using default configuration
for critical-power-level
TRACE[xfpm-xfconf.c:165] xfpm_xfconf_load(): Using default configuration
for show-brightness-popup
TRACE[xfpm-xfconf.c:165] xfpm_xfconf_load(): Using default configuration
for handle-brightness-keys
TRACE[xfpm-xfconf.c:165] xfpm_xfconf_load(): Using default configuration
for hibernate-button-action
TRACE[xfpm-xfconf.c:165] xfpm_xfconf_load(): Using default configuration
for sleep-button-action
TRACE[xfpm-xfconf.c:165] xfpm_xfconf_load(): Using default configuration
for brightness-level-on-ac
TRACE[xfpm-xfconf.c:165] xfpm_xfconf_load(): Using default configuration
for brightness-level-on-battery
TRACE[xfpm-xfconf.c:165] xfpm_xfconf_load(): Using default configuration
for brightness-slider-min-level
TRACE[xfpm-xfconf.c:165] xfpm_xfconf_load(): Using default configuration
for dpms-enabled
TRACE[xfpm-xfconf.c:165] xfpm_xfconf_load(): Using default configuration
for dpms-sleep-mode
TRACE[xfpm-xfconf.c:165] xfpm_xfconf_load(): Using default configuration
for inactivity-on-ac
TRACE[xfpm-xfconf.c:165] xfpm_xfconf_load(): Using default configuration
for inactivity-sleep-mode-on-ac
TRACE[xfpm-xfconf.c:165] xfpm_xfconf_load(): Using default configuration
for network-manager-sleep
TRACE[xfpm-xfconf.c:165] xfpm_xfconf_load(): Using default configuration
for logind-handle-power-key
TRACE[xfpm-xfconf.c:165] xfpm_xfconf_load(): Using default configuration
for logind-handle-suspend-key
TRACE[xfpm-xfconf.c:165] xfpm_xfconf_load(): Using default configuration
for logind-handle-hibernate-key
TRACE[xfpm-xfconf.c:165] xfpm_xfconf_load(): Using default configuration
for heartbeat-command
TRACE[xfpm-dpms.c:75] xfpm_dpms_set_timeouts(): Settings dpms: standby=3600
suspend=0 off=3600

TRACE[xfpm-polkit.c:287] xfpm_polkit_init_data(): Using unix session polkit
subject
TRACE[xfpm-polkit.c:345] xfpm_polkit_check_auth_intern(): polkit request:
(('unix-process', {'pid': <uint32 9707>, 'start-time': <uint64 2432178>}),
'org.freedesktop.login1.power-off', @a{ss} {}, uint32 0, '')
TRACE[xfpm-polkit.c:366] xfpm_polkit_check_auth_intern():
Action=org.freedesktop.login1.power-off is authorized=TRUE
TRACE[xfpm-polkit.c:345] xfpm_polkit_check_auth_intern(): polkit request:
(('unix-process', {'pid': <uint32 9707>, 'start-time': <uint64 2432178>}),
'org.freedesktop.login1.reboot', @a{ss} {}, uint32 0, '')
TRACE[xfpm-polkit.c:366] xfpm_polkit_check_auth_intern():
Action=org.freedesktop.login1.reboot is authorized=TRUE
TRACE[xfpm-polkit.c:345] xfpm_polkit_check_auth_intern(): polkit request:
(('unix-process', {'pid': <uint32 9707>, 'start-time': <uint64 2432178>}),
'org.freedesktop.login1.suspend', @a{ss} {}, uint32 0, '')
TRACE[xfpm-polkit.c:366] xfpm_polkit_check_auth_intern():
Action=org.freedesktop.login1.suspend is authorized=TRUE
TRACE[xfpm-polkit.c:345] xfpm_polkit_check_auth_intern(): polkit request:
(('unix-process', {'pid': <uint32 9707>, 'start-time': <uint64 2432178>}),
'org.freedesktop.login1.hibernate', @a{ss} {}, uint32 0, '')
TRACE[xfpm-polkit.c:366] xfpm_polkit_check_auth_intern():
Action=org.freedesktop.login1.hibernate is authorized=TRUE
TRACE[xfpm-power.c:936] xfpm_power_get_power_devices(): Power device
detected at : /org/freedesktop/UPower/devices/line_power_AC
TRACE[xfpm-power.c:898] xfpm_power_add_device(): 'line-power' device added
TRACE[xfpm-power.c:936] xfpm_power_get_power_devices(): Power device
detected at : /org/freedesktop/UPower/devices/battery_BAT0
TRACE[xfpm-power.c:898] xfpm_power_add_device(): 'battery' device added
TRACE[xfpm-power.c:908] xfpm_power_add_device(): Battery device type
'battery' detected at: /org/freedesktop/UPower/devices/battery_BAT0
TRACE[xfpm-button.c:183] xfpm_button_xevent_key(): Grabbed key 124 :
((XfpmButtonKey) BUTTON_POWER_OFF)
TRACE[xfpm-button.c:183] xfpm_button_xevent_key(): Grabbed key 213 :
((XfpmButtonKey) BUTTON_HIBERNATE)
TRACE[xf
(xfce4-power-manager:9707): GLib-CRITICAL **: 18:43:58.247: g_error_free:
assertion 'error != NULL' failed

** (xfce4-power-manager:9707): WARNING **: 18:43:58.248: No outputs have
backlight property
xfce4-power-manager-Message: 18:43:58.264: Set kernel brightness switch to 0
xfce4-power-manager-Message: 18:44:04.142: Restored brightness switch value
to: 1

(xfce4-power-manager:9707): Gtk-WARNING **: 18:44:04.142: A floating object
was finalized. This means that someone
called g_object_unref() on an object that had only a floating
reference; the initial floating reference is not owned by anyone
and must be removed with g_object_ref_sink().

(xfce4-power-manager:9707): Gtk-WARNING **: 18:44:04.142: A floating object
was finalized. This means that someone
called g_object_unref() on an object that had only a floating
reference; the initial floating reference is not owned by anyone
and must be removed with g_object_ref_sink().
pm-button.c:183] xfpm_button_xevent_key(): Grabbed key 150 :
((XfpmButtonKey) BUTTON_SLEEP)
TRACE[xfpm-button.c:183] xfpm_button_xevent_key(): Grabbed key 233 :
((XfpmButtonKey) BUTTON_MON_BRIGHTNESS_UP)
TRACE[xfpm-button.c:183] xfpm_button_xevent_key(): Grabbed key 232 :
((XfpmButtonKey) BUTTON_MON_BRIGHTNESS_DOWN)
TRACE[xfpm-button.c:183] xfpm_button_xevent_key(): Grabbed key 244 :
((XfpmButtonKey) BUTTON_BATTERY)
TRACE[xfpm-button.c:183] xfpm_button_xevent_key(): Grabbed key 238 :
((XfpmButtonKey) BUTTON_KBD_BRIGHTNESS_UP)
TRACE[xfpm-button.c:183] xfpm_button_xevent_key(): Grabbed key 237 :
((XfpmButtonKey) BUTTON_KBD_BRIGHTNESS_DOWN)
TRACE[xfpm-power.c:936] xfpm_power_get_power_devices(): Power device
detected at : /org/freedesktop/UPower/devices/battery_BAT1
TRACE[xfpm-power.c:898] xfpm_power_add_device(): 'battery' device added
TRACE[xfpm-power.c:908] xfpm_power_add_device(): Battery device type
'battery' detected at: /org/freedesktop/UPower/devices/battery_BAT1
TRACE[xfpm-dpms.c:75] xfpm_dpms_set_timeouts(): Settings dpms: standby=1260
suspend=0 off=1560

TRACE[xfpm-dpms.c:348] xfpm_dpms_set_on_battery(): dpms on battery TRUE
TRACE[xfpm-power.c:1446] xfpm_update_blank_time(): Timeout: 10
TRACE[xfpm-power.c:1446] xfpm_update_blank_time(): Timeout: 10
TRACE[xfpm-power.c:213] xfpm_power_check_polkit_auth(): using logind
suspend backend
TRACE[xfpm-polkit.c:345] xfpm_polkit_check_auth_intern(): polkit request:
(('unix-process', {'pid': <uint32 9707>, 'start-time': <uint64 2432178>}),
'org.freedesktop.login1.suspend', @a{ss} {}, uint32 0, '')
TRACE[xfpm-polkit.c:366] xfpm_polkit_check_auth_intern():
Action=org.freedesktop.login1.suspend is authorized=TRUE
TRACE[xfpm-polkit.c:345] xfpm_polkit_check_auth_intern(): polkit request:
(('unix-process', {'pid': <uint32 9707>, 'start-time': <uint64 2432178>}),
'org.freedesktop.login1.hibernate', @a{ss} {}, uint32 0, '')
TRACE[xfpm-polkit.c:366] xfpm_polkit_check_auth_intern():
Action=org.freedesktop.login1.hibernate is authorized=TRUE
TRACE[xfpm-power.c:1446] xfpm_update_blank_time(): Timeout: 10
TRACE[xfpm-power.c:1446] xfpm_update_blank_time(): Timeout: 10
TRACE[xfpm-power.c:1446] xfpm_update_blank_time(): Timeout: 13
TRACE[xfpm-power.c:1446] xfpm_update_blank_time(): Timeout: 13
TRACE[xfpm-manager.c:645] xfpm_manager_inhibit_sleep_systemd(): Inhibiting
systemd sleep: handle-power-key:handle-suspend-key:handle-hibernate-key
TRACE[xfpm-backlight.c:256]
xfpm_backlight_brightness_on_ac_settings_changed(): Alarm on ac timeout
changed 120
TRACE[xfpm-backlight.c:277]
xfpm_backlight_brightness_on_battery_settings_changed(): Alarm on battery
timeout changed 120
TRACE[xfpm-main.c:68] xfpm_quit_signal(): sig 2
TRACE[xfpm-manager.c:939] xfpm_manager_stop(): Stopping
TRACE[xfpm-manager.c:266] xfpm_manager_quit(): Exiting
TRACE[xfpm-polkit.c:244] xfpm_polkit_free_data(): Destroying Polkit data




On Wed, Jun 3, 2020 at 2:27 PM Mark Hindley <mark@???> wrote:

> On Wed, Jun 03, 2020 at 12:04:32PM -0500, Michaela Merz wrote:
> >    Hey Mark - hope you are not doing all the work alone. Thanks for your
> >    help. Here is the requested policykit listing:
> >    ii  elogind                               241.4-2
> >          amd64        user, seat and session management daemon
> >    ii  gir1.2-polkit-1.0                     0.105-25+devuan8
> >           amd64        GObject introspection data for PolicyKit
> >    ii  libelogind0:amd64                     241.4-2
> >          amd64        user, seat and session management library
> >    ii  libpam-elogind:amd64                  241.4-2
> >          amd64        elogind PAM module
> >    ii  libpolkit-agent-1-0:amd64             0.105-25+devuan8
> >           amd64        PolicyKit Authentication Agent API
> >    ii  libpolkit-backend-1-0                 0.105-25+devuan8
> >           all          PolicyKit Authorization API
> >    ii  libpolkit-backend-elogind-1-0:amd64   0.105-25+devuan8
> >           amd64        PolicyKit backend API
> >    ii  libpolkit-gobject-1-0                 0.105-25+devuan8
> >           all          PolicyKit Authorization API
> >    ii  libpolkit-gobject-elogind-1-0:amd64   0.105-25+devuan8
> >           amd64        PolicyKit Authorization API
> >    ii  policykit-1                           0.105-25+devuan8
> >           amd64        framework for managing administrative policies and
> >    privileges
> >    ii  policykit-1-gnome                     0.105-7
> >          amd64        authentication agent for PolicyKit

>
> OK. That looks fine.
>
> So You need to use either xfce4-power-manager/pm-utils or elogind for
> this, but
> not both.
>
> Details are available at
> https://docs.xfce.org/xfce/xfce4-power-manager/faq and
> in man logind.conf(5) (particularly the HandleLidSwitch* options).
>
> How have you tried to set this up and exactly what doesn't work?
>
> Is xfce4-power-manager actually running?
>
> If it still isn't working please enable xfce4-power-manager debugging:
>
> xfce4-power-manager -q
> xfce4-power-manager --no-daemon --debug
>
> and see what it reports when it runs.
>
> Thanks.
>
> Mark
>