[opensuse-support] How can I hibernate in shutdown mode?
![](https://seccdn.libravatar.org/avatar/77cb4da5f72bc176182dcc33f03a18f3.jpg?s=120&d=mm&r=g)
Hi, some weeks ago I said I had crashes on restore from hibernation. Andrei Borzenkov told me to use HibernateMode=shutdown in systemd-sleep.conf. After reading man systemd-sleep.conf I fail to find a syntax that works. If I write Telcontar:~ # cat /etc/systemd/sleep.conf HibernateMode=shutdown Telcontar:~ # I get this message in syslog:
<4.4> 2019-02-28 03:52:59 Telcontar systemd-logind 1664 - - /etc/systemd/sleep.conf:1: Assignment outside of section. Ignoring.
So I add a section: Telcontar:~ # cat /etc/systemd/sleep.conf [sleep] HibernateMode=shutdown Telcontar:~ # Now I get: <4.4> 2019-03-01 03:50:49 Telcontar systemd-logind 1639 - - /etc/systemd/sleep.conf:1: Unknown section 'sleep'. Ignoring. So, what is the correct syntax? Manual page systemd-sleep.conf(5) says: The following options can be configured in the "[Sleep]" section of /etc/systemd/sleep.conf or a sleep.conf.d file: SuspendMode=, HibernateMode=, HybridSleepMode= So the section is correct, isn't it? I don't understand :-( -- Cheers / Saludos, Carlos E. R. (from 15.0 x86_64 at Telcontar)
![](https://seccdn.libravatar.org/avatar/11fc101abea99ba31b2b38ddcda5da99.jpg?s=120&d=mm&r=g)
On 2019-03-01 01:47 PM, Carlos E. R. wrote:
Hi,
some weeks ago I said I had crashes on restore from hibernation. Andrei Borzenkov told me to use
HibernateMode=shutdown
in systemd-sleep.conf. After reading man systemd-sleep.conf I fail to find a syntax that works.
If I write
Telcontar:~ # cat /etc/systemd/sleep.conf HibernateMode=shutdown Telcontar:~ #
I get this message in syslog:
<4.4> 2019-02-28 03:52:59 Telcontar systemd-logind 1664 - - /etc/systemd/sleep.conf:1: Assignment outside of section. Ignoring. So I add a section:
Telcontar:~ # cat /etc/systemd/sleep.conf [sleep] HibernateMode=shutdown Telcontar:~ #
Now I get:
<4.4> 2019-03-01 03:50:49 Telcontar systemd-logind 1639 - - /etc/systemd/sleep.conf:1: Unknown section 'sleep'. Ignoring.
So, what is the correct syntax?
Manual page systemd-sleep.conf(5) says:
The following options can be configured in the "[Sleep]" section of /etc/systemd/sleep.conf or a sleep.conf.d file:
SuspendMode=, HibernateMode=, HybridSleepMode=
So the section is correct, isn't it? I don't understand :-(
Maybe it's case sensitive? Try using [Sleep] instead of [sleep] -- To unsubscribe, e-mail: opensuse-support+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse-support+owner@opensuse.org
![](https://seccdn.libravatar.org/avatar/77cb4da5f72bc176182dcc33f03a18f3.jpg?s=120&d=mm&r=g)
On 01/03/2019 21.01, Darryl Gregorash wrote:
On 2019-03-01 01:47 PM, Carlos E. R. wrote:
Manual page systemd-sleep.conf(5) says:
The following options can be configured in the "[Sleep]" section of /etc/systemd/sleep.conf or a sleep.conf.d file:
SuspendMode=, HibernateMode=, HybridSleepMode=
So the section is correct, isn't it? I don't understand :-(
Maybe it's case sensitive? Try using [Sleep] instead of [sleep]
That would astonish me, but yes, I have done that change, after posting. I don't know how to test unless hibernating, and as it can crash I try to avoid it. Later this night. -- Cheers / Saludos, Carlos E. R. (from 15.0 x86_64 at Telcontar)
![](https://seccdn.libravatar.org/avatar/77cb4da5f72bc176182dcc33f03a18f3.jpg?s=120&d=mm&r=g)
On 01/03/2019 21.14, Carlos E. R. wrote:
On 01/03/2019 21.01, Darryl Gregorash wrote:
On 2019-03-01 01:47 PM, Carlos E. R. wrote:
Manual page systemd-sleep.conf(5) says:
The following options can be configured in the "[Sleep]" section of /etc/systemd/sleep.conf or a sleep.conf.d file:
SuspendMode=, HibernateMode=, HybridSleepMode=
So the section is correct, isn't it? I don't understand :-(
Maybe it's case sensitive? Try using [Sleep] instead of [sleep]
That would astonish me, but yes, I have done that change, after posting. I don't know how to test unless hibernating, and as it can crash I try to avoid it. Later this night.
Apparently, that was it :-( No message today in log. Let's hope that it also solves the crashes. -- Cheers / Saludos, Carlos E. R. (from 15.0 x86_64 at Telcontar)
![](https://seccdn.libravatar.org/avatar/c8b49a7a57ae09cd5482d4a4ac5bb593.jpg?s=120&d=mm&r=g)
On 2019-03-01 20:47, Carlos E. R. wrote:
Telcontar:~ # cat /etc/systemd/sleep.conf HibernateMode=shutdown Telcontar:~ #
Don't *.conf need sections? Like [Sleep] or similar. ex. [Sleep] HibernateMode=shutdown ref. man systemd.syntax -- /bengan -- To unsubscribe, e-mail: opensuse-support+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse-support+owner@opensuse.org
![](https://seccdn.libravatar.org/avatar/c8b49a7a57ae09cd5482d4a4ac5bb593.jpg?s=120&d=mm&r=g)
Ignore that. Answered before I read the message. On 2019-03-02 10:49, Bengt Gördén wrote:
On 2019-03-01 20:47, Carlos E. R. wrote:
Telcontar:~ # cat /etc/systemd/sleep.conf HibernateMode=shutdown Telcontar:~ #
Don't *.conf need sections? Like [Sleep] or similar.
ex. [Sleep] HibernateMode=shutdown
ref. man systemd.syntax
-- /bengan -- To unsubscribe, e-mail: opensuse-support+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse-support+owner@opensuse.org
![](https://seccdn.libravatar.org/avatar/28fb60f36a5c05d6e95d00be1c0c257c.jpg?s=120&d=mm&r=g)
Le 02/03/2019 à 10:50, Bengt Gördén a écrit :
Ignore that. Answered before I read the message.
On 2019-03-02 10:49, Bengt Gördén wrote:
On 2019-03-01 20:47, Carlos E. R. wrote:
Telcontar:~ # cat /etc/systemd/sleep.conf HibernateMode=shutdown Telcontar:~ #
Don't *.conf need sections? Like [Sleep] or similar.
ex. [Sleep] HibernateMode=shutdown
ref. man systemd.syntax
but may be the [Sleep] is necessary?? sometime syntax is cryptic :!-( jdd -- http://dodin.org -- To unsubscribe, e-mail: opensuse-support+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse-support+owner@opensuse.org
participants (4)
-
Bengt Gördén
-
Carlos E. R.
-
Darryl Gregorash
-
jdd@dodin.org