禁用 Windows 页面文件和休眠以释放空间: 如果您的计算机(Disable Windows Pagefile and Hibernation To Free Up Space: )磁盘空间(disk space)不足,那么您总是可以删除一些数据或更好地运行磁盘清理(disk cleanup)来清理临时文件,但即使在做了所有这些之后仍然面临同样的问题?然后您需要禁用Windows 页面文件和休眠(Windows pagefile and hibernation)以释放硬盘空间。分页(Paging)是一种内存管理(memory management)方案,您的 Windows 将当前正在运行的进程的临时数据存储在硬盘分配的空间 ( Pagefile.sys ) 上,并且可以随时立即交换回随机存取内存(Random Acces Memory)( RAM )。
页面文件也称为交换文件、页面文件或(swap file)分页(Pagefile)文件,通常位于硬盘上的C:pagefile.sys,但您无法看到此文件,因为它被系统(System)隐藏以防止损坏或误用(damage or misuse)。为了更好地理解 pagefile.sys 让我们举个例子,假设你打开了Chrome,一旦你打开Chrome,它的文件就会被放入RAM中以便更快地访问,而不是从硬盘读取相同的文件。
现在,每当您在Chrome中打开新网页或标签(page or tab)时,它都会被下载并存储在您的RAM中,以便更快地访问。但是当您使用多个选项卡时,您的计算机上的RAM量可能已全部用完,在这种情况下,Windows会将一些数据量或 chrome 中使用最少的选项卡移回您的硬盘,将其放在分页中(paging file)文件从而释放你的内存(RAM)。虽然从硬盘 (pagefile.sys) 访问数据要慢得多,但它可以防止程序在RAM变满时崩溃。
禁用Windows 页面文件和休眠(Windows Pagefile and Hibernation)以释放空间(Free Up Space)
注意:(Note:)如果您禁用 Windows 页面文件以释放空间,请确保您的系统上有足够的可用RAM ,因为如果您的(RAM)RAM用完,那么将没有任何虚拟内存可供分配,从而导致程序崩溃。
如何禁用Windows 分页文件(Windows Paging File)(pagefile.sys):
1.右键单击这台电脑或我的电脑(Computer),然后选择属性。(Properties.)
2.现在从左侧菜单中单击(menu click)高级系统设置。( Advanced System Settings.)
3.切换到高级选项卡(Advanced tab),然后单击性能下的设置。( Settings under Performance.)
4.再次在“性能选项”窗口(Options window)下切换到“高级”选项卡。( Advanced tab.)
5.单击虚拟内存下的(Virtual Memory.)更改(Change)按钮。
6.取消选中自动管理所有驱动器的页面文件大小。(Automatically manage paging file size for all drives.)
7.勾选无分页文件(Check mark No paging file),然后点击设置(Set)按钮。
8.单击确定(OK),然后单击应用,然后单击确定。
9.重新启动您的 PC 以保存更改。
如果您想在保存所有程序的同时快速关闭您的 PC,以便在您再次启动 PC 时看到您离开时的所有程序。简而言之,这是休眠的好处,当您休眠您的 PC 时,所有打开的程序或应用程序本质上都会保存到您的硬盘上,然后 PC 就会关闭。当您首先打开您的 PC 时,它会比正常启动更快地启动,其次,您将再次看到您离开时的所有程序或应用程序。这是 hiberfil.sys 文件进入的地方,因为Windows将内存中的信息写入该文件。
现在这个hiberfil.sys 文件(hiberfil.sys file)可以在你的 PC 上占用一个巨大的磁盘空间(disk space),所以为了释放这个磁盘空间(disk space),你需要禁用休眠。现在确保您将无法休眠您的 PC,因此只有在每次关闭 PC 时都感到舒适时才继续。
如何在Windows 10中禁用(Windows 10)休眠(Hibernation):
1.按Windows Key + X然后选择命令提示符(管理员)。(Command Prompt (Admin).)
2. 在 cmd 中输入以下命令并回车(Enter):
powercfg -h 关闭(powercfg -h off)
3.命令完成后,您会注意到关机菜单中不再有休眠PC的选项。(no longer an option to hibernate your PC in shutdown menu.)
4.此外,如果您访问文件资源管理器并检查(file explorer and check)hiberfil.sys 文件(hiberfil.sys file),您会发现该文件不存在。
注意:(Note:)您需要取消选中文件夹选项中的隐藏系统保护文件(uncheck hide system protected files in Folder Options)才能查看hiberfil.sys 文件(hiberfil.sys file)。
5.如果您需要再次启用休眠,请在 cmd 中键入以下命令并按Enter:
powercfg -h 开启(powercfg -h on)
6.重新启动您的 PC 以保存更改。
为你推荐:(Recommended for you:)
- 修复操作系统(Fix Operating System)未找到错误(Found Error)
- 如何在Windows 10中退出安全(Windows 10)模式(Mode)
- 修复 Internet Explorer 没有声音
- 修复 Google Chrome 错误 6(Fix Google Chrome Error 6) (net::ERR_FILE_NOT_FOUND)
如果您已成功禁用 Windows 页面文件和休眠(Disable Windows Pagefile and Hibernation)以释放 PC 上的空间(Free Up Space),但如果您对本文仍有任何疑问,请随时在评论部分询问。
Disable Windows Pagefile and Hibernation To Free Up Space
Disable Windows Pagefile and Hibernation To Free Up Space: If your computer is running low on disk space then you could always delete some of your data or better run disk cleanup to clean up temporary files but even after doing all that still facing the same issue? Then you need to disable Windows pagefile and hibernation to free up space on your hard disk. Paging is one of the memory management schemes where your Windows store temporary data of currently running processes on the space allocated on hard disk (Pagefile.sys) and can be instantly swapped back to Random Acces Memory (RAM) anytime.
The Pagefile also known as the swap file, pagefile, or paging file is often located on your hard drive at C:\pagefile.sys but you won’t be able to see this file as it’s is hidden by System in order to prevent any damage or misuse. In order to better understand pagefile.sys let’s take an example, suppose your open Chrome and as soon as you open Chrome it’s files are placed into RAM for faster access rather than reading the same files from hard disk.
Now, whenever you open a new web page or tab in Chrome it is downloaded and stored in your RAM for faster access. But when you are using multiple tabs it’s possible the amount of RAM on your computer is all used up, in this case, the Windows moves some amount of data or the least used tabs in chrome back to your hard disk, placing it in the paging file thus freeing up your RAM. Although accessing data from hard disk (pagefile.sys) is much slower but it prevents crashing the programs when the RAM becomes full.
Disable Windows Pagefile and Hibernation To Free Up Space
Note: If you disable Windows pagefile to free up space make sure you have enough RAM available on your system because if you run out of RAM then there won’t be any virtual memory available to allocate thus causing the programs to crash.
How To Disable Windows Paging File (pagefile.sys):
1.Right-click on This PC or My Computer and select Properties.
2.Now from the left-hand menu click on Advanced System Settings.
3.Switch to the Advanced tab and then click Settings under Performance.
4.Again under Performance Options window switch to Advanced tab.
5.Click Change button under Virtual Memory.
6.Uncheck Automatically manage paging file size for all drives.
7.Check mark No paging file, and click the Set button.
8.Click OK then click Apply followed by OK.
9.Reboot your PC to save changes.
If you want to quickly turn off your PC while saving all your programs so that once you again start your PC you see all the programs as you left. In short, this is the benefit of hibernation, when you hibernate your PC all the opened programs or applications are essentially saved to your hard disk then the PC is shut down. When you gain power ON your PC first it will boot faster than the normal startup and second, you will again see all your programs or application as you left them. This is where the hiberfil.sys files come in as Windows writes the information in the memory to this file.
Now this hiberfil.sys file can take a monstrous disk space on your PC, so in order to free up this disk space, you need to disable hibernation. Now make sure that you won’t be able to hibernate your PC, so continue only if you are comfortable every time shutting down your PC.
How to Disable Hibernation in Windows 10:
1.Press Windows Key + X then select Command Prompt (Admin).
2. Type the following command into cmd and hit Enter:
powercfg -h off
3.As soon as the command is finished you will notice that there is no longer an option to hibernate your PC in shutdown menu.
4.Also, if you visit the file explorer and check for the hiberfil.sys file you will notice that the file is not there.
Note: You need to uncheck hide system protected files in Folder Options in order to view the hiberfil.sys file.
5.If by any chance you need to again enable hibernation then type the following command in cmd and hit Enter:
powercfg -h on
6.Reboot your PC to save changes.
Recommended for you:
That’s if you have successfully Disable Windows Pagefile and Hibernation To Free Up Space on your PC but if you still have any queries regarding this article then please feel free to ask them in the comment’s section.