Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place. |
Notices |
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
Are you new to LinuxQuestions.org? Visit the following links:
Site Howto |
Site FAQ |
Sitemap |
Register Now
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
|
|
|
11-07-2002, 06:34 AM
|
#1
|
Member
Registered: Oct 2002
Location: Norway
Distribution: Gentoo
Posts: 36
Rep:
|
Hibernation and suspend to disk
Using Linux (Redhat 8.0) on my laptop, hibernation or suspend to disk where the OS writes everything in RAM to disk and then shuts completely off, is an important feature. I've searched the web, this forum, linux-laptop.net and several other resources, and I'm still stumped.
Main questions are:
Does hibernation/suspend2disk require a supend-partition (primary?) or is a hibernation file (like Windoze uses) sufficient?
I've read that it's not possible to hibernate linux if your bootloader (grub in my case) is located in MBR (also my case), and only possible if it's located on /boot. Is this the case, and if, how do I move my bootloader from MBR to /boot?
Assuming the above problems are solved, what exactly do I have to do to make my linux hibernate? Is there a utility available to make all the appropriate arrangement?
As you've probably understood by now, hibernation/suspend2disk is something I really want to make work, and if anyone have any input at all, it'll be greatly appreciated.
Sorry about the bad english (not my native language), and thanks for reading!
|
|
|
11-07-2002, 07:10 AM
|
#2
|
Senior Member
Registered: Jul 2001
Location: 406292E 290755N
Distribution: GNU/Linux Slackware 8.1, Redhat 8.0, LFS 4.0
Posts: 1,004
Rep:
|
Hello Slasher, welcome to LQ.org
Firstly, in your profile on this forum, it's best to include what distro you're using I know you say it's redhat but as this post gets further down the page, people will have to scroll up and down.
I have grub in the MBR and hibernation works fine. I close the lid to my laptop and it goes into standby. It wakes when I open it and starts the cardbus up too.
It has to be enabled in your kernel. Redhat 8.0 includes it by default I believe, so if your BIOS has it, it should be enabled. What laptop are you running?
|
|
|
11-07-2002, 07:18 AM
|
#3
|
Member
Registered: Oct 2002
Location: Curitiba - Brazil
Distribution: Conectiva
Posts: 334
Rep:
|
Hi Slasher,
You could use a program called apm (Advanced Power Management daemon) It can watch your notebook's battery and warn all users when the battery is low, and suspend activi ty too.
I belive grub in MBR has nothing to to with but you could check the man to have sure.
It's in a theres a package called apmd-<version>.
I hopes this help you...
|
|
|
11-07-2002, 07:26 AM
|
#4
|
Member
Registered: Oct 2002
Location: Norway
Distribution: Gentoo
Posts: 36
Original Poster
Rep:
|
Hi, thanks for replying Bert and vladkrack.
Forgot to metion, but suspend and apm works fine, I can suspend the machine manually, automaticly or by closing the lid.
The difference between suspend and suspend to disk is that suspend never shut down the entire machine, i.e keeping information in ram (draws power), while suspend to disk copies everything to disk and shuts down completely.
Sorry if I caused any misunderstanding.
Edit: The machin is a Dell Inspiron 4100, I830M.
Last edited by Slasher; 11-07-2002 at 07:33 AM.
|
|
|
11-15-2002, 02:49 AM
|
#5
|
LQ Newbie
Registered: Aug 2002
Posts: 11
Rep:
|
I am looking to do a "hibernate" feature with linux so i can dump winxp (right now its just so conveninent to be running in 15sec). can i do this with Red Hat 7.3?? If so, how? If not, how can i do it in Red hat 8 .. .which I could download :-)
-Mike
|
|
|
12-19-2002, 10:41 AM
|
#6
|
Member
Registered: Sep 2002
Location: New Hampshire
Distribution: RH8.0
Posts: 55
Rep:
|
Slasher, did you ever get this to work? I too would like to get hibernate working on my Portege 7200.
|
|
|
12-19-2002, 04:17 PM
|
#7
|
Member
Registered: Oct 2002
Location: Norway
Distribution: Gentoo
Posts: 36
Original Poster
Rep:
|
No, never found out how. Still searching....
|
|
|
12-19-2002, 05:04 PM
|
#8
|
Senior Member
Registered: Jul 2001
Location: 406292E 290755N
Distribution: GNU/Linux Slackware 8.1, Redhat 8.0, LFS 4.0
Posts: 1,004
Rep:
|
These folks have a few suggestions, and a few got it working ...
Bert
|
|
|
12-19-2002, 05:09 PM
|
#9
|
Member
Registered: Oct 2002
Location: Norway
Distribution: Gentoo
Posts: 36
Original Poster
Rep:
|
True, checked it out som time ago. But I got the impression that it wasn't One good solution, but more tweaking and tuning to get it to work. And it isn't clear whether it's necessary to have a hibernation partition or not. That's why I'm still searching
|
|
|
12-24-2002, 09:19 AM
|
#10
|
Member
Registered: Sep 2002
Location: New Hampshire
Distribution: RH8.0
Posts: 55
Rep:
|
I've read about "swsusp" patches for the Linux kernel, which is "suspend to disk", I think is the same as hibernate (?).
One thread says (I quote):
>>On many laptops, the suspend-to-disk feature is controlled by the BIOS and requires a FAT partition as the first partition on the disk. A DOS utility or its Linux equivalent "phdisk" writes a file ~ the size of the machine's RAM that's composed of contiguous sectors to this partition, then writes the location of the start and end sectors to some secret place in the NVRAM. Then you can trigger the suspend-to-disk feature with a special key sequence regardless of what OS you're running, often Fn-F12.
>>If that doesn't work, the "swsusp" patches for the Linux kernel add similar functions that take slightly longer to complete, but work everywhere.
--
but being a Linux newbie, I'm pretty intimidated by this. And I'd rather work on my laptop than have to repartition and start over.
|
|
|
12-25-2002, 04:38 PM
|
#11
|
Member
Registered: Oct 2002
Location: Norway
Distribution: Gentoo
Posts: 36
Original Poster
Rep:
|
I agree. I'm probably gonna wait for a kernel with ACPI support, and hopefully every issue is gonna vanish :P
|
|
|
08-24-2003, 05:06 PM
|
#12
|
LQ Newbie
Registered: Aug 2002
Posts: 11
Rep:
|
It has been a while since this thread was touched, and I never got around to installing Linux because of this issue.
Now that Red Hat Linux 9.0 is out, is there any ACPI support? What about the original issue of suspend-to-disk, where the RAM contents are written to the harddrive so that the machine boots faster by restoring everything?
|
|
|
08-24-2003, 05:17 PM
|
#13
|
Member
Registered: Oct 2002
Location: Norway
Distribution: Gentoo
Posts: 36
Original Poster
Rep:
|
gig103, to get ACPI in RH 9, one needs to compile it afterwards, there is no generic ACPI support in RH 9.0 (at least to my knowledge). The next RH release will be based on kernel 2.4.21 (I think), which has much better ACPI support (most of the ACPI work done for kernel 2.5 and 2.6 have been inkluded in 2.4.21). Think I got that correct
Anyways, if ACPI is a key issue, and you don't vant to compile the lot on your own, it would be wise to either wait for the next RH release or consider another distro.
|
|
|
09-01-2003, 11:23 AM
|
#15
|
Member
Registered: Jun 2003
Location: Canada
Distribution: Red Hat 9
Posts: 94
Rep:
|
just as a reminder, the swsusp patch needs a plain vanilla kernel; it won't work with the RH9 kernel source.
A really brief howto:
1. download a vanilla kernel source from www.kernel.org.
2. su to root.
3. cd /usr/src
4. tar -zxvf kerelxxxxx.gz or tar -jxvf kernelxxxxx.bz2
5. ln -s /usr/src/the_new_kernel /usr/src/linux
6. download the current swsusp patch from http://sourceforge.net/project/showf...group_id=25964.
7. bzip2 -dc < /path_to_the_swsusp_patch | patch -p1
8. make xconfig, enable the software suspend in the general setup section. (plus properly configuring ur kernel, you can find more help from the forum)
9. make dep clean bzImage
10. install the new kernel.
11. download the suspend script from http://sourceforge.net/project/showf...group_id=25964.
12. install the script.
13. append "resume=your swap partion" to ur kernel parameters in grub or lilo.
This is just a very brief summary. For more information, please refer to the swsusp's doc.
P.S.
1. There might be some risk trying that out.
2. before applying a patch, it's a good idea to run with --dry-run option to see if the patch applied cleanly.
|
|
|
All times are GMT -5. The time now is 07:50 PM.
|
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.
|
Latest Threads
LQ News
|
|