The Power option of Hibernation in Windows

Hibernation in Windows is a power-saving state designed primarily for laptops. When a computer enters hibernation, it saves the current session, including all open applications and files, to the hard drive or SSD and then powers down completely. This allows the computer to use no power while still preserving the current session for quick restoration when powered back on.


How Hibernation Works

  1. The system writes the contents of the RAM to a file called hiberfil.sys located in the root directory of the system drive (usually C:\).
  2. The computer shuts down completely, consuming no power.
  3. When you turn the computer back on, it reads the contents of hiberfil.sys and restores your session to its previous state.


Benefits of Hibernation

  • Power Saving: Unlike Sleep mode, hibernation uses zero power.
  • Session Preservation: Restores all open applications and files.
  • Useful for Laptops: Ideal when the battery is low and you can't charge the device.


Difference Between Sleep and Hibernation

Feature Sleep Hibernation
Power Usage Minimal (low power) None
Resume Time Very fast Slower than Sleep
Session Storage Stored in RAM Stored in disk (hiberfil.sys)
Best Use Case Short breaks Long breaks or low battery


Enabling/Disabling Hibernation

Hibernation is sometimes disabled by default on Windows 10 systems. To enable or disable it:

  1. Enable Hibernation:

    • Open Command Prompt as Administrator.
    • Type: powercfg /hibernate on and press Enter.
  2. Disable Hibernation:

    • Open Command Prompt as Administrator.
    • Type: powercfg /hibernate off and press Enter.
    • This will also delete the hiberfil.sys file, freeing up disk space.


How to Use Hibernation

  1. Manually Hibernate:

    • Open the Start menu and select the Power button.
    • Click on Hibernate (if available).
  2. Add Hibernate Option to Power Menu:

    • Open Control Panel > Power Options.
    • Click Choose what the power buttons do.
    • Select Change settings that are currently unavailable.
    • Under Shutdown settings, check the box for Hibernate.
    • Save changes.


Managing hiberfil.sys File

  • The size of hiberfil.sys depends on your system’s RAM (usually 40%-75% of total RAM).
  • If disk space is a concern, you can disable hibernation or resize the file:
    • To resize: powercfg /hibernate /size <percentage> (e.g., powercfg /hibernate /size 50).


Comments

Popular posts from this blog

Quotation marks to wrap an element in HTML

What is the difference between iostream and iostream.h in cpp?

The Basic Structure of a Full-Stack Web App