Thread: Linux hibernation speed and amount of RAM

  1. #1
    Registered User
    Join Date
    Dec 2006
    Location
    Canada
    Posts
    3,229

    Linux hibernation speed and amount of RAM

    My current laptop has 2GB of RAM, and I have to do hibernation (suspend to disk) a lot, since I use it in and between classes, and suspend to ram doesn't work (no Linux support yet for this machine ). So I am wondering, if Linux copies everything in RAM (including unused space and disk cache) to disk or just the application data?

    I have a SSD so wake ups are not THAT slow, but are still quite slow compared to waking up from RAM, and would like to make it faster. Will removing 1GB of RAM help? Since I don't need more than 1GB of RAM anyways.
    Last edited by cyberfish; 09-12-2009 at 09:57 PM.

  2. #2
    Malum in se abachler's Avatar
    Join Date
    Apr 2007
    Posts
    3,195
    Susend to ram just declocks the processor and powers down other devices, it doesnt go into full hibernation. You only need as much ram as you have, since it doesnt make a copy of that ram in ram.

  3. #3
    Registered User
    Join Date
    Dec 2006
    Location
    Canada
    Posts
    3,229
    I was referring to suspend to disk (hibernation).

    AFAIK, suspend to RAM means power down everything (including CPU) except RAM, but that's aside.

  4. #4
    Malum in se abachler's Avatar
    Join Date
    Apr 2007
    Posts
    3,195
    Quote Originally Posted by cyberfish View Post
    I was referring to suspend to disk (hibernation).
    Quote Originally Posted by cyberfish View Post
    So I am wondering, if Linux copies everything in RAM ... to RAM or just the application data?
    Make up your mind.

    Quote Originally Posted by Wikipedia
    Hibernate is a feature of many computer operating systems where the contents of RAM are written to non-volatile storage such as a hard disk, as a file or on a separate partition, before powering off the computer.

    Windows 95 supported hibernation through hardware manufacturer-supplied drivers and only if compatible hardware and BIOS were present. Since Windows 95 supported only Advanced Power Management (APM), hibernation was then known as Suspend-to-Disk.
    Perhaps you are confusing hibernate with low power mode, which just shuts down the hard drive monitor and declocks the processor, but does not suspend to disk.
    Last edited by abachler; 09-12-2009 at 09:57 PM.

  5. #5
    Registered User
    Join Date
    Dec 2006
    Location
    Canada
    Posts
    3,229
    Ah sorry. A typo. Fixed. I was referring to hibernating to disk (no power mode).

  6. #6
    Malum in se abachler's Avatar
    Join Date
    Apr 2007
    Posts
    3,195
    Quote Originally Posted by cyberfish View Post
    Ah sorry. A typo. Fixed. I was referring to hibernating to disk (no power mode).
    It saves everything in ram, including global and local descriptor tables, thread context information, registers, the entire machine state including virtual memory and all application data that resides in memory, physical or virtual.

    I do not know if it saves the cache (L1L2L3) btu I doubt it as there is no trivial way to directly access teh cache and whether a memory location is in the cache or not does not effect its logical operation. It does however flush the cache.

    It also saves peripheral device states for ACPI compliant devices.

  7. #7
    Registered User
    Join Date
    Dec 2006
    Location
    Canada
    Posts
    3,229
    I see. So not unused memory? That means removing 1 stick of memory won't help (make it faster)?

  8. #8
    C++まいる!Cをこわせ!
    Join Date
    Oct 2007
    Location
    Inside my computer
    Posts
    24,654
    I know that usually more memory equals longer hibernation times.
    I guess that this might have something to do with that it has more data to dump from memory. If you lesser RAM, then the rest of the data would already be saved in the pagefile.
    To try this out, you can, for example, hibernate when you've just booted your system against, for example, when you run a game. The latter should take longer.
    Quote Originally Posted by Adak View Post
    io.h certainly IS included in some modern compilers. It is no longer part of the standard for C, but it is nevertheless, included in the very latest Pelles C versions.
    Quote Originally Posted by Salem View Post
    You mean it's included as a crutch to help ancient programmers limp along without them having to relearn too much.

    Outside of your DOS world, your header file is meaningless.

Popular pages Recent additions subscribe to a feed