kde login screen: auto sleep option?

Is there some way to enable “sleep after x minutes” for the login screen?

I have some users complaining that it is “rather complicated” to initiate sleep on the login screen, and I must say it could be simpler (like a “sleep” button…).

My display manager upon boot is kdm. I’m on 11.4 (KDE 4.6). Anything for later versions is also appreciated, as I plan to switch to 12.2 when it “hit the shelves”.

Or could that be done with gdm?

Thanks.

On 07/29/2012 09:56 PM, p barill wrote:
> sleep on the login screen,

i’ve never had occasion to want to make the computer sleep while on the
login screen…but, i have often on the popup that comes after
immediately after clicking “Leave”

simple there: Just with the left mouse button click and hold it down
over the down facing arrow on the “Turn off the computer” button, and
select your choice of “Suspend to RAM” or “Suspend to Disk”

(i guess RAM = Hibernate and Disk = Sleep but i’m not able to find that
in the docs anywhere)

let us know if that works for your users…or if they really want to
sleep from the login screen…


dd

My guess is that the case for sleeping at the login screen is that at that moment in time nobody is loged in (the system is unused by desktop users, let us assume this system does not serve anything to other systems) and people are aware that the system is still consuming power and maybe making noise. But switching it off means booting when it is needed again and that takes more time then awakening to the login screen.

Thank you, but I was well aware of how to get it to sleep manually.

> (i guess RAM = Hibernate and Disk = Sleep but i’m not able to find that
> in the docs anywhere)

No. RAM = sleep, disk = hibernate.

Also the fact that it states “Restart computer?” adds to the confusion
when it has nothing to do with restaring!
Hence it would be simpler to have something like sleep after x minutes
on the logon screen.

On 07/29/2012 04:05 PM, dd@home.dk wrote:
> On 07/29/2012 09:56 PM, p barill wrote:
>> sleep on the login screen,
>
> i’ve never had occasion to want to make the computer sleep while on the
> login screen…but, i have often on the popup that comes after
> immediately after clicking “Leave”
>
> simple there: Just with the left mouse button click and hold it down
> over the down facing arrow on the “Turn off the computer” button, and
> select your choice of “Suspend to RAM” or “Suspend to Disk”
>
>
> let us know if that works for your users…or if they really want to
> sleep from the login screen…
>

On 07/29/2012 04:56 PM, hcvv wrote:
>
> My guess is that the case for sleeping at the login screen is that at
> that moment in time nobody is loged in (the system is unused by desktop
> users, let us assume this system does not serve anything to other
> systems) and people are aware that the system is still consuming power
> and maybe making noise. But switching it off means booting when it is
> needed again and that takes more time then awakening to the login
> screen.

That’s precisely what I had in mind.

KDM does not appear to have a sleep option. Don’t know which Desktop you are using but most used are KDM GDM and XDM. I did not look up the others but it is easy to do in Google.

Sounds like it may be a useful option so maybe you need to ask if someone can provide it in the appropriate mailing lists.

> Thank you, but I was well aware of how to get it to sleep manually.

would have been nice had that have been included in your initial post…

>> (i guess RAM = Hibernate and Disk = Sleep but i’m not able to find that
>> in the docs anywhere)
>
> No. RAM = sleep, disk = hibernate.

thanks, but i do wonder where you found that…it seems to me everyone
else was born knowing it… (ah, maybe they learned it in Windows and the
KDE hackers copied it from there, maybe…)

> Also the fact that it states “Restart computer?” adds to the confusion
> when it has nothing to do with restaring!
> Hence it would be simpler to have something like sleep after x minutes
> on the logon screen.

okay…i don’t guess there is an easy way to do as you wish–so you can
make a feature request to FATE at https://features.opensuse.org/

it sounds like a good feature, to me…if you include the reason you
what it…(otherwise you risk having the feature makers scratching their
head…like i did…but they will probably just ignore requests they
don’t understand the “Why?” about)

once the feature request is made come back here with a link to it and
other can vote for the new feature…and, maybe it will get done…

WAIT: on my KDE (maybe different from yours) if i go Personal Settings -
Configure Desktop > System Administration > Login Screen > Shutdown
(tab) > Commands (section) > Halt blank

i see “/sbin/shutdown -h -P now” which could as easily be an executable
script you write to (as root):

  • log out the current user
  • launch the login screen
  • the go to “sleep after x minutes”
  • exit script

of course, then you would have some users complaining that its too hard
to just shutdown for real…

so, you could put a “Shutdown” button on their desktop to really shut
down using “/sbin/shutdown -h -P now” in the command section of the
launcher…

WOW, you could put a “Go to Sleep” button on their desktop or in their
menu to link to the “sleep after x minutes” script…and not have to
wait for a developer to do it for you and all other KDE users (who may
never need it)!!!

or using the menu editor just build those features into your
organization’s menu…


dd

On 2012-07-29 22:05, dd@home.dk wrote:
> (i guess RAM = Hibernate and Disk = Sleep but i’m not able to find that in the docs anywhere)

No, hibernate is suspend to disk, sleep is s2ram.


Cheers / Saludos,

Carlos E. R.
(from 11.4 x86_64 “Celadon” at Telcontar)

On 07/29/2012 05:38 PM, dd@home.dk wrote:
> thanks, but i do wonder where you found that…it seems to me everyone
> else was born knowing it… (ah, maybe they learned it in Windows and the
> KDE hackers copied it from there, maybe…)

