HOWTO: suspend/hibernate kernel 3.0.0-1

Archived topics about LMDE 1 and LMDE 2
Locked
Bill_KY

HOWTO: suspend/hibernate kernel 3.0.0-1

Post by Bill_KY »

I had trouble with suspend/hibernate on a new LMDE installation with kernel 3.0.0-1. I searched the forum and put together solutions from several threads. Here is how I got suspend/hibernate working properly with kernel 3.0.0-1 on my System 76 Pangolin PanP4 laptop. I hope it helps someone else!

inxi short-form reports my system as:
CPU[-Dual core Intel Core2 Duo T6400 (-MCP-) clocked at 1200.000 Mhz-] Kernel[-3.0.0-1-amd64 x86_64-] Up[-20 min-] Mem[-288.6/3018.4MB-] HDD[-250.1GB(38.1% used)-] Procs[-126-] Client[-Shell-] inxi[-1.4.23-]
Graphics are nVidia G93. Ethernet is Realtek, wireless is Intel. Swap-file is 2X installed RAM. I do not have consistent results with suspend/hibernate on any Linux distro unless my swap file is this large. Check yours and be certain it is sufficient in size.

Initially neither suspend nor hibernate would work. Both would shutdown X, disconnect the keyboard and leave a blinking horizontal cursor in the upper left corner and go no further. There turned out to be two parts to this problem, both of which must be solved for suspend/hibernate to work.

1. /etc/initramfstools/conf.d/resume must contain the proper UUID for your swap-file. You can determine this by opening a terminal and doing:
sudo blkid
You should see a list of UUID numbers for each of your partitions, one of which will be your swap file. Note that these are in the form UUID="123ab456 ..." Those quote marks are going to disappear as you work through this, so ignore those and just check that the number given by blkid matches the number in your resume file.

My resume file initially contained the UUID number for my Home partition, why I do not know. If yours is incorrect as mine was, open a terminal and do:
sudo update-initramfs -u
Now check the resume file again using Nautilus. You should see a string in this form, UUID=1234abc5678... There will be no quote marks. If the number now matches the number given for your swap file by blkid you are good. Close up and we'll go to step two.

2. Every other time that I have solved this problem, pointing to the correct swap-file has done the trick. Not so with LMDE oddly enough. It seems that we must both configure and use your wireless capability. (I tested this to be certain. Merely configuring your wireless will not be enough.)

So if you have not done it use "edit connections" and fully configure your wireless capability. Then check the box that makes it available to "any user" so that it will start by default. This is important. Now when you start LMDE your wireless will be active even if you usually connect using Ethernet. Together with the UUID fix, if you needed it, this should allow both hibernate and suspend work for you though I cannot explain why it does.

3. Now let's test one more time. We will do suspend first. You should get a full suspend using either the power-off menu or by closing your laptop lid. If closing your lid does not work, then check your Power Management Preferences to make sure you have it selected. It then should work. To resume just raise the lid. You should hear your HDD spin up at which point just tap your space-bar. You will be asked for your password to unlock your desktop and back in you will go.

Hibernate is slower but it should work. First make certain you open at least one application on your desktop. (I opened both Abiword and Gnumeric, which I use.) Select Hibernate from your Quit menu. X will turn off immediately (the dreaded horizontal cursor returns!), then the HDD will spin up as it writes your RAM contents to the HDD and then your machine will power-down. To resume press your power key once. Your machine will come up and boot GRUB. Select LMDE and log in as you normally do. This is going to look like a normal cold start but the difference here is that your desktop will show your open applications just as you left them. In other words Hibernate has done a resume just as it should.

Note that I do not know if this fix will survive a future kernel upgrade. If it does not the culprit probably will be the resume file pointing to the wrong partition once again. So we may have to fix that when we do a kernel upgrade. Time will tell.

