Bug 70237 - logind: Allow active session to hibernate while other sessions are active
Summary: logind: Allow active session to hibernate while other sessions are active
Status: RESOLVED WONTFIX
Alias: None
Product: systemd
Classification: Unclassified
Component: general (show other bugs)
Version: unspecified
Hardware: Other All
: medium normal
Assignee: systemd-bugs
QA Contact: systemd-bugs
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2013-10-07 15:34 UTC by drago01
Modified: 2013-10-14 15:42 UTC (History)
3 users (show)

See Also:
i915 platform:
i915 features:


Attachments
Patch (1.34 KB, patch)
2013-10-07 15:35 UTC, drago01
Details | Splinter Review

Description drago01 2013-10-07 15:34:18 UTC
See patch.
Comment 1 drago01 2013-10-07 15:35:33 UTC
Created attachment 87245 [details] [review]
Patch
Comment 2 Lennart Poettering 2013-10-08 22:20:47 UTC
We can't really allow that by default. It's not OK to interrupt somebody else's work in the middle who's also active on the machine.

The hibernate-on-battery logic sounds like something that really should be solved on the system level. Doing this policy in user programs is wrong, I am pretty sure.
Comment 3 Bastien Nocera 2013-10-14 06:47:43 UTC
I've been working on patches to move that functionality from gnome-settings-daemon (or other user session managers) to UPower itself.

It will be broken in F20 as it was in F19.
Comment 4 drago01 2013-10-14 06:58:25 UTC
(In reply to comment #2)
> We can't really allow that by default. It's not OK to interrupt somebody
> else's work in the middle who's also active on the machine.
> 
> The hibernate-on-battery logic sounds like something that really should be
> solved on the system level. Doing this policy in user programs is wrong, I
> am pretty sure.

Yeah but the "evil" user can interrupt the work of the other users in that case by intentionally draining the battery. It takes a bit longer but has the same effect.
Comment 5 Bastien Nocera 2013-10-14 09:37:05 UTC
(In reply to comment #3)
> I've been working on patches to move that functionality from
> gnome-settings-daemon (or other user session managers) to UPower itself.

This is implemented in UPower master.
Comment 6 Lennart Poettering 2013-10-14 15:41:42 UTC
(In reply to comment #4)
> (In reply to comment #2)
> > We can't really allow that by default. It's not OK to interrupt somebody
> > else's work in the middle who's also active on the machine.
> > 
> > The hibernate-on-battery logic sounds like something that really should be
> > solved on the system level. Doing this policy in user programs is wrong, I
> > am pretty sure.
> 
> Yeah but the "evil" user can interrupt the work of the other users in that
> case by intentionally draining the battery. It takes a bit longer but has
> the same effect.

It's pretty hard to drain the battery on my desktop PC where power comes out of the wall. On that system hibernation is available, and we hence cannot allow them to hibernate the system at free will if somebody else is also logged in.
Comment 7 Lennart Poettering 2013-10-14 15:42:29 UTC
(In reply to comment #5)
> (In reply to comment #3)
> > I've been working on patches to move that functionality from
> > gnome-settings-daemon (or other user session managers) to UPower itself.
> 
> This is implemented in UPower master.

Thanks! I figure that means this bug is obsolete now. Closing.


Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.