Turn off the Windows 10 disk hibernation function to easily save 10G space on the C drive

1. Problem description

When using the computer in the past few days, I found that the C drive has lost 10 G of space for no reason. Originally, our C drive had less memory, but now it has lost 10 G. How can this be acceptable. So I spent a lot of time and finally figured out the cause of the problem.
When scanning the disk, it was found that " hiberfil.sys" took up a lot of space. After Baidu, I learned that this is the hibernation file of the system, and it can be closed by executing the command.

Second, the advantages of turning on/off the hibernation file

Advantages of turning it on : the content in the memory will be saved to the hard disk, and when the computer is woken up, all the programs and documents that were opened before entering the hibernation state will be restored to the desktop, which can greatly increase the speed of startup and shutdown.

Advantages of turning off : Turning off hibernation can reduce the generation and accumulation of hard disk garbage, make the computer run faster, and prolong the use time of the hard disk.

3. Operation steps

1. Right-click the start menu button and select the administrator command line window.
insert image description here

2. Enter in the command line window powercfg -h off, press the Enter key to run, the hibernation function will be closed, and the hiberfil.sys file will be deleted at the same time.
insert image description here
3. If you want to restore the hibernation function later, enter powercfg -h on in the command line window above.

4. Effect display

insert image description here

Guess you like

Origin blog.csdn.net/weixin_43520450/article/details/128356270