How to manually enable the Hibernate feature during an unattended installation of Windows 2000
This article was previously published under Q293399
This article describes how to enable the Hibernate feature during an unattended installation of Windows 2000.
Important This section, method, or task contains steps that tell you how to modify the registry. However, serious problems might occur if you modify the registry incorrectly. Therefore, make sure that you follow these steps carefully. For added protection, back up the registry before you modify it. Then, you can restore the registry if a problem occurs. For more information about how to back up and restore the registry, click the following article number to view the article in the Microsoft Knowledge Base:
322756 How to back up and restore the registry in Windows
There are no parameters you can set in the Unattend Answer file that can instruct Windows to enable the Hibernate feature during initial installation.
To work around this behavior, follow these steps:
- Install Windows 2000 on a test computer. This installation can either be completed manually or unattended.
- Enable the Hibernate feature by means of the graphical user interface (GUI). In Control Panel, double-click Power Options, and then click the Hibernate tab. Click to select the Enable Hibernate Support check box.
- Using the Regedit.exe tool, locate the following registry key:HKEY_LOCAL_MACHINE\System\CurrentControlSet\Control\Session Manager\Power
- Click the Power key. On the Registry menu, click Export Registry File, and then save this file as Hiber.reg.
- The preceding key contains several values. The only value you want is the Heuristics value. Right-click the Hiber.reg file, and then click Edit. You can edit the registry file to remove any other entries. The Heuristics value only exists when the Hibernate feature is enabled.
- The Hiberfil.sys hidden file is also added to the root of your hard disk. This file only exists after the Hibernate feature is enabled. This file cannot be copied in Windows as the file is in use by the computer. To work around this behavior:
- When the Hibernate feature is enabled, restart the computer, and then use the Recovery Console.For more information about the Recovery Console, click the following article number to view the article in the Microsoft Knowledge Base:229716 Description of the Windows 2000 Recovery Console
- Locate the root folder.
- Copy the target file with the copy hiberfil.sys hiberfil.cop command.
- Exit the Recovery Console and restart the computer.
- When the Hibernate feature is enabled, restart the computer, and then use the Recovery Console.For more information about the Recovery Console, click the following article number to view the article in the Microsoft Knowledge Base:
- Copy the Hiber.reg and Hiberfil.cop files to a location that is accessible during the unattended installation. This location may be a CD-ROM, a network share, or another partition on your target computer.
Note The Hiberfil.sys file may be several hundred megabytes. Therefore, you cannot copy this file to a floppy disk.
- Add the following section to your Unattend Answer file:The Hibernate feature is enabled when you restart the computer.
[GuiRunOnce] Command0="regedit /s <path>\hiber.reg" Command1="cmd /c copy <path>\hiberfil.cop c:\hiberfil.sys" Command2="cmd /c attrib +S +H +A C:\hiberfil.sys"
Note On a computer that is running Microsoft Windows XP with Service Pack 2, add the following section to your Unattend Answer file instead:
[GuiRunOnce] Command0="powercfg /HIBERNATE ON"
For more information, click the following article number to view the article in the Microsoft Knowledge Base:
237551 Advanced power management features are disabled with Terminal Services
unattended unattend txt hibernate installation runonce
Article ID: 293399 - Last Review: 10/31/2006 02:49:42 - Revision: 4.3
Microsoft Windows 2000 Service Pack 1, Microsoft Windows 2000 Advanced Server, Microsoft Windows 2000 Service Pack 1
- kbenv kbhowtomaster KB293399