How I found that out? I tried, and noted what happens :slight_smile:

It makes sense when you think about it: hibernate is a kind of shutdown
as the computer powers off completely. That would erase anything on the
memory.

Also, when you click Menu then click (without holding) “Suspend
Computer”, it defaults to hibernate, which I find odd. Who uses it? Who
trusts it?? And there is no point to hibernate from the moment you have
an SSD: boot is faster and safer.

>> Also the fact that it states “Restart computer?” adds to the confusion
>> when it has nothing to do with restaring!
>> Hence it would be simpler to have something like sleep after x minutes
>> on the logon screen.
>
> okay…i don’t guess there is an easy way to do as you wish–so you can
> make a feature request to FATE at https://features.opensuse.org/
>
> it sounds like a good feature, to me…if you include the reason you
> what it…(otherwise you risk having the feature makers scratching their
> head…like i did…but they will probably just ignore requests they
> don’t understand the “Why?” about)
>
> once the feature request is made come back here with a link to it and
> other can vote for the new feature…and, maybe it will get done…
>
> WAIT: on my KDE (maybe different from yours) if i go Personal Settings -
> Configure Desktop > System Administration > Login Screen > Shutdown
> (tab) > Commands (section) > Halt blank
>
> i see “/sbin/shutdown -h -P now” which could as easily be an executable
> script you write to (as root):
>
> - log out the current user
> - launch the login screen
> - the go to “sleep after x minutes”
> - exit script
>
> of course, then you would have some users complaining that its too hard
> to just shutdown for real…
>
> so, you could put a “Shutdown” button on their desktop to really shut
> down using “/sbin/shutdown -h -P now” in the command section of the
> launcher…
>
> WOW, you could put a “Go to Sleep” button on their desktop or in their
> menu to link to the “sleep after x minutes” script…and not have to
> wait for a developer to do it for you and all other KDE users (who may
> never need it)!!!
>
> or using the menu editor just build those features into your
> organization’s menu…
>

When you speak of “button on their desktop”, are we still talking of the
login screen or the desktop screen inside a KDE session? For the latter,
all the necessary shortcuts are there in the kmenu.

That’s interesting, as you can change the default behavior of halt and
reboot quite easily, but you can’t add a button to the login screen.
Anyway what I’m looking for is a passive process.

I checked on another distro with KDE 4.8.4 (latest), and the login
manager utility is the same, except that it now uses “/sbin/shutdown -h
-P now” for halt while in 11.4 it’s just “/sbin/halt”. Not a big deal.

Thanks for suggesting this wishlist. hcvv above summarized my point. On
a multi-user machine, whether in a computer lab or at home, the common
usage is to return to the login screen when you’re done. If that machine
spends a lot of idle time, why keep it running? There are power settings
within any user profile, but seemingly not outside.

I deduce little need for this on a single-user machine. The only time I
see the login screen is when I boot. Whenever I logoff, it’s part of a
shutdown sequence or some occasional reboot…

Here:

https://features.opensuse.org/313842

Looks as a good feature wish with a clear explanation from your side.

I voted for it.

On 2012-07-30 04:01, p_barill wrote:

> It makes sense when you think about it: hibernate is a kind of shutdown
> as the computer powers off completely. That would erase anything on the
> memory.

Actually, no, because the memory is saved to disk.

> Also, when you click Menu then click (without holding) “Suspend
> Computer”, it defaults to hibernate, which I find odd. Who uses it? Who
> trusts it?? And there is no point to hibernate from the moment you have
> an SSD: boot is faster and safer.

I use it every day. It is much faster than booting with hard disks, specially considering that
I get the same desktop with all applications I had opened still opened on the same spot. Even
editors with opened, non saved files.

In fact, suspend to ram crashes my system immediately, I can not use it.

The snag is that when suspend/hibernate does not work, it is very difficult to solve.

> Thanks for suggesting this wishlist. hcvv above summarized my point. On
> a multi-user machine, whether in a computer lab or at home, the common
> usage is to return to the login screen when you’re done. If that machine
> spends a lot of idle time, why keep it running? There are power settings
> within any user profile, but seemingly not outside.

There is something you might try. Find out if the login display runs under a different user
(gdm runs under gdm, dunno about kdm). Then, do login as that user and setup the defaults for
that one. This works with gnome classic.


Cheers / Saludos,

Carlos E. R.
(from 11.4 x86_64 “Celadon” at Telcontar)

On Sun, 29 Jul 2012 20:05:13 GMT, dd@home.dk wrote:

>On 07/29/2012 09:56 PM, p barill wrote:
>> sleep on the login screen,
>
>i’ve never had occasion to want to make the computer sleep while on the
>login screen…but, i have often on the popup that comes after
>immediately after clicking “Leave”
>
>simple there: Just with the left mouse button click and hold it down
>over the down facing arrow on the “Turn off the computer” button, and
>select your choice of “Suspend to RAM” or “Suspend to Disk”
>
>(i guess RAM = Hibernate and Disk = Sleep but i’m not able to find that
>in the docs anywhere)

I don’t remember where i found it but sleep is to RAM or RAM and disk;
while hibernate is to disk. It has to do with wakeup time and power
requirements, with sleep taking more power but responds faster.
>
>let us know if that works for your users…or if they really want to
>sleep from the login screen…