『楼 主』:
万能WinXP Ghost镜像制作指南
使用 LLM 解释/回答一下
重装系统可不是一件好玩的事情:首先得端坐在电脑桌前老老实实地回windows安装程序提出的问题,安装好了呢,也不能闲着,还得安装驱动程序、应用程序…粗略佑计,没有半天拿不下来!可能有朋友会说,用Ghost,既快又方便,不出五分钟,系统就恢复了,不过那只是本机备份,如果拿到别人的机器上去恢复,肯定会“水土不服”,道理很简单:硬件、系统、网络的配置不可能都千篇一律……不过看完本文以后,你就可以轻松打造出一把万能钥匙了,随便什么机器,都可以轻松采用Ghost恢复安装的方法,10多分钟就能搞Windows XP的安装!
一、做好准备工作
安装好Windows XP并且利用Windows Update升级最新的系统补丁(包括service Pack l和其他最新的Hot fix)。同时安装好所需的应用程序,不过不要贪多,因为将应用程序安装在 C 盘里并不是值得推荐的做法,同时会造成Ghost映像文件的容量过大。
二、为Windows XP减肥
不管是否需要将最后产生的Ghost映像文件刻录到光盘上,都应该对Windows XP进行减肥,以尽可能地减小Ghost映像文件的容量。可以删减的主要项目如下:
1.系统文件保护缓存
它位于C:\WINDOWS\System32\Dllcache目录下,我们只需在命令提示符窗口中运行“sfe . exe/purgecache”即可将它删除。
2.清空页面文件
在“我的电脑”上单击鼠标右键,选择“属性”。在打开的“系统属性”对话框中选择“高级”选项卡,单击“性能”下的“设置”按钮,在打开的“性能选项”对话框中选择“高级”选项卡,再单击右下角的“更改”按钮,打开“虚拟内存”对话框。默认情况下虚拟内存文件保存在Windows XP的安装目录下,我们只需选择下面的“无分页文件”选项,再单击“设置”按钮即可。重新启动计算机后虚拟内存文件即被删除。注意做好硬盘映像文件后,再重设虚拟内存。
3.关闭系统还原功能
在打开的“系统属性”对话框中选择“系统还原”选项卡,选中“在所有驱动器上关闭系统还原”前的复选框即可。
4.其他方法
我们还可以采用其他的如删除帮助文档、删除不需要的输人法、字体文件等常规“减肥”方法来进一步减小Windows XP所在分区的大小。
三、对驱动程序做手术
由于我们要制作的是一个万能的Windows XP Ghost文件,目标计算机上的硬件配置和当前计算机的配置肯定不完全相同,因此我们要将当前计算机上的设备驱动程序删除。
1. 删除普通驱动程序
① 在“运行”对话框里输人“devmgrnt.rnsc”并回车,打开“设备管理器”控制台窗口。
② 找到网络适配器,鼠标右键单击其下的网卡设备名称,在弹出菜单上单击“卸载”菜单项。
③ 再用类似的方法卸载通用串行总线控制器、视频游戏控制器、显卡、声卡等设备驱动程序。这里要注意的是,如果系统提示需要重新启动,一定不要重启机器,以免系统自作主张,重新安装驱动程序。
2. 更新ACPI属性
然后我们要把计算机的ACPI属性更改为Standard PC,这是因为如果目标计算机中有不同类型的ACPI,则新克隆的目标计算机就无法实现电脑软关机,并且可能会在第一次启动后崩溃!更改步骤如下:
① 在设备管理器控制台窗口用鼠标右键单击“计算机”→“ACPI Uniprocessor PC”,在弹出菜单上单击“更新驱动程序”菜单项;
② 在打开的“硬件更新向导”对话框里选中“从列表或指定位置安装(高级)”选项,并单击“下一步”按钮;
③ 在接下来的页面里选中“不要搜索,我要自己选择要安装的驱动程序”选项,并单击“下一步”按钮;
④ 然后选择“Standsrd PC”选项,并根据屏幕提示一路Next, 只是最后提示是否重新启动时,一定不要重启!
3. 更新IDE控制器属性
对设备驱动程序的最后一步手术是更改IDE ATA / ATAPI 控制器。这一步非常重要,因为大家知道,不同的主板,例如Intel、Nforce 2、VIA等主板,其IDE ATA / ATAPI控制器的驱动程序有很大的差别,根本无法通用!
① 在设备管理器控制台窗口用鼠标右键单击IDE ATA / ATAPI控制器、Intel (r) 82371 AB / EB Bus Master IDE Controller,在弹出菜单上单击“更新驱动程序”菜单项;
② 在打开的“硬件更新向导”对话框里选中“从列表或指定位置安装(高级)”选项,并单击“下一步”按钮;
③ 在接下来的页面里选中“不要搜索,我自己选择要安装的驱动程序”选项,并单击“下一步”按钮;
④ 然后选择“标准的双通道PCI IDE控制器”选项,并根据屏幕提示一路Next,只是最后提示是否重新启动时,一定不要重启!
四、准备主映像文件
删除了“母机”上的驱动程序,还不能说已经马到成功。这是因为每一台计算机都有一个惟一的安全标识符(SID: security identifier),如果直接把磁盘映像复制到其他计算机上,那么其他计算机都有会具有同样的SID,所以需要用Sysprep工具去除“母机”的SID,从而强迫目标计算机产生新的SID。
1. 自动应答文件
在目标计算机恢复克隆备份时,系统会开始一个Mini-Setup向导过程,该向导会提示我们输人特定的计算机变量,例如管理员密码、计算机名等等。但是由于在克隆备份里去除了驱动程序,所以在这个阶段无法使用键盘、鼠标进行交互。不过我们可以创建一个自动安装应答文件,让这个应答文件自动回复安装程序提出的问题。
① 把Windows XP安装光盘插人光驱,将\SUPPORT\TOOLS\目录下的DEPLOY.CAB文件释放到C:\Sysprep目录;
② 然后运行其中的setupmgr.exe文件,在出现选择安装类型界面中选择“Sysprep安装”选项;
③ 根据屏幕提示填入必要的信息,一直单击“Next”按钮,直至最后进人保存配置文件的对话框,一定要确保最后的安装脚本路径是C:\Sysprep\sysprep.inf。
2.重新封装
现在可以利用Sysprep工具去除“母机”的SID,很简单:运行C:\Sysprep目录下的Sysprep.exe程序,然后在打开的窗口中单击“重新封装”按钮。接下来会提示下一次启动时将重新生成SID,单击“确定”按钮,稍等片刻,计算机将会自动关闭。
五、克隆主映像文件
计算机关闭之后,我们就可以用Ghost 2003启动盘引导计算机,然后依次单击“Local→Partition→To Image”命令,指定源分区为C盘,再设置Ghost映像文件的路径和文件名,开始备份。备份结束后,我们就拥有了一个万能的Windows XP映像文件!
---------- Edited by willsort ----------
自 DOS疑難解答 & 問題討論 (解答室) 移动至此
---------- Edited by willsort ----------
Last edited by willsort on 2005-10-14 at 18:33 ]
Reinstalling the system is not a fun thing: First, you have to sit in front of the computer desk and honestly answer the questions raised by the Windows installation program. After installation, you can't be idle. You also have to install drivers, applications... It is roughly estimated that it won't be done in less than half a day! Maybe some friends will say, use Ghost, which is fast and convenient, and the system will be restored in less than five minutes. But that's only local backup. If you restore it on someone else's machine, it will definitely "not fit in". The reason is very simple: the configurations of hardware, system, and network cannot all be exactly the same... But after reading this article, you can easily create a universal key. Any machine can easily use the Ghost recovery installation method, and you can install Windows XP in more than 10 minutes!
I. Prepare well
Install Windows XP and use Windows Update to upgrade to the latest system patches (including service Pack 1 and other latest Hot fixes). Also install the required applications. But don't be greedy, because installing applications in the C drive is not a recommended practice, and it will also cause the Ghost image file to be too large.
II. Slim down Windows XP
Whether you need to burn the final Ghost image file to a CD or not, you should slim down Windows XP to minimize the size of the Ghost image file as much as possible. The main items that can be cut are as follows:
1. System file protection cache
It is located in the C:\WINDOWS\System32\Dllcache directory. We just need to run "sfe.exe /purgecache" in the command prompt window to delete it.
2. Empty the page file
Right-click on "My Computer" and select "Properties". In the opened "System Properties" dialog box, select the "Advanced" tab, click the "Settings" button under "Performance", in the opened "Performance Options" dialog box, select the "Advanced" tab, and then click the "Change" button at the bottom right to open the "Virtual Memory" dialog box. By default, the virtual memory file is saved in the installation directory of Windows XP. We just need to select the "No paging file" option below and then click the "Set" button. Restart the computer and the virtual memory file will be deleted. Note that after making the hard disk image file, reset the virtual memory.
3. Turn off the system restore function
In the opened "System Properties" dialog box, select the "System Restore" tab and check the checkbox in front of "Turn off system restore on all drives".
4. Other methods
We can also use other conventional "slimming down" methods such as deleting help documents, deleting unnecessary input methods, font files, etc. to further reduce the size of the partition where Windows XP is located.
III. Operate on the drivers
Since the Windows XP Ghost file we are going to make is universal, the hardware configuration of the target computer must not be exactly the same as the current computer's configuration. Therefore, we need to delete the device drivers on the current computer.
1. Delete ordinary drivers
① Enter "devmgmt.msc" in the "Run" dialog box and press Enter to open the "Device Manager" console window.
② Find the network adapter, right-click on the name of the network card device under it, and click the "Uninstall" menu item in the pop-up menu.
③ Then use a similar method to uninstall device drivers such as Universal Serial Bus controllers, video game controllers, graphics cards, sound cards, etc. Note here that if the system prompts that a restart is required, must not restart the machine, so that the system won't reinstall the drivers on its own.
2. Update the ACPI property
Then we need to change the computer's ACPI property to Standard PC. This is because if there are different types of ACPI in the target computer, the newly cloned target computer will not be able to achieve soft shutdown of the computer and may crash after the first boot! The change steps are as follows:
① In the Device Manager console window, right-click on "Computer" → "ACPI Uniprocessor PC", and click the "Update driver" menu item in the pop-up menu;
② In the opened "Hardware Update Wizard" dialog box, select the "Install from a list or specified location (Advanced)" option and click the "Next" button;
③ In the next page, select the "Don't search, I will choose the driver to install myself" option and click the "Next" button;
④ Then select the "Standard PC" option, and follow the screen prompts all the way to Next. Just when it finally prompts whether to restart, must not restart!
3. Update the IDE controller property
The final operation on the device drivers is to change the IDE ATA/ATAPI controller. This step is very important, because as we all know, different motherboards, such as Intel, Nforce 2, VIA, etc., have very different drivers for the IDE ATA/ATAPI controller and cannot be universal at all!
① In the Device Manager console window, right-click on the IDE ATA/ATAPI controller, Intel (R) 82371 AB/EB Bus Master IDE Controller, and click the "Update driver" menu item in the pop-up menu;
② In the opened "Hardware Update Wizard" dialog box, select the "Install from a list or specified location (Advanced)" option and click the "Next" button;
③ In the next page, select the "Don't search, I will choose the driver to install myself" option and click the "Next" button;
④ Then select the "Standard dual-channel PCI IDE controller" option, and follow the screen prompts all the way to Next. Just when it finally prompts whether to restart, must not restart!
IV. Prepare the main image file
Deleting the drivers on the "mother machine" doesn't mean it's done. This is because each computer has a unique security identifier (SID: security identifier). If the disk image is directly copied to other computers, then other computers will all have the same SID. Therefore, we need to use the Sysprep tool to remove the SID of the "mother machine" to force the target computer to generate a new SID.
1. Automatic answer file
When the target computer restores the cloned backup, the system will start a Mini-Setup wizard process, which will prompt us to enter specific computer variables, such as the administrator password, computer name, etc. But since the drivers are removed in the cloned backup, we cannot use the keyboard and mouse for interaction at this stage. However, we can create an automatic installation answer file to let this answer file automatically answer the questions raised by the installation program.
① Insert the Windows XP installation CD into the optical drive, and extract the DEPLOY.CAB file in the \SUPPORT\TOOLS\ directory to the C:\Sysprep directory;
② Then run the setupmgr.exe file in it. In the interface where the installation type is selected, select the "Sysprep installation" option;
③ Fill in the necessary information according to the screen prompts, keep clicking the "Next" button until finally entering the dialog box for saving the configuration file. Be sure to ensure that the final installation script path is C:\Sysprep\sysprep.inf.
2. Repackage
Now we can use the Sysprep tool to remove the SID of the "mother machine". It's very simple: run the Sysprep.exe program in the C:\Sysprep directory, then click the "Repackage" button in the opened window. Next, it will prompt that the SID will be regenerated when it starts next time. Click the "OK" button, wait for a while, and the computer will automatically shut down.
V. Clone the main image file
After the computer is shut down, we can use the Ghost 2003 boot disk to boot the computer, then click the "Local→Partition→To Image" command in sequence, specify the source partition as the C drive, then set the path and file name of the Ghost image file, and start the backup. After the backup is completed, we will have a universal Windows XP image file!
---------- Edited by willsort ----------
Moved from DOS Troubleshooting & Problem Discussion (Answer Room)
---------- Edited by willsort ----------
Last edited by willsort on 2005-10-14 at 18:33 ]
|