Page 1 of 12 12311 ... LastLast
Results 1 to 10 of 213

Thread: [HowTo]: Fix suspend and hibernate on laptops

Hybrid View

  1. #1
    Join Date
    May 2007
    Location
    PA, USA
    Beans
    113
    Distro
    Gutsy Gibbon Testing

    Lightbulb [HowTo]: Fix suspend and hibernate on laptops

    If the normal suspend and hibernate buttons don't work, you can try this little hack.

    First get uswsusp:

    Code:
    sudo apt-get install uswsusp
    Now, test out suspend to see if it works:

    Code:
    sudo s2ram
    If this does not work, you can use

    Code:
    sudo s2ram --force
    Next, try out hibernate:

    Code:
    sudo s2disk
    Now, if one or both of these commands work and you would like to use them, we need to change the command on the shutdown menu to this.

    Note: This part is for FEISTY AND GUTSY ONLY!!! The scripts in Edgy are stored in "/usr/share/hal/scripts" and have different names AFAIK. If someone running Edgy could tell me what the files names are I will add it here.

    First, backup your original files:

    Code:
    sudo cp /usr/lib/hal/scripts/linux/hal-system-power-suspend-linux /usr/lib/hal/scripts/linux/hal-system-power-suspend-linux.bak
    
    sudo cp /usr/lib/hal/scripts/linux/hal-system-power-hibernate-linux /usr/lib/hal/scripts/linux/hal-system-power-hibernate-linux.bak
    Now, edit these two files and replace all the code with this:

    hal-system-power-suspend-linux

    Code:
    sudo gedit /usr/lib/hal/scripts/linux/hal-system-power-suspend-linux
    Code:
    #!/bin/sh
    
    /sbin/s2ram --force
    hal-system-power-hibernate-linux

    Code:
    sudo gedit /usr/lib/hal/scripts/linux/hal-system-power-hibernate-linux
    Code:
    #!/bin/sh
    
    /sbin/s2disk
    if this breaks stuff, just restore the backup files you made.

    Good luck!
    Last edited by Bluecircle; June 24th, 2007 at 10:03 PM.

  2. #2
    Join Date
    Jan 2007
    Location
    London, UK
    Beans
    3,525
    Distro
    Ubuntu Development Release

    Re: [HowTo]: Fix suspend and hibernate on laptops

    I know few people having this problem in feisty I will ask them to try this.

    On my laptops there are no problems either on Edgy or Feisty.

    Good work though.
    You came empty handed, that is how you shall leave. Whatever you claim as yours today, belonged to someone else yesterday, will be someone else's tomorrow.

  3. #3
    Join Date
    Jul 2007
    Location
    Philadelphia, PA
    Beans
    7
    Distro
    Ubuntu 7.04 Feisty Fawn

    Re: [HowTo]: Fix suspend and hibernate on laptops

    Quote Originally Posted by ukripper View Post
    I know few people having this problem in feisty I will ask them to try this.

    On my laptops there are no problems either on Edgy or Feisty.

    Good work though.
    Fixed my problem on Feisty with my Inspiron 1501

  4. #4
    Join Date
    Feb 2008
    Location
    Helsinki. Finland
    Beans
    8
    Distro
    Xubuntu 9.10 Karmic Koala

    Re: [HowTo]: Fix suspend and hibernate on laptops

    Thanks, works fine with Acer Aspire 5102 with 8.10.

    All the best,

    pen

  5. #5
    Join Date
    Sep 2008
    Location
    Stuttgart, Germany
    Beans
    6
    Distro
    Ubuntu 8.04 Hardy Heron

    Re: [HowTo]: Fix suspend and hibernate on laptops

    As it seams no need to change anything on the new Ubuntu 8.10 Intrepid.

    Suspend and resume has been working out of the box for me!

  6. #6
    Join Date
    Dec 2005
    Beans
    104

    Re: [HowTo]: Fix suspend and hibernate on laptops

    Also confirmed the suspend to disk(hibernate) works for aspire 4720Z. The default suspend to ram(suspend) works so I didn't test it, just left it as is by default.

    This is on Ubuntu 9.04 Jaunty Jackalopearoo.

    Now I can focus on making games work

  7. #7
    Join Date
    Nov 2004
    Beans
    142
    Distro
    Ubuntu 9.04 Jaunty Jackalope

    Re: [HowTo]: Fix suspend and hibernate on laptops

    I have a Dell Inspiron 9400 I have never been able to get suspend to ram or hibernate to work.

    Today read through this entire thread and did some googling after some prelim work got my swap space setup and recognized and s2disk works perfectly.

    But s2ram is a bit problematic it suspends but on resume the system freezes I have to do a hard power off.

    My Inspiron uses an integrated Intel 945GM. Where can I locate the log that would have the errors encountered while resuming?

    Thanks.
    Johann #339720
    Dell Inspiron 9400

  8. #8
    Join Date
    Apr 2006
    Beans
    9

    Thumbs down Re: [HowTo]: Fix suspend and hibernate on laptops

    I just upgraded to Jaunty, and as I normally do in upgrades, I made the changes outlined in this howto to make my system use s2ram and s2disk. Both commands would work when I ran them from the terminal, but when I selected "hibernate" or "suspend" from the logout menu, they didn't seem to be working.

    I discovered that with this upgrade, Jaunty seems to have installed uswsusp into /usr/sbin/, and not /sbin. So, for those of you having the same problem, when you edit /usr/lib/hal/scripts/linux/hal-system-power-hibernate-linux, instead of putting this:

    Code:
    #!/bin/sh
    
    /sbin/s2disk
    try this instead:

    Code:
    #!/bin/sh
    
    /usr/sbin/s2disk
    You also would need to make a similar change for suspend. This fixed the problem for me so that I could select hibernate or suspend from the menu, rather than having to run s2disk or s2ram from the terminal.

  9. #9
    Join Date
    Dec 2006
    Beans
    Hidden!

    Re: [HowTo]: Fix suspend and hibernate on laptops

    Excellent!

    This works on my HP Pavilion DV5215us, with xgl and beryl enabled on Feisty

    But, after I hibernate or suspend, my Hibernate and Suspend buttons from the Log off menu are gone!

    UPDATE: Sound didn't work, I have to reboot to get it back.
    Last edited by Unnicknamed; June 16th, 2007 at 12:50 AM.

  10. #10
    Join Date
    Jun 2007
    Beans
    2

    Re: [HowTo]: Fix suspend and hibernate on laptops

    Thanks, Bluecircle. The kernalspace (?) suspend/resume stuff (what comes by default) never worked properly on my Toshiba A105. I spent some time long ago trying to figure it out, and eventually because satisfied with only hibernate.

    A couple weeks ago, after some update undoubtedly, fan control started to be flaky on resume---the laptop would sometimes get VERY hot! But following your guide, now suspend and hibernate both seem to work fine.

    The only strange thing I get is that upon resume, Gnome Power Manager reports that there was a problem suspending. So I have to click a checkbox to make that disappear.

Page 1 of 12 12311 ... LastLast

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •