locked
Enable Administrator Account RRS feed

  • Question

  • I want to enable the Administrator account and have the password set automaticly durring instillation.
    I am installing from a UFD.
    I have placed autounattend.xml in the root of my UFD but it doesn't seem to work.
    what am i doing wrong?
    here is the xml file i am using

    ------------------------------------------------------------------------

    <?xml version="1.0" encoding="utf-8"?>

    <unattend xmlns="urn:schemas-microsoft-com:unattend">

        <settings pass="oobeSystem">

            <component name="Microsoft-Windows-Shell-Setup" processorArchitecture="x86" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS" xmlns:wcm="http://schemas.microsoft.com/WMIConfig/2002/State" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">

                <UserAccounts>

                    <AdministratorPassword>

                        <Value>MyPassword</Value>

                        <PlainText>true</PlainText>

                    </AdministratorPassword>

                </UserAccounts>

                            <AutoLogon>

                    <Password>

                        <Value>MyPassword</Value>

                        <PlainText>true</PlainText>

                    </Password>

                    <Enabled>true</Enabled>

                    <LogonCount>1</LogonCount>

                    <Username>Administrator</Username>

                </AutoLogon>

            </component>

        </settings>

        <cpi:offlineImage cpi:source="wim:c:/image%20files/install.wim#Windows 7 Enterprise" xmlns:cpi="urn:schemas-microsoft-com:cpi" />

    </unattend>


     

    Thursday, October 7, 2010 1:27 PM

Answers

All replies

  • In the example here: http://technet.microsoft.com/en-us/library/dd744293(WS.10).aspx the order is a bit different in the section concerning <username>Administrator</username>

    I don't know if it matters, but it might be worth a shot?

    Thursday, October 7, 2010 1:56 PM
  • Hi,

    1. Enable the administrator account. It should be like in the specialize pass.

                <RunSynchronous>
                    <RunSynchronousCommand wcm:action="add">
                        <Description>EnableAdmin</Description>
                        <Order>1</Order>
                        <Path>cmd /c net user Administrator /active:yes</Path>
                    </RunSynchronousCommand>

    2. To set the password, in the oobesystem pass - Microsoft-Windows-Shell-Setup

                <UserAccounts>
                    <AdministratorPassword>
                        <Value>P@ssword</Value>
                        <PlainText>true</PlainText>
                    </AdministratorPassword>
                 </UserAccounts>

    Use the Windows System Image Manager to create your unattended file.


    Blog Microsoft | Déployer Windows 7 | Améliorer les performances de Windows 7
    Thursday, October 7, 2010 2:14 PM
  • the unattended.xml must be in the root of your ufd


    Blog Microsoft | Déployer Windows 7 | Améliorer les performances de Windows 7
    Thursday, October 7, 2010 3:10 PM
  • Hi,

    1. Enable the administrator account. It should be like in the specialize pass.

                <RunSynchronous>
                    <RunSynchronousCommand wcm:action="add">
                        <Description>EnableAdmin</Description>
                        <Order>1</Order>
                        <Path>cmd /c net user Administrator /active:yes</Path>
                    </RunSynchronousCommand>

    2. To set the password, in the oobesystem pass - Microsoft-Windows-Shell-Setup

                <UserAccounts>
                    <AdministratorPassword>
                        <Value>P@ssword</Value>
                        <PlainText>true</PlainText>
                    </AdministratorPassword>
                 </UserAccounts>

    Use the Windows System Image Manager to create your unattended file.


    Blog Microsoft | Déployer Windows 7 | Améliorer les performances de Windows 7
    and does this need to be in the unattend.xml that i run with sysprep befor i capture the image or in the autounattend.xml on my UFD with my image?
    Thursday, October 7, 2010 3:11 PM
  • when i do that i get an error "Windows could not parse or process... The answer file is invalid"

    any thoughts?

    Thursday, October 7, 2010 3:28 PM
  • Install WAIK for Windows 7, then open your file with WISM. Once you have edited your xml file click on the icon check for errors. it will tell you what's wrong.
    Blog Microsoft | Déployer Windows 7 | Améliorer les performances de Windows 7
    Thursday, October 7, 2010 3:30 PM
  • I fixed the autounattend and the instillation completed but the administrator account was not enabled. here is what i have...
    -------------------------------
    <?xml version="1.0" encoding="utf-8"?>
    <unattend xmlns="urn:schemas-microsoft-com:unattend">
        <settings pass="specialize">
            <component name="Microsoft-Windows-Shell-Setup" processorArchitecture="x86" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS" xmlns:wcm="http://schemas.microsoft.com/WMIConfig/2002/State" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
               <RunSynchronous>
                    <RunSynchronousCommand wcm:action="add">
                        <Description>EnableAdmin</Description>
                        <Order>1</Order>
                        <Path>cmd /c net user Administrator /active:yes</Path>
                    </RunSynchronousCommand>
    </RunSynchronous>
            </component>
        </settings>
        <settings pass="oobeSystem">
            <component name="Microsoft-Windows-Shell-Setup" processorArchitecture="x86" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS" xmlns:wcm="http://schemas.microsoft.com/WMIConfig/2002/State" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
                <UserAccounts>
                    <AdministratorPassword>
                        <Value>MyPassword</Value>
                        <PlainText>true</PlainText>
                    </AdministratorPassword>
                 </UserAccounts>
    <OOBE>
                    <NetworkLocation>Work</NetworkLocation>
                    <HideEULAPage>true</HideEULAPage>
                    <ProtectYourPC>2</ProtectYourPC>
    <SkipUserOOBE>true</SkipUserOOBE>
                </OOBE>
                <TimeZone>Eastern Standard Time</TimeZone>
            </component>
        </settings>
        <cpi:offlineImage cpi:source="wim:c:/image%20files/install.wim#Windows 7 ENTERPRISE" xmlns:cpi="urn:schemas-microsoft-com:cpi" />
    </unattend>
    Thursday, October 7, 2010 3:56 PM
  • ok, you just forgot the autolon part in the oobesystem pass - Microsoft-Windows-Shell-Setup

    <AutoLogon>
        <Enabled>true</Enabled>
        <Username>Administrator</Username>
        <Domain>.</Domain>
        <Password>
         <Value>P@ssword</Value>
         <PlainText>true</PlainText>
        </Password>
     </AutoLogon>


    Blog Microsoft | Déployer Windows 7 | Améliorer les performances de Windows 7
    Thursday, October 7, 2010 4:09 PM
  • thank you so much for your help but it still did not work. installation completed but Administrator not enabled.
    hers is what i have now
    ----------------------------------------------------------
    <?xml version="1.0" encoding="utf-8"?>
    <unattend xmlns="urn:schemas-microsoft-com:unattend">
        <settings pass="specialize">
            <component name="Microsoft-Windows-Shell-Setup" processorArchitecture="x86" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS" xmlns:wcm="http://schemas.microsoft.com/WMIConfig/2002/State" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
               <RunSynchronous>
                    <RunSynchronousCommand wcm:action="add">
                        <Description>EnableAdmin</Description>
                        <Order>1</Order>
                        <Path>cmd /c net user Administrator /active:yes</Path>
                    </RunSynchronousCommand>
    </RunSynchronous>
            </component>
        </settings>
        <settings pass="oobeSystem">
            <component name="Microsoft-Windows-Shell-Setup" processorArchitecture="x86" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS" xmlns:wcm="http://schemas.microsoft.com/WMIConfig/2002/State" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
                <UserAccounts>
                    <AdministratorPassword>
                        <Value>MyPassword</Value>
                        <PlainText>true</PlainText>
                    </AdministratorPassword>
                 </UserAccounts>
    <AutoLogon>
        <Enabled>true</Enabled>
        <Username>Administrator</Username>
        <Password>
         <Value>MyPassword</Value>
         <PlainText>true</PlainText>
        </Password>
     </AutoLogon>
    <OOBE>
                    <NetworkLocation>Work</NetworkLocation>
                    <HideEULAPage>true</HideEULAPage>
                    <ProtectYourPC>2</ProtectYourPC>
    <SkipUserOOBE>true</SkipUserOOBE>
                </OOBE>
                <TimeZone>Eastern Standard Time</TimeZone>
            </component>
        </settings>
        <cpi:offlineImage cpi:source="wim:c:/image%20files/install.wim#Windows 7 ENTERPRISE" xmlns:cpi="urn:schemas-microsoft-com:cpi" />
    </unattend>
    Thursday, October 7, 2010 4:56 PM
  • ok, use this in the auditSystem instead of oobe.

          <AutoLogon>
             <Password>
                <Value>SecurePasswd123</Value>
                <PlainText>true</PlainText>
             </Password>
             <Username>Administrator</Username>
             <Enabled>true</Enabled>
             <LogonCount>5</LogonCount>
          </AutoLogon>
          <UserAccounts>
             <AdministratorPassword>
                <Value>SecurePasswd123</Value>
                <PlainText>true</PlainText>
             </AdministratorPassword>
          </UserAccounts>
       </component>


    Blog Microsoft | Déployer Windows 7 | Améliorer les performances de Windows 7
    Thursday, October 7, 2010 5:04 PM
  • I'm sorry to say that gave me the same results. Administrator is still not enabled.
    here is what i have...
    -------------------------------------------------------
    <?xml version="1.0" encoding="utf-8"?>
    <unattend xmlns="urn:schemas-microsoft-com:unattend">
        <settings pass="specialize">
            <component name="Microsoft-Windows-Shell-Setup" processorArchitecture="x86" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS" xmlns:wcm="http://schemas.microsoft.com/WMIConfig/2002/State" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
                <RunSynchronous>
                    <RunSynchronousCommand wcm:action="add">
                        <Description>EnableAdmin</Description>
                        <Order>1</Order>
                        <Path>cmd /c net user Administrator /active:yes</Path>
                    </RunSynchronousCommand>
                </RunSynchronous>
            </component>
        </settings>
        <settings pass="oobeSystem">
            <component name="Microsoft-Windows-Shell-Setup" processorArchitecture="x86" 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>
                    <NetworkLocation>Work</NetworkLocation>
                    <HideEULAPage>true</HideEULAPage>
                    <ProtectYourPC>2</ProtectYourPC>
                    <SkipUserOOBE>true</SkipUserOOBE>
                </OOBE>
                <TimeZone>Eastern Standard Time</TimeZone>
            </component>
        </settings>
        <settings pass="auditSystem">
            <component name="Microsoft-Windows-Shell-Setup" processorArchitecture="x86" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS" xmlns:wcm="http://schemas.microsoft.com/WMIConfig/2002/State" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
    <AutoLogon>
             <Password>
                <Value>MyPassword</Value> 
                <PlainText>true</PlainText> 
             </Password>
             <Username>Administrator</Username> 
             <Enabled>true</Enabled> 
             <LogonCount>5</LogonCount> 
          </AutoLogon>
          <UserAccounts>
             <AdministratorPassword>
                <Value>MyPassword</Value> 
                <PlainText>true</PlainText> 
             </AdministratorPassword>
          </UserAccounts>
            </component>
        </settings>
        <cpi:offlineImage cpi:source="wim:c:/users/bcooper.msu/documents/windowes%207%20image/sources/install.wim#Windows 7 ENTERPRISE" xmlns:cpi="urn:schemas-microsoft-com:cpi" />
    </unattend>

    Thursday, October 7, 2010 5:39 PM
    • Marked as answer by Leo Huang Thursday, October 14, 2010 7:45 AM
    Thursday, October 7, 2010 5:44 PM