8

Could you provide a minimal unattend.xml file for use in Windows 7, which will be manually installed, updated and configured on one workstation, then SysPrep will be run like this:

C:\Windows\System32\sysprep>
sysprep /generalize /oobe /unattend:unattend.xml /shutdown

and then C: partition cloned to multiple workstations (I use partimage from a Linux LiveUSB for this).

This unattend.xml should configure a workstation so it will not ask for anything after cloning. Workstation should just show an ordinary login screen with accounts configured before. It should create random computer name and don't try to join Active Directory, as I'm not comfortable with storing passwords in unattend.xml.

I don't want to use Windows System Image Manager (Windows SIM) from Windows Automated Installation Kit (Windows AIK) as this is overkill — too complicated for my tastes.

Tometzky
  • 2,709

3 Answers3

2
<?xml version="1.0" encoding="utf-8"?>
<unattend xmlns="urn:schemas-microsoft-com:unattend"
        xmlns:wcm="http://schemas.microsoft.com/WMIConfig/2002/State"
        xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
    <settings pass="generalize">
        <component name="Microsoft-Windows-PnpSysprep"
                processorArchitecture="amd64"
                publicKeyToken="31bf3856ad364e35"
                language="neutral" versionScope="nonSxS">
            <PersistAllDeviceInstalls>true</PersistAllDeviceInstalls>
        </component>
    </settings>
    <settings pass="specialize">
        <component name="Microsoft-Windows-Deployment"
                processorArchitecture="amd64"
                publicKeyToken="31bf3856ad364e35"
                language="neutral" versionScope="nonSxS">
            <RunSynchronous>
                <RunSynchronousCommand wcm:action="add">
                    <Description>Disable create user account</Description>
                    <Path>reg add HKLM\Software\Microsoft\Windows\CurrentVersion\Setup\OOBE /v UnattendCreatedUser /t REG_DWORD /d 1 /f</Path>
                    <Order>1</Order>
                </RunSynchronousCommand>
            </RunSynchronous>
        </component>
        <component name="Microsoft-Windows-Shell-Setup"
                processorArchitecture="amd64"
                publicKeyToken="31bf3856ad364e35"
                language="neutral" versionScope="nonSxS">
            <RegisteredOwner>Wile E. Coyote</RegisteredOwner>
            <RegisteredOrganization>ACME Corp.</RegisteredOrganization>
            <TimeZone>Central European Standard Time</TimeZone>
            <Computername>*</Computername>
            <OOBE>
                <HideEULAPage>true</HideEULAPage>
                <NetworkLocation>Other</NetworkLocation>
                <ProtectYourPC>2</ProtectYourPC>
                <SkipUserOOBE>true</SkipUserOOBE>
            </OOBE>
        </component>
    </settings>
    <settings pass="oobeSystem">
        <component name="Microsoft-Windows-International-Core"
                processorArchitecture="amd64"
                publicKeyToken="31bf3856ad364e35"
                language="neutral" versionScope="nonSxS">
            <InputLocale>pl-PL</InputLocale>
            <SystemLocale>pl-PL</SystemLocale>
            <UILanguage>pl-PL</UILanguage>
            <UserLocale>pl-PL</UserLocale>
        </component>
    </settings>
</unattend>

You just need to change:

  • <RegisteredOwner>
  • <RegisteredOrganization>
  • <TimeZone>
  • Polish locale pl-PL to yours, for example en-US for US.
Tometzky
  • 2,709
0

There's a similar question in Super user: Sysprep WITHOUT creating new user

For reference, here's the minimal unattend.xml file that was posted there:

<?xml version="1.0" encoding="utf-8"?>
<unattend xmlns="urn:schemas-microsoft-com:unattend">
  <settings pass="oobeSystem">
    <component name="Microsoft-Windows-Shell-Setup" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS" xmlns:wcm="http://schemas.microsoft.com/WMIConfig/2002/State" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
      <OOBE>
        <SkipMachineOOBE>true</SkipMachineOOBE>
        <SkipUserOOBE>true</SkipUserOOBE>
      </OOBE>
    </component>
  </settings>
</unattend>

You can copy and paste this to Notepad, and save it as "unattend.xml" (with the quotation marks - so the file extension will be xml). Credits goes to blaniel.

Oz Edri
  • 141
0

You can have it join a domain without a password using UnsecureJoin.

MSCF
  • 135