Jump to content

Hibernation (computing): Difference between revisions

From Wikipedia, the free encyclopedia
Content deleted Content added
Line 9: Line 9:
==Operating system support==
==Operating system support==
===Microsoft Windows===
===Microsoft Windows===
On most Windows computers, cliking the hibernate option uses the same amout of energy as turning off the computer would do, however when turned on, the computer restarts from wherever the user left off. 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''. Windows 98 and later support ACPI. However, hibernation worked flawlessly on relatively few systems since most hardware was not fully [[ACPI]] 1.0 compliant or did not have [[Windows Driver Model|WDM]] drivers. There were also issues with the FAT32 file system.<ref> [http://www.microsoft.com/whdc/archive/hiberfat32.mspx BIOS and Hibernate Issues for FAT32 File System] </ref> [[Windows Me]] also supports OS controlled hibernation and requires half the amount of disk space of the computer's [[RAM]].
On most Windows computers, clicking the hibernate option uses the same amout of energy as turning off the computer would do, however when turned on, the computer restarts from wherever the user left off. 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''. Windows 98 and later support ACPI. However, hibernation worked flawlessly on relatively few systems since most hardware was not fully [[ACPI]] 1.0 compliant or did not have [[Windows Driver Model|WDM]] drivers. There were also issues with the FAT32 file system.<ref> [http://www.microsoft.com/whdc/archive/hiberfat32.mspx BIOS and Hibernate Issues for FAT32 File System] </ref> [[Windows Me]] also supports OS controlled hibernation and requires half the amount of disk space of the computer's [[RAM]].


[[Microsoft Windows 2000]] and later support hibernation at the operating system level (OS-controlled ACPI S4 sleep state) without special drivers from the hardware manufacturer. A file, "<tt>hiberfil.sys</tt>" is used to store the contents of RAM when the computer hibernates, and is always the same size as the total [[RAM]]. The file resides in the root of the system partition, usually "<tt>C:\hiberfil.sys</tt>". The file is a hidden system file. This file is a full snapshot of the physical [[RAM]] memory compressed with an LZXPRESS algorithm, and contains further information like processor state. Although this file is undocumented, a security researcher, [[Matthieu Suiche]], documented it<ref>[http://msuiche.net/con/bhusa2008/Windows_hibernation_file_for_fun_%27n%27_profit-0.6.pdf BlackHat USA 2008 - Windows hibernation file for fun and profit]</ref> during [[Black Hat Briefings]] 2008 and has also provided a [[computer forensics]] framework to manage and convert this file into a readable memory dump.<ref>[http://sandman.msuiche.net SandMan Computer Forensics Framework]</ref>
[[Microsoft Windows 2000]] and later support hibernation at the operating system level (OS-controlled ACPI S4 sleep state) without special drivers from the hardware manufacturer. A file, "<tt>hiberfil.sys</tt>" is used to store the contents of RAM when the computer hibernates, and is always the same size as the total [[RAM]]. The file resides in the root of the system partition, usually "<tt>C:\hiberfil.sys</tt>". The file is a hidden system file. This file is a full snapshot of the physical [[RAM]] memory compressed with an LZXPRESS algorithm, and contains further information like processor state. Although this file is undocumented, a security researcher, [[Matthieu Suiche]], documented it<ref>[http://msuiche.net/con/bhusa2008/Windows_hibernation_file_for_fun_%27n%27_profit-0.6.pdf BlackHat USA 2008 - Windows hibernation file for fun and profit]</ref> during [[Black Hat Briefings]] 2008 and has also provided a [[computer forensics]] framework to manage and convert this file into a readable memory dump.<ref>[http://sandman.msuiche.net SandMan Computer Forensics Framework]</ref>

Revision as of 11:21, 28 May 2009

Hibernate is a feature seen in many operating systems where the contents of RAM is written to non-volatile storage, such as the hard disk (as either a file or on a separate partition) before powering off the system. Later the system can be restored to the state it was in when hibernation was invoked, so that programs can continue execution from their previous state. Hibernating and restoring from hibernate is also generally faster than a hard reboot and, if necessary, can be done without user interaction (unlike shutting down, which often requires the user to specify if open documents should be saved).

To enable hibernation, the hard disk needs to have at least as much free space as there is RAM on the system.

Hibernation is often used on laptops and can generally be set to happen automatically on a low battery alarm. Early implementations of hibernation did use the BIOS but on modern systems the functionality is usually handled by the operating system. Hibernation is defined as sleeping mode S4 in the ACPI specification.[1]

Operating system support

Microsoft Windows

On most Windows computers, clicking the hibernate option uses the same amout of energy as turning off the computer would do, however when turned on, the computer restarts from wherever the user left off. 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. Windows 98 and later support ACPI. However, hibernation worked flawlessly on relatively few systems since most hardware was not fully ACPI 1.0 compliant or did not have WDM drivers. There were also issues with the FAT32 file system.[2] Windows Me also supports OS controlled hibernation and requires half the amount of disk space of the computer's RAM.

Microsoft Windows 2000 and later support hibernation at the operating system level (OS-controlled ACPI S4 sleep state) without special drivers from the hardware manufacturer. A file, "hiberfil.sys" is used to store the contents of RAM when the computer hibernates, and is always the same size as the total RAM. The file resides in the root of the system partition, usually "C:\hiberfil.sys". The file is a hidden system file. This file is a full snapshot of the physical RAM memory compressed with an LZXPRESS algorithm, and contains further information like processor state. Although this file is undocumented, a security researcher, Matthieu Suiche, documented it[3] during Black Hat Briefings 2008 and has also provided a computer forensics framework to manage and convert this file into a readable memory dump.[4]

Windows XP further improved support for the hibernate function.[5] On Windows computers, hibernation is available only if all hardware is ACPI and Plug-and-play compliant, and additionally all drivers are PnP-compatible. The Microsoft Help and Support website also describes a command line instruction to invoke hibernation, in article #555569[6]; such command line instructions can be added to many keyboard instruction sets to hibernate computers at the touch of a (programmable) button.

Windows Vista's Fast Sleep and Resume feature saves the contents of volatile memory to hard disk before entering sleep mode. If power to memory is lost, it will use the hard disk to wake up. The user has the option of hibernating directly if they wish.

Hibernate is often under-used in business environments as it is difficult to enable post-deployment without resorting to third party software.[7] This omission by Microsoft has been widely criticisized as having led to a huge waste in energy.[8]

Mac OS

On Macs, a feature known as Safe Sleep saves the contents of volatile memory to the system hard disk each time the Mac enters Sleep mode. The Mac can instantaneously wake from sleep mode if power to the RAM has not been lost. However, if the power supply was interrupted, such as when removing batteries without an AC power connection, the Mac would wake from Safe Sleep instead, restoring memory contents from the hard drive.[9] Because Safe Sleep's hibernation process occurs during regular Sleep, the Apple menu does not have a "hibernate" option.

Safe Sleep capability is found only in new Mac models starting with the October 2005 revision of the PowerBook G4 (Double-Layer SD). Mac OS X v10.4 or higher is also required.

Shortly after Apple started supporting Safe Sleep, Mac enthusiasts released a hack to enable this feature for much older Mac computers running Mac OS X v10.4.[10] Classical Mac OS once also supported hibernate, but this feature was dropped by Apple.[11]

Linux

In the Linux kernel, Hibernate or suspend-to-disk, suspend-to-ram, suspend-to-file is implemented by swsusp which is built into the 2.6 series. An alternative implementation is TuxOnIce which is available as patches for the 2.4 and 2.6 kernels. Other alternative implementations also exist, namely, uswsusp (user-space suspend). TuxOnIce provides advantages such as support for SMP, 4GB high mem and preemption. Currently, work is being done on merging TuxOnIce into the mainline kernel.[12]

See also

References