chaoticyeshua Posted January 10, 2013 Share Posted January 10, 2013 (edited) Hi everyone.I have captured an image after using "sysprep.exe /oobe /generalize /shutdown /unattend:answerfile" in audit mode.I now want to be able to modify the answer file in WinPE after deploying the image so that it changes the computer name and joins to the domain during "mini-setup" using credentials that are given by the user in an AutoIt script that will run in WinPE. I have an AutoIt script that automatically changes the correct fields in the XML file already, under Credentials I have "Username" and "Password" being modified. I also have it modifying the ComputerName field. The problem is that it doesn't change the computer name or join to the domain. The answer file was created using the WAIK and the only manual modifications that are made are through the script, which only change the values of the nodes listed above.Can anyone help me figure out why this isn't working? Modifying the answer file after running sysprep and having those new settings apply during the specialize phase is possible to do, right?Here's my answer file with identifying information removed:<?xml version="1.0" encoding="utf-8"?><unattend xmlns="urn:schemas-microsoft-com:unattend"> <settings pass="oobeSystem"> <component name="Microsoft-Windows-International-Core" 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"> <InputLocale>en-us</InputLocale> <SystemLocale>en-us</SystemLocale> <UILanguage>en-us</UILanguage> <UILanguageFallback>en-us</UILanguageFallback> <UserLocale>en-us</UserLocale> </component> <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> <HideEULAPage>true</HideEULAPage> <ProtectYourPC>1</ProtectYourPC> <NetworkLocation>Work</NetworkLocation> </OOBE> <UserAccounts> <AdministratorPassword> <Value>password</Value> <PlainText>false</PlainText> </AdministratorPassword> <LocalAccounts> <LocalAccount wcm:action="add"> <Password> <Value>UABhAHMAcwB3AG8AcgBkAA==</Value> <PlainText>false</PlainText> </Password> <Description>ADMIN USER</Description> <DisplayName>Administrator</DisplayName> <Group>Administrators</Group> <Name>Administrator</Name> </LocalAccount> </LocalAccounts> </UserAccounts> <RegisteredOwner>Owner</RegisteredOwner> <RegisteredOrganization>Organization</RegisteredOrganization> <TimeZone>Central Standard Time</TimeZone> <AutoLogon> <Password> <Value>Password==</Value> <PlainText>false</PlainText> </Password> <Enabled>true</Enabled> <Username>administrator</Username> <LogonCount>10</LogonCount> </AutoLogon> </component> </settings> <settings pass="specialize"> <component name="Microsoft-Windows-IE-InternetExplorer" 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"> <DisableFirstRunWizard>true</DisableFirstRunWizard> <DisableOOBAccelerators>true</DisableOOBAccelerators> <EnableLinksBar>false</EnableLinksBar> <Home_Page>http://www.homepage.com</Home_Page> <ShowMenuBar>true</ShowMenuBar> </component> <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"> <WindowsFeatures> <ShowInternetExplorer>true</ShowInternetExplorer> </WindowsFeatures> <CopyProfile>true</CopyProfile> <ComputerName>ComputerName</ComputerName> <RegisteredOrganization>Organization</RegisteredOrganization> <RegisteredOwner>Owner</RegisteredOwner> </component> <component name="Microsoft-Windows-UnattendedJoin" 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"> <Identification> <Credentials> <Domain>Domain</Domain> <Password>Password</Password> <Username>Username</Username> </Credentials> <JoinDomain>domain.edu</JoinDomain> </Identification> </component> </settings> <settings pass="generalize"> <component name="Microsoft-Windows-Security-SPP" 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"> <SkipRearm>1</SkipRearm> </component> </settings> <cpi:offlineImage cpi:source="catalog:e:/sources/install_windows 7 enterprise.clg" xmlns:cpi="urn:schemas-microsoft-com:cpi"/></unattend> Edited January 10, 2013 by chaoticyeshua Link to comment Share on other sites More sharing options...
chaoticyeshua Posted January 10, 2013 Author Share Posted January 10, 2013 Nevermind, I'm an id***.I didn't know that sysprep caches the answer file at C:\Windows\Panther\unattend.xml. Replacing this XML with my modified one fixed it. Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now