Re: system now hibernates automatically 3 hours after suspend ?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]



On Wed, Sep 12, 2018 at 05:21:03PM +0000, Zbigniew Jędrzejewski-Szmek wrote:
> On Wed, Sep 12, 2018 at 08:58:46AM -0500, mcatanzaro@xxxxxxxxx wrote:
> > On Wed, Sep 12, 2018 at 8:44 AM, Matthias Clasen
> > <mclasen@xxxxxxxxxx> wrote:
> > >If it works, why should we make it configurable ? I don't think
> > >anybody wants their battery drained...
> > >What corner cases are you thinking of ?
> > 
> > Kamil is surely worried that the system will attempt to hibernate
> > and fail, leading to data loss. Historically, we have not exposed
> > hibernate to users precisely because we expect it to fail. (We are
> > even recently discussed getting rid of the swap partition!)
> > 
> > It looks like that would be a systemd or kernel bug, because we ask
> > systemd if hibernate is supported, and do not attempt to hibernate
> > at all if it's not. Hopefully systemd is right about that in
> > practice....
> 
> Systemd checks if there's a swap device and if there's enough space 
> on it to fit current RSS. If systemd returns true from
> org.freedesktop.login1.Manager.CanHibernate or
> org.freedesktop.login1.Manager.CanSuspendThenHibernate when those
> conditions are not satisfied, that would be a bug.
> It also has some other heuristics, e.g. hibernation should be disabled
> after a kernel upgrade. But systemd does not check if resume= is set.
> I'm sure that are other ways in which this detection is faulty.
> 
> In recent times hibernation support in systemd hasn't been getting
> much testing, so if it's to be used by default in gnome, more testing
> (and reports of bugs) would be very welcome.
> 
> It is possible to disable any suspend/hibernation mode using
> 'systemctl mask suspend.target/hibnerate.target/suspend-then-hibernate.target'.

After looking into this some more, I think enabling s2h by default in gnome
is risky:
- systemd does not check for resume=
- systemd does not check if the swap partition is encrypted
  (this was OK for "normal" hibernation, where the user is present,
   but becomes a problem with s2h)

Arguably those are bugs in systemd, but suddenly we're getting much
bigger exposure. So this should either be reverted in gnome for F29,
or systemd should quickly improve the checks for those two things...

[https://bugzilla.redhat.com/show_bug.cgi?id=1206936 is also related.
Anaconda started adding resume= by default, so for recently installed
systemd resume= will be present.]

Zbyszek
_______________________________________________
desktop mailing list -- desktop@xxxxxxxxxxxxxxxxxxxxxxx
To unsubscribe send an email to desktop-leave@xxxxxxxxxxxxxxxxxxxxxxx
Fedora Code of Conduct: https://getfedora.org/code-of-conduct.html
List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines
List Archives: https://lists.fedoraproject.org/archives/list/desktop@xxxxxxxxxxxxxxxxxxxxxxx




[Index of Archives]     [Fedora Users]     [Fedora KDE]     [Fedora Announce]     [Fedora Docs]     [Fedora Config]     [PAM]     [Red Hat Development]     [Red Hat 9]     [Gimp]     [Yosemite News]

  Powered by Linux