Sysprep and unattend.xml: remove local user account on windows 7

deploymentsysprepunattendedwindows 7

We are deploying Windows 7 using WDS. We want to remove the local user account which was created during setup. We don't need this account since the machines join a domain and a domain user account is created during OOBE phase.

Documentation of Microsoft-Windows-Shell-Setup | UserAccounts | LocalAccounts states that this option can create local accounts.

Is there a way to specify accounts to be deleted in a unattend.xml?

Best Answer

You want to use Audit Mode when creating your Sysprep image. Audit Mode enables you to customize a Windows installation without prompting to create user accounts and configure your location and time zone.

Reference: http://technet.microsoft.com/en-us/library/cc722413(v=ws.10).aspx