Linux - Laptop and Netbook Having a problem installing or configuring Linux on your laptop? Need help running Linux on your netbook? This forum is for you. This forum is for any topics relating to Linux and either traditional laptops or netbooks (such as the Asus EEE PC, Everex CloudBook or MSI Wind). |
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.
|
 |
06-05-2004, 10:26 PM
|
#1
|
LQ Newbie
Registered: Jun 2004
Posts: 7
Rep:
|
Slackware, ACPI standby/hibernate howto???
Hello! Linux newbie here.. please help!
I have a T30 IBM thinkpad running Kernel 2.6.3 with Slackware 9.1 and fluxbox.
I had ACPI compiled into my kernel when i recompiled from 2.4, and lately i've been reading around to find out how to exactly use ACPI. I'm still quite confused though on how to change the state of my computer (all the S0, S1, S2, etc..) I read a couple threads here and there, and most refer to a file either /sys/proc/state or /proc/acpi/sleep that I need to do some sort of 'echo' command to. Unfortunately, I could find neither (lucky for me). I have known slackware to be a bit...untradtional when it came to finding configuration files, etc... so I went searching around.
My /proc/acpi directory has many subdirectories of the different components of my computer, i figured I had to do something here??:
root@rufus:/proc/acpi# ls -l
total 0
dr-xr-xr-x 3 root root 0 Jun 5 23:12 ac_adapter
dr-xr-xr-x 4 root root 0 Jun 5 23:12 battery
dr-xr-xr-x 5 root root 0 Jun 5 22:54 button
-r-------- 1 root root 0 Jun 5 23:12 dsdt
dr-xr-xr-x 3 root root 0 Jun 5 23:12 embedded_controller
-r-------- 1 root root 0 Jun 5 22:09 event
-r-------- 1 root root 0 Jun 5 23:12 fadt
-r--r--r-- 1 root root 0 Jun 5 23:12 info
dr-xr-xr-x 3 root root 0 Jun 5 23:12 power_resource
dr-xr-xr-x 3 root root 0 Jun 5 23:12 processor
dr-xr-xr-x 3 root root 0 Jun 5 23:12 thermal_zone
so where do I go from here? I also stumbled across the 'sleep' command, then proceeded to experiment with it, but absolutely nothing happens when I type it. So I have still failed to put my computer to sleep. My main questions are: How do I change the state of my computer? If there is a file I need to do some sort of 'echo' command to, any ideas to where slackware would put it? Why doesn't the 'sleep' command do anything to my computer? and if I can even get that far, how then can I map my keys so Fn-F4 (the sleep key-combination in windows) will put my computer to sleep?
|
|
|
06-06-2004, 01:46 PM
|
#2
|
Member
Registered: Jul 2003
Location: Boston
Distribution: Ubuntu: Warty & Hoary
Posts: 113
Rep:
|
I have had luck with 'Software Suspend 2', but to use this, you will need to patch your kernel. Check it out here.
It was a bit difficult for me to figure out how to use the patches, and I recommend using the --dry-run option when you are testing the patches.
The hibernate script on the above site is great for getting your computer all ready to sleep.
Good luck! 
|
|
|
06-07-2004, 05:30 AM
|
#3
|
Member
Registered: Jan 2004
Distribution: Debian etch
Posts: 202
Rep:
|
I've had a quick go at getting hibernate to work on a compaq laptop and game up, when it did resume properly ( not very often ) it wasn't any quicker than a normal boot.
|
|
|
06-07-2004, 10:50 AM
|
#4
|
Member
Registered: Jan 2003
Location: Ballston Lake, NY
Distribution: Slackware, Debian
Posts: 665
Rep:
|
I use `apm -s` to suspend my laptop.
|
|
|
06-07-2004, 12:19 PM
|
#5
|
Member
Registered: Jul 2003
Location: Boston
Distribution: Ubuntu: Warty & Hoary
Posts: 113
Rep:
|
Swsusp 2 makes a HUGE difference in boot times for me--and as long as I don't put a pcmcia card in or pull one out during hibernate--it seems to work flawlessly (sound and video both come back perfectly--I can hibernate with an mp3 going and when I unhibernate it will be playing right where it left off).
I shut down in like 5-10 seconds and reboot in about 20 (I'll time it and post the times here after work tonight)
It makes me use my laptop even more now that I can shut it off and turn it on quickly.
|
|
|
06-07-2004, 04:53 PM
|
#6
|
LQ Newbie
Registered: Jun 2004
Posts: 7
Original Poster
Rep:
|
hey, i was going through applying the patches for my kernel for Software Suspend. My kernel version is 2.6.3, but the highest kernel version specific patch was 2.6.2, and i proceeded to use that one, I get numerous messages saying
"Reversed (or previously applied) patch detected! Assume -R? [n]"
What does this mean? should I go ahead and type "yes"?
|
|
|
06-07-2004, 11:30 PM
|
#7
|
Member
Registered: Jul 2003
Location: Boston
Distribution: Ubuntu: Warty & Hoary
Posts: 113
Rep:
|
Go here [sourceforge.net] for the latest patches and test releases.
There is nothing for 2.6.3 or 2.6.4, but you CAN get a patch for 2.6.5 or 2.6.6
I wouldn't recommend using a patch not designed specifically for a kernel version...
So get a new kernel (I'll assume 2.6.6) and download the following--unzip and untar it, and then add the whole and incremental patches (first patch the w/ version specific--then the core):
software-suspend-2.0.0.81-for-2.6.6.tar.bz2
Then install the current (.18) suspend script.
I think this should work... I used the SMP highmem patch for 2.6.5, so I can't guarantee you this is correct. However, you could ask Nigel, the current maintainer of the project, for help if you run into any more trouble. He is VERY good about keeping in touch with people on the swsusp mailing list, and will answer your questions quickly.
Let us know about your progress, and I wish you luck!
--Dean
Oh, and I timed my up and down for hibernating--I may have exaggerated a little
from pressing power to fully resumed KDE desktop = 27 seconds
pressing power to fully off = 19 seconds
but it seems to be at least twice as fast as usual...
Last edited by ming0; 06-09-2004 at 01:54 AM.
|
|
|
06-08-2004, 10:16 AM
|
#8
|
LQ Newbie
Registered: Jun 2004
Posts: 7
Original Poster
Rep:
|
wow, thanks guys. it works. I recompiled, added patches, and i now have a /proc/acpi/sleep =).
I do have another question though, when I do suspend to disk (S4 I believe), do I have to have a line added to lilo.conf to tell my computer where ot look for my image? I have heard people having multiple problems with comming back up after full hibernation; result was possible corruption of their data. So just to jump ahead of this so none of my data gets messed up, should I be adding resume2="/dev/hda3"? (hda3 being my swap partition) Or maybe something of the like?
|
|
|
06-08-2004, 12:17 PM
|
#9
|
Member
Registered: Jul 2003
Location: Boston
Distribution: Ubuntu: Warty & Hoary
Posts: 113
Rep:
|
That's what I have I think (in lilo)...
You are going to want to try hibernating make sure you start from a console (like do 'telinit 2') and if you have success, then try from an X11 session.
I almost forgot--if you have any ext3 partitions, you need to install a fsck program. Read the swsusp2's FAQ very carefully--it'll tell you what program you need.
And you know that all you need to do to hibernate is type 'hibernate' right?
|
|
|
06-10-2004, 12:19 PM
|
#10
|
LQ Newbie
Registered: Jun 2004
Posts: 7
Original Poster
Rep:
|
I read through the swsusp FAQ, and determined that the fsck i needed was e2fsprogs, which i have..so that's all good to go. However when I entered in resume2="/dev/hda3" into my lilo, then proceeded to run 'lilo' , I got an error saying "Unrecgonized token "resume2" at or above line 37 in flie '/etc/lilo.conf'.....so er, is that supposed to happen? I tried just "resume" instead of "resume2", but the same error appeared. Should I just ignore this and proceed to try to hibernate? or??
-thanks for all your help so far.
|
|
|
06-16-2004, 02:20 AM
|
#11
|
Member
Registered: Jul 2003
Location: Boston
Distribution: Ubuntu: Warty & Hoary
Posts: 113
Rep:
|
Ok,
Try adding this to the append section... it should look like this:
Code:
append = "resume2=swap:/dev/hda3"
You can add it to your existing append section. (I think it's delimited by commas)
They don't make this very clear in the swsusp2 howto
I had the same problem.
I won't be checking this as often, but if you are still trying, I will still try helping 
|
|
|
All times are GMT -5. The time now is 02:10 AM.
|
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
|
|