One last point: If you do an update/upgrade and you have both Ethernet and Wireless active, turn off the wireless. In my earlier experience with sidux timing differences between the two corrupted compressed downloads. Then if you anticipate using either suspend or hibernate just make certain that Wireless is active.
Last edited by LockBot on Wed Dec 28, 2022 7:16 am, edited 4 times in total.
Reason: Topic automatically closed 6 months after creation. New replies are no longer allowed.
User avatar
xenopeek
Level 25
Level 25
Posts: 29460
Joined: Wed Jul 06, 2011 3:58 am

Re: [solved] LMDE suspend/hibernate kernel 3.0.0-1

Post by xenopeek »

Moved here by moderator
Image
DataMan

Re: HOWTO: suspend/hibernate kernel 3.0.0-1

Post by DataMan »

Beyond the correct uuid, the resume should be adjusted to the correct protocol as in

Code: Select all

#RESUME=UUID=blah-blah-blah-original-uuid
RESUME=/dev/disk/by-uuid/blah-blah-blah-correct-uuid
-DataMan
Bill_KY

Re: HOWTO: suspend/hibernate kernel 3.0.0-1

Post by Bill_KY »

Thanks Dataman, but I am not sure I know what this means. When I opened /etc/initramfstools/conf.d/resume I saw nothing in it but the line UUID=1234....., so all I did was replace that UUID number with the correct number for my swap file. That has seemed to work.

So now what are you proposing we should write and where should we put it? Sorry to be dense. I have a bad cold so I might not be thinking clearly at the moment!
DataMan

Re: HOWTO: suspend/hibernate kernel 3.0.0-1

Post by DataMan »

As long as it is now working, you don't need to "fix it" :lol: . In some cases (reasons unknown), the protocol detailed above is also required.

-DataMan
Bill_KY

Re: HOWTO: suspend/hibernate kernel 3.0.0-1

Post by Bill_KY »

I am back with a clearer head -- thank goodness! -- and an addition to my original how-to. Recall I said that for suspend/resume to work wireless must be both configured and operating. I have since tested that assertion many times if only because I tend to forget to turn on my wireless capability when I have an Ethernet link. There is no doubt that is true.

But I did not test to see what happens if wireless is configured and working and Ethernet is down. In fact suspend/resume will work as it should in this case and it has done so now over many tests.

So the problem would seem to involve the iwlagn module in the present kernel? A more technically literate person than I might be able to fool with this, confirm my diagnosis and perhaps propose a simple fix?

For what it is worth I do not care much for Gnome 3 in any of its various guises but if I run it on this machine (as I have most recently with Debian Testing) suspend/resume will work exactly as it should.

Hmmm, what do the Debianistas know that the Mintians do not?
DataMan

Re: HOWTO: suspend/hibernate kernel 3.0.0-1

Post by DataMan »

For what it is worth I do not care much for Gnome 3 in any of its various guises...
Mint Debian Xfce might be a viable alternative. I'm currently testing a developmental Xfce build and am able to configure the desktop pretty close to what I'm running in Mint 10 Gnome.

-DataMan
donv
Level 1
Level 1
Posts: 18
Joined: Mon Oct 04, 2010 5:38 pm

Re: HOWTO: suspend/hibernate kernel 3.0.0-1

Post by donv »

Thanks for the post, making the UUID match my swap partition worked for me on my EeePC 1000HA. For those following, please note in step 1 the correct directory (on my new LMDE Mate 201204 installation) is not /etc/initramfstools/ but rather /etc/initramfs-tools/ . So the correct file to check/edit is actually

Code: Select all

/etc/initramfs-tools/conf.d/resume
.
Image
LM20/Ulyana MATE on ASRock AB350M PRO4/AMD Ryzen 2200G and Acer Aspire E5-575-33BM
LMDE3 on Asus EeePC 1000HA
LMDE1(!) on ASUS AT3IONT-I DELUXE (HTPC)
Locked

Return to “LMDE Archive”