Bug 1275063 - UPower does not honor CriticalPowerAction even if sleep.conf is present
UPower does not honor CriticalPowerAction even if sleep.conf is present
Status: CLOSED EOL
Product: Fedora
Classification: Fedora
Component: upower (Show other bugs)
23
Unspecified Unspecified
unspecified Severity unspecified
: ---
: ---
Assigned To: Richard Hughes
Fedora Extras Quality Assurance
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2015-10-25 09:55 EDT by sandeep
Modified: 2016-12-20 10:09 EST (History)
1 user (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2016-12-20 10:09:01 EST
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)
sleep.conf (192 bytes, text/plain)
2015-10-25 09:58 EDT, sandeep
no flags Details
UPower.conf (2.60 KB, text/plain)
2015-10-25 09:58 EDT, sandeep
no flags Details

  None (edit)
Description sandeep 2015-10-25 09:55:49 EDT
This problem originated from an attempt to get the laptop to suspend when battery is about to die. For whatever reason my laptop does not hibernate... and neither does it hybrid sleep (tested using sudo /usr/lib/systemd/systemd-sleep hybrid-sleep). 
Remember that UPower.conf has only 3 options for CriticalPowerAction: PowerOff, Hibernate, HybridSleep. Since the last two dont work, each and every time my laptop shuts off. I would rather that the laptop suspends and gives me even 15 minutes to find a power socket.

To fix this, I created a sleep.conf and HybridSleepMode=suspend platform
HybridSleepState=mem. This works perfectly on commandline. When I run "sudo /usr/lib/systemd/systemd-sleep hybrid-sleep", the laptop suspends. However, UPower will not accept the CriticalPowerAction=HybridSleep configuration. It is still taken as PowerOff (as can be seen from "upower -d"). I have rebooted multiple times to get the settings change to take effect.

As it stands right now, there seems to be no way to get UPower to suspend my laptop on low battery. This is a serious problem for us.


Attached UPower.conf and sleep.conf


>cat /sys/power/disk 
[platform] shutdown reboot suspend 

upower -d

Device: /org/freedesktop/UPower/devices/line_power_AC
  native-path:          AC
  power supply:         yes
  updated:              Sun 25 Oct 2015 05:14:48 PM IST (6919 seconds ago)
  has history:          no
  has statistics:       no
  line-power
    warning-level:       none
    online:              yes
    icon-name:          'ac-adapter-symbolic'

Device: /org/freedesktop/UPower/devices/battery_BAT0
  native-path:          BAT0
  vendor:               Panasonic
  model:                45N1143
  serial:               2050
  power supply:         yes
  updated:              Sun 25 Oct 2015 07:08:48 PM IST (79 seconds ago)
  has history:          yes
  has statistics:       yes
  battery
    present:             yes
    rechargeable:        yes
    state:               charging
    warning-level:       none
    energy:              34.4 Wh
    energy-empty:        0 Wh
    energy-full:         43.28 Wh
    energy-full-design:  43.29 Wh
    energy-rate:         6.02973 W
    voltage:             12.4 V
    time to full:        1.5 hours
    percentage:          79%
    capacity:            99.9769%
    technology:          lithium-ion
    icon-name:          'battery-full-charging-symbolic'

Device: /org/freedesktop/UPower/devices/battery_BAT1
  native-path:          BAT1
  vendor:               SONY
  model:                45N1041
 serial:               1441
  power supply:         yes
  updated:              Sun 25 Oct 2015 07:08:48 PM IST (79 seconds ago)
  has history:          yes
  has statistics:       yes
  battery
    present:             yes
    rechargeable:        yes
    state:               charging
    warning-level:       none
    energy:              21.02 Wh
    energy-empty:        0 Wh
    energy-full:         31.01 Wh
    energy-full-design:  31.32 Wh
    energy-rate:         22.173 W
    voltage:             12.13 V
    time to full:        27.0 minutes
    percentage:          67%
    capacity:            99.0102%
    technology:          lithium-polymer
    icon-name:          'battery-full-charging-symbolic'
  History (charge):
    1445780328  67.000  charging
  History (rate):
    1445780328  22.173  charging

Device: /org/freedesktop/UPower/devices/DisplayDevice
  power supply:         yes
  updated:              Sun 25 Oct 2015 07:08:48 PM IST (79 seconds ago)
  has history:          no
  has statistics:       no
  battery
    present:             yes
    state:               charging
    warning-level:       none
    energy:              55.42 Wh
    energy-full:         74.29 Wh
    energy-rate:         28.2027 W
    time to full:        40.1 minutes
    percentage:          74.5995%
    icon-name:          'battery-full-charging-symbolic'

Daemon:
  daemon-version:  0.99.3
  on-battery:      no
  lid-is-closed:   no
  lid-is-present:  yes
  critical-action: PowerOff


                                                                                                                                                              


Description of problem:


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


How reproducible:


Steps to Reproduce:
1.
2.
3.

Actual results:


Expected results:


Additional info:
Comment 1 sandeep 2015-10-25 09:58 EDT
Created attachment 1086218 [details]
sleep.conf
Comment 2 sandeep 2015-10-25 09:58 EDT
Created attachment 1086219 [details]
UPower.conf
Comment 3 sandeep 2016-07-28 00:53:30 EDT
I just want to highlight that this issue continues to haunt us. I'm now on a Dell XPS 13 that anyway has some kernel issues.

Configuring hibernate does not work (even after putting the resume parameter. The error shown on trying to hibernate is "Failed to hibernate system via logind: Sleep verb not supported")

 I hope you understand the issue here - I would have been perfectly happy with suspend (which works beautifully on my machine) and I'm willing to assume the risk that I dont find a power adapter within X minutes. As opposed to right now :(
Comment 4 Fedora End Of Life 2016-11-24 07:54:26 EST
This message is a reminder that Fedora 23 is nearing its end of life.
Approximately 4 (four) weeks from now Fedora will stop maintaining
and issuing updates for Fedora 23. It is Fedora's policy to close all
bug reports from releases that are no longer maintained. At that time
this bug will be closed as EOL if it remains open with a Fedora  'version'
of '23'.

Package Maintainer: If you wish for this bug to remain open because you
plan to fix it in a currently maintained version, simply change the 'version' 
to a later Fedora version.

Thank you for reporting this issue and we are sorry that we were not 
able to fix it before Fedora 23 is end of life. If you would still like 
to see this bug fixed and are able to reproduce it against a later version 
of Fedora, you are encouraged  change the 'version' to a later Fedora 
version prior this bug is closed as described in the policy above.

Although we aim to fix as many bugs as possible during every release's 
lifetime, sometimes those efforts are overtaken by events. Often a 
more recent Fedora release includes newer upstream software that fixes 
bugs or makes them obsolete.
Comment 5 Fedora End Of Life 2016-12-20 10:09:01 EST
Fedora 23 changed to end-of-life (EOL) status on 2016-12-20. Fedora 23 is
no longer maintained, which means that it will not receive any further
security or bug fix updates. As a result we are closing this bug.

If you can reproduce this bug against a currently maintained version of
Fedora please feel free to reopen this bug against that version. If you
are unable to reopen this bug, please file a new report against the
current release. If you experience problems, please add a comment to this
bug.

Thank you for reporting this bug and we are sorry it could not be fixed.

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