none
SetupComplete.cmd copies but doesn't run automatically after setup completes. RRS feed

  • Question

  • Hi,

    My SetupComplete.cmd copies locally to C:\Windows\Setup\Scripts successfully after Windows 8 unattended setup completes, but it doesn't run automatically as it suppose to. I can run the script manually but not automatically. Basically, SetupComplete.cmd script is to connect to network share which then in turn run a batch script which contains a bunch of apps. Few days ago, script somehow mapped to network share automatically but the next day it stopped doing it for some reason. No changes were made to the script or unattended file until it stopped mapping automatically. Since then, I've been trying different changes to the script to make it work but none of those have worked so far. Weird thing is that I can manually run the script and it maps to the network share and install all the programs.

    I've been using VMware setup to test out unattended deployment and the scripts. Not sure, if VMware has anything to do with it.

    Please check out my unattend xml file and script and suggest me some solution. I'm tired of trying different things for last 2 days without getting anywhere with it.

    SetupComplete.cmd script
    
    net use z: \\192.168.5.2\Apps /user:Mikasa.local\Administrator Ghtwhts2015
    
    z:\Prog.bat


    Unattended Xml File
    
    <?xml version="1.0" encoding="UTF-8"?>
    
    -<unattend xmlns="urn:schemas-microsoft-com:unattend">
    
    
    -<settings pass="specialize">
    
    
    -<component language="neutral" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:wcm="http://schemas.microsoft.com/WMIConfig/2002/State" versionScope="nonSxS" publicKeyToken="31bf3856ad364e35" processorArchitecture="amd64" name="Microsoft-Windows-Shell-Setup">
    
    
    -<OEMInformation>
    
    <Manufacturer>HP</Manufacturer>
    
    <Model>HP Elitebook 850 G1</Model>
    
    </OEMInformation>
    
    
    -<WindowsFeatures>
    
    <ShowInternetExplorer>true</ShowInternetExplorer>
    
    <ShowMediaCenter>false</ShowMediaCenter>
    
    <ShowWindowsMediaPlayer>true</ShowWindowsMediaPlayer>
    
    </WindowsFeatures>
    
    <ComputerName>Win8-Sisense</ComputerName>
    
    <CopyProfile>true</CopyProfile>
    
    <ProductKey>NG4HW-VH26C-733KW-K6F98-J8CK4</ProductKey>
    
    <RegisteredOrganization>Sisense</RegisteredOrganization>
    
    <RegisteredOwner>Sisense</RegisteredOwner>
    
    <TimeZone>eastern standard time</TimeZone>
    
    <BluetoothTaskbarIconEnabled>false</BluetoothTaskbarIconEnabled>
    
    </component>
    
    
    -<component language="neutral" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:wcm="http://schemas.microsoft.com/WMIConfig/2002/State" versionScope="nonSxS" publicKeyToken="31bf3856ad364e35" processorArchitecture="amd64" name="Microsoft-Windows-Deployment">
    
    
    -<RunSynchronous>
    
    
    -<RunSynchronousCommand wcm:action="add">
    
    <Path>net user administrator /active:yes</Path>
    
    <Description>Admin Built-In Account</Description>
    
    <Order>1</Order>
    
    <WillReboot>Never</WillReboot>
    
    </RunSynchronousCommand>
    
    
    -<RunSynchronousCommand wcm:action="add">
    
    <Path>REG ADD "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\CurrentVersion\NetworkList\Signatures\FirstNetwork" /v Category /t REG_DWORD /d 00000000 /f</Path>
    
    <Order>2</Order>
    
    <Description>Disable Network Location Prompt</Description>
    
    </RunSynchronousCommand>
    
    </RunSynchronous>
    
    </component>
    
    
    -<component language="neutral" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:wcm="http://schemas.microsoft.com/WMIConfig/2002/State" versionScope="nonSxS" publicKeyToken="31bf3856ad364e35" processorArchitecture="amd64" name="Microsoft-Windows-IE-InternetExplorer">
    
    <BlockPopups>yes</BlockPopups>
    
    <DisableFirstRunWizard>true</DisableFirstRunWizard>
    
    <DisableAccelerators>true</DisableAccelerators>
    
    <Home_Page>www.marca.com</Home_Page>
    
    </component>
    
    
    -<component language="neutral" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:wcm="http://schemas.microsoft.com/WMIConfig/2002/State" versionScope="nonSxS" publicKeyToken="31bf3856ad364e35" processorArchitecture="amd64" name="Microsoft-Windows-TerminalServices-LocalSessionManager">
    
    <fDenyTSConnections>false</fDenyTSConnections>
    
    </component>
    
    
    -<component language="neutral" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:wcm="http://schemas.microsoft.com/WMIConfig/2002/State" versionScope="nonSxS" publicKeyToken="31bf3856ad364e35" processorArchitecture="amd64" name="Networking-MPSSVC-Svc">
    
    
    -<FirewallGroups>
    
    
    -<FirewallGroup wcm:action="add" wcm:keyValue="Remote Desktop">
    
    <Active>true</Active>
    
    <Profile>all</Profile>
    
    <Group>Remote Desktop</Group>
    
    </FirewallGroup>
    
    </FirewallGroups>
    
    </component>
    
    
    -<component language="neutral" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:wcm="http://schemas.microsoft.com/WMIConfig/2002/State" versionScope="nonSxS" publicKeyToken="31bf3856ad364e35" processorArchitecture="amd64" name="Microsoft-Windows-TerminalServices-RDP-WinStationExtensions">
    
    <UserAuthentication>0</UserAuthentication>
    
    </component>
    
    
    -<component language="neutral" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:wcm="http://schemas.microsoft.com/WMIConfig/2002/State" versionScope="nonSxS" publicKeyToken="31bf3856ad364e35" processorArchitecture="amd64" name="Microsoft-Windows-Security-SPP-UX">
    
    <SkipAutoActivation>true</SkipAutoActivation>
    
    </component>
    
    </settings>
    
    
    -<settings pass="generalize">
    
    
    -<component language="neutral" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:wcm="http://schemas.microsoft.com/WMIConfig/2002/State" versionScope="nonSxS" publicKeyToken="31bf3856ad364e35" processorArchitecture="amd64" name="Microsoft-Windows-Security-SPP">
    
    <SkipRearm>1</SkipRearm>
    
    </component>
    
    </settings>
    
    
    -<settings pass="offlineServicing">
    
    
    -<component language="neutral" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:wcm="http://schemas.microsoft.com/WMIConfig/2002/State" versionScope="nonSxS" publicKeyToken="31bf3856ad364e35" processorArchitecture="amd64" name="Microsoft-Windows-LUA-Settings">
    
    <EnableLUA>false</EnableLUA>
    
    </component>
    
    </settings>
    
    
    -<settings pass="oobeSystem">
    
    
    -<component language="neutral" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:wcm="http://schemas.microsoft.com/WMIConfig/2002/State" versionScope="nonSxS" publicKeyToken="31bf3856ad364e35" processorArchitecture="amd64" name="Microsoft-Windows-Shell-Setup">
    
    
    -<AutoLogon>
    
    
    -<Password>
    
    <Value>RwBoAHQAdwBoAHQAcwAyADAAMQA2AFAAYQBzAHMAdwBvAHIAZAA=</Value>
    
    <PlainText>false</PlainText>
    
    </Password>
    
    <Enabled>true</Enabled>
    
    <LogonCount>10</LogonCount>
    
    <Username>Administrator</Username>
    
    </AutoLogon>
    
    
    -<OOBE>
    
    <HideEULAPage>true</HideEULAPage>
    
    <HideWirelessSetupInOOBE>true</HideWirelessSetupInOOBE>
    
    <NetworkLocation>Home</NetworkLocation>
    
    <HideOEMRegistrationScreen>true</HideOEMRegistrationScreen>
    
    <ProtectYourPC>1</ProtectYourPC>
    
    <HideLocalAccountScreen>true</HideLocalAccountScreen>
    
    <HideOnlineAccountScreens>true</HideOnlineAccountScreens>
    
    </OOBE>
    
    
    -<UserAccounts>
    
    
    -<AdministratorPassword>
    
    <Value>RwBoAHQAdwBoAHQAcwAyADAAMQA2AEEAZABtAGkAbgBpAHMAdAByAGEAdABvAHIAUABhAHMAcwB3AG8AcgBkAA==</Value>
    
    <PlainText>false</PlainText>
    
    </AdministratorPassword>
    
    
    -<LocalAccounts>
    
    
    -<LocalAccount wcm:action="add">
    
    
    -<Password>
    
    <Value>RwBoAHQAdwBoAHQAcwAyADAAMQA1AFAAYQBzAHMAdwBvAHIAZAA=</Value>
    
    <PlainText>false</PlainText>
    
    </Password>
    
    <Description>Local Admin Account</Description>
    
    <DisplayName>MSIADMIN</DisplayName>
    
    <Group>Administrators</Group>
    
    <Name>MSIADMIN</Name>
    
    </LocalAccount>
    
    </LocalAccounts>
    
    </UserAccounts>
    
    <BluetoothTaskbarIconEnabled>false</BluetoothTaskbarIconEnabled>
    
    <RegisteredOrganization>Sisense</RegisteredOrganization>
    
    <RegisteredOwner>Sisense</RegisteredOwner>
    
    <TimeZone>eastern standard time</TimeZone>
    
    
    -<FirstLogonCommands>
    
    
    -<SynchronousCommand wcm:action="add">
    
    <CommandLine>"%WINDIR%\Setup\Scripts\SetupComplete.cmd"</CommandLine>
    
    <Description>Apps Silent Installation</Description>
    
    <Order>1</Order>
    
    <RequiresUserInput>false</RequiresUserInput>
    
    </SynchronousCommand>
    
    </FirstLogonCommands>
    
    </component>
    
    
    -<component language="neutral" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:wcm="http://schemas.microsoft.com/WMIConfig/2002/State" versionScope="nonSxS" publicKeyToken="31bf3856ad364e35" processorArchitecture="amd64" name="Microsoft-Windows-International-Core">
    
    <InputLocale>en-US</InputLocale>
    
    <SystemLocale>en-US</SystemLocale>
    
    <UILanguage>en-US</UILanguage>
    
    <UserLocale>en-US</UserLocale>
    
    </component>
    
    </settings>
    
    <cpi:offlineImage xmlns:cpi="urn:schemas-microsoft-com:cpi" cpi:source="wim:e:/windows-os-images/sisense-elitebook-850g1/win8-pro-x64/install.wim#Windows 8 Pro"/>
    
    </unattend>


    Prog.bat 
    
    
    start /wait msiexec /i z:\7z920-x64.msi /quiet /qn 
    start /wait z:\vlc-2.1.5-win64.exe /L=1033 /S
    start /wait z:\setup64.exe /s /v "/qn Reboot=ReallySuppress" 
    start /wait msiexec /i z:\ccsetup416.msi /qn  
    start /wait msiexec /i z:\Firefox-32.0-en-US.msi -ms /qn /q 
    start /wait z:\jre-8u25.exe /s 
    start /wait msiexec /i z:\SkypeSetup.msi /qn /q /norestart
    start /wait z:\AdbeRdr1014_en_US.exe /sPB /rs
    z:\pkeyui.exe > %systemdrive\Users\myWin8oemkey.txt
    for /f %%1 in (%systemdrive\Users\myWin8oemkey.txt) do cscript.exe %systemroot%\system32\slmgr.vbs /ipk %%1
    cscript.exe //B slmgr.vbs /ato
    

    Please take a look and help me fix this issue.

    Looking forward to hear.

    Thanks

    Omar

    Wednesday, January 21, 2015 12:40 AM