Documenti di Didattica
Documenti di Professioni
Documenti di Cultura
HowSysprepWorks
Sysprep Executable
Sysprep.exe is the main program that calls other executable files that prepare the Windows installation. Sysprep.exe is located in
the %WINDIR%\system32\sysprep directory on all installations. Sysprep must always be run from the
%WINDIR%\system32\sysprep directory and must run on the version of Windows with which it was installed.
Sysprep Process
When Sysprep runs, it goes through the following process:
1. Verifies that Sysprep can run. Only an administrator can run Sysprep, and only one instance of Sysprep can run at a given
time. Also, Sysprep must run on the version of Windows with which it was installed.
2. Initializes logging.
3. Parses commandline arguments.
If no commandline arguments were provided, the Sysprep window appears that enables users to specify Sysprep actions.
4. Processes Sysprep actions, calls appropriate .dll files and executable files, and adds actions to the log file.
5. Verifies that all .dll files have processed all their tasks, and then either shuts down the system, restarts the system, or exits
Sysprep.
https://technet.microsoft.com/enus/library/cc766514(v=ws.10).aspx
1/5
9/16/2016
HowSysprepWorks
For more information, see How Configuration Passes Work. For more information about Sysprep commandline options, see
Sysprep CommandLine Syntax.
2/5
9/16/2016
HowSysprepWorks
If the command returns nonzero, its related list item is annotated with a redX. A nonzero return value is not treated as a
fatal error when WillReboot is set either to Always or Never.
If RunSynchronous/RunSynchronousCommand/WillReboot is set to OnRequest, then:
If the command returns0, its related list item is annotated with a green check mark.
If the command returns1, its related list item is annotated with a green check mark. A reboot immediately occurs.
If the command returns2, its related list item is temporarily annotated with a green checkmark. A reboot immediately
occurs. Following the reboot, the related list item is displayed again in the AuditUI without annotation because the
command is still in process.
If the command returns other values, then a fatal error occurs and a blocking dialog is displayed. If the Errorhandler.cmd
file is present, no dialog is displayed. For more information about Errorhandler.cmd, see Add a Custom Script to Windows
Setup.
Important
If you anticipate running Sysprep multiple times on a single computer, you must use the SkipRearm setting in the Microsoft
WindowsSecurityLicensingSLC component to postpone resetting the activation clock. Because you can reset the activation
clock only three times, if you run Sysprep multiple times on a computer, you might run out of activation clock resets.
Microsoft recommends that you use the SkipRearm setting if you plan on running Sysprep multiple times on a computer.
3/5
9/16/2016
HowSysprepWorks
Note
You cannot make an image of an activated Windows installation and duplicate that image to another computer. If you do,
Windows fails to recognize the activation and forces the end user to reactivate the installation manually.
Item
Log Path
https://technet.microsoft.com/enus/library/cc766514(v=ws.10).aspx
4/5
9/16/2016
HowSysprepWorks
generalize
%WINDIR%\System32\Sysprep\Panther
specialize
%WINDIR%\Panther\
%WINDIR%\Panther\Unattendgc
See Also
Concepts
What is Sysprep?
Sysprep CommandLine Syntax
2016 Microsoft
https://technet.microsoft.com/enus/library/cc766514(v=ws.10).aspx
5/5