Make a VHD without SID confliction

Microsoft-based operating systems use Security IDs(SID) that are generated as part of the initial setup of Windows. If you have more than one computer with the same SID, this could cause problems, and cloning a computer (either physical or virtual) without re-generating this SID can cause SID duplication.

It's easy to remove SID and other personal information from the VHD via tool sysprep. The typical comands to generate an available VHD is: sysprep.exe /generalize /shutdown

if you need to add account and custiomize other configurations automatically, please use "/unattend:<unattend.xml>". (refer to "Unattend Operating System Installation")

The System Preparation (Sysprep) tool prepares an installation of Windows for duplication, auditing, and customer delivery. Duplication, also called imaging, enables you to capture a customized Windows image that you can reuse throughout an organization. Audit mode enables you to add additional device drivers or applications to a Windows installation. After you install the additional drivers and applications, you can test the integrity of the Windows installation. Sysprep also enables you to prepare an image to be delivered to a customer. When the customer boots Windows, Windows Welcome starts.

If you intend to transfer a Windows image to a different computer, you must run sysprep /generalize, even if the computer has the same hardware configuration.  The sysprep /generalize command removes unique information from your Windows installation, which enables you to reuse that image on different computers.

sysprep.exe [/oobe | /audit] [/generalize] [/reboot | /shutdown | /quit] [/quiet] [/unattend:answerfile]
OptionDescription

/audit

Restarts the computer into audit mode. Audit mode enables you to add additional drivers or applications to Windows. You can also test an installation of Windows before it is sent to an end user.

If an unattended Windows setup file is specified, the audit mode of Windows Setup runs the auditSystem and auditUser configuration passes.

/generalize

Prepares the Windows installation to be imaged. If this option is specified, all unique system information is removed from the Windows installation. The security ID (SID) resets, any system restore points are cleared, and event logs are deleted.

The next time the computer starts, the specialize configuration pass runs. A new security ID (SID) is created, and the clock for Windows activation resets, if the clock has not already been reset three times.

/oobe

Restarts the computer into Windows Welcome mode. Windows Welcome enables end users to customize their Windows operating system, create user accounts, name the computer, and other tasks. Any settings in the oobeSystem configuration pass in an answer file are processed immediately before Windows Welcome starts.

/reboot

Restarts the computer. Use this option to audit the computer and to verify that the first-run experience operates correctly.

/shutdown

Shuts down the computer after Sysprep completes.

/quiet

Runs Sysprep without displaying on-screen confirmation messages. Use this option if you automate Sysprep.

/quit

Closes Sysprep after running the specified commands.

/unattend:

Applies settings in an answer file to Windows during unattended installation.

answerfile

Specifies the path and file name of the answer file to use.

posted @ 2012-02-24 21:34  AdaColor  阅读(261)  评论(0编辑  收藏  举报