Gentoo Archives: gentoo-user

From: "Canek Peláez Valdés" <caneko@×××××.com>
To: Volker Armin Hemmann <volkerarmin@××××××××××.com>
Cc: gentoo-user@l.g.o
Subject: Re: [gentoo-user] Re: Suspend to {RAM,Disk]
Date: Fri, 18 May 2012 23:47:21
Message-Id: CADPrc83KNYHdaLSmL=91rDWEoDo-NcLnx0Vm=aKD9ibg6STkew@mail.gmail.com
In Reply to: Re: [gentoo-user] Re: Suspend to {RAM,Disk] by "Canek Peláez Valdés"
1 On Fri, May 18, 2012 at 6:36 PM, Canek Peláez Valdés <caneko@×××××.com> wrote:
2 > On Fri, May 18, 2012 at 5:37 PM, Volker Armin Hemmann
3 > <volkerarmin@××××××××××.com> wrote:
4 >> Am Freitag, 18. Mai 2012, 17:26:10 schrieb Canek Peláez Valdés:
5 >>> On Fri, May 18, 2012 at 5:09 PM, Volker Armin Hemmann
6 >>>
7 >>> <volkerarmin@××××××××××.com> wrote:
8 >>> > Am Freitag, 18. Mai 2012, 22:42:59 schrieb Ignas Anikevicius:
9 >>> >> On 18/05/12 20:59, Alex Schuster wrote:
10 >>> >> > Suspend to ram (using the hibernate-ram command from
11 >>> >> > sys-power/hibernate-script) seems to work better.
12 >>> >>
13 >>> >> What about pm-utils? Does it work better or worse than hibernate-script.
14 >>> >> I had 0 problems with it during entire usage of linux, whereas with the
15 >>> >> hibernate script package I had some issues...
16 >>> >>
17 >>> >> And yes, I am usually suspending to ram, but I was just thinking about
18 >>> >> possibilities to make my computer boot faster in the cases I really need
19 >>> >> to do a restart. :)
20 >>> >>
21 >>> >> Cheers,
22 >>> >> Ignas
23 >>> >
24 >>> > I just do echo mem > ... or click on the 'Ruhezustand' button in KDE.
25 >>> > Results in the same. Well working suspend-to-ram. With fglrx. X running
26 >>> > etc pp.
27 >>> With upower to suspend-to-ram you can just:
28 >>>
29 >>> dbus-send --system --print-reply --dest="org.freedesktop.UPower"
30 >>> /org/freedesktop/UPower org.freedesktop.UPower.Suspend
31 >>>
32 >>
33 >> which is way harder to type and memorize than:
34 >> echo mem > /sys/power/state
35 >
36 > Yeah. However, he Dbus method works as a simple user; the
37 > /sys/power/state thing you can only do it as root. At least in my
38 > system.
39 >
40 >>> or use the "Suspend" option in GNOME 3 (GNOME uses upower). That I
41 >>> already knew. What I didn't knew was that
42 >>>
43 >>> dbus-send --system --print-reply --dest="org.freedesktop.UPower"
44 >>> /org/freedesktop/UPower org.freedesktop.UPower.Hibernate
45 >>>
46 >>> works as well for suspend-to-disk. I hadn't hibernated my laptop in
47 >>> ages, it's good to know it still works. I use systemd+> dracut, which I
48 >>> suppose it matters for the hibernate option.
49 >>
50 >> no, not really...
51 >
52 > The restore-from-hibernate requires booting the kernel in a special
53 > way to load the memory state from the swap partition. That requires
54 > special handling from the init process and the initramfs; we had a
55 > discussion some weeks ago about genkernel not handling this correctly.
56 >
57 > Maybe systemd has nothing to do with restore-from-hibernate working (I
58 > don't know)
59
60 Oh, and less than two weeks ago systemd added suspend/hibernate targets on git:
61
62 http://cgit.freedesktop.org/systemd/systemd/commit/?id=6edd7d0a09171ea5ae8e01b7b1cbcb0bdfbfeb16
63
64 Which of course is not necessary for suspend/hibernate to work, but it
65 is cool nonetheless.
66
67 Regards.
68 --
69 Canek Peláez Valdés
70 Posgrado en Ciencia e Ingeniería de la Computación
71 Universidad Nacional Autónoma de México