Mikep7779 Posted July 21, 2008 Posted July 21, 2008 (edited) Due to hard drive failure, i lost my unattended settings. Since then i have started the process but for the life of me i cant get guirunonce to work.Ill attach my winnt.sif, my folder layout and so on.Winnt.sif:;SetupMgrTag[Data] AutoPartition=0 MsDosInitiated="0" UnattendedInstall="Yes"[Unattended] UnattendMode=FullUnattended OemSkipEula=Yes OemPreinstall=Yes FileSystem=* TargetPath=\WINDOWS UnattendSwitch="yes" WaitForReboot="No" DriverSigningPolicy=Ignore[GuiUnattended] AdminPassword="LOL WUT" EncryptedAdminPassword=NO AutoLogon=Yes AutoLogonCount=9999999 OEMSkipRegional=1 TimeZone=35 OemSkipWelcome=1[UserData] ProductKey=LOL WUT KEY GOES HERE FullName="HO HO HO" OrgName="" ComputerName=Panda[GuiRunOnce] Command0="%systemdrive%\windows\system32\Install.cmd"[Identification] JoinWorkgroup=WORKGROUP[Networking] InstallDefaultComponents=YesMy install.cmd is in "\$OEM$\$$\System32". when i double click the file, everything goes great. It just wont run the file on its own at first login.Install.cmd:cmdow @ /HID@echo offSET KEY=HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\RunOnceExREG ADD %KEY% /V TITLE /D "Installing Applications" /f REG ADD %KEY%\002 /VE /D "Steam" /f REG ADD %KEY%\002 /V 1 /D "%systemdrive%\install\Applications\steam.msi /qn" /f REG ADD %KEY%\002 /VE /D "Additions to Sendto" /f REG ADD %KEY%\002 /V 1 /D "%systemdrive%\install\Applications\ftp sendto.cmd" /f REG ADD %KEY%\099 /VE /D "Cleaning Up and Rebooting" /f REG ADD %KEY%\099 /V 1 /D "%systemdrive%\install\cleanup.cmd" /fEXITThe install files are located in $OEM$\$1\Install. I am out of ideas.Any ideas? Edited July 21, 2008 by Mikep7779
COKEDUDEUSF Posted July 21, 2008 Posted July 21, 2008 [GuiUnattended]AdminPassword="LOL WUT"EncryptedAdminPassword=NOAutoLogon=YesAutoLogonCount=9999999OEMSkipRegional=1TimeZone=35OemSkipWelcome=1I'm pretty sure you have 3 mistakes with this. You need to have these 3 lines below.EncryptedAdminPassword="No"AutoLogon="Yes"AdminPassword=*You forgot quotes and password needs to be a *.
Flip1001 Posted July 21, 2008 Posted July 21, 2008 Your install.cmd is setup to be run from cmdlines.txt. Comment out or remove the guirunonce section in your winnt.sif.Move the install.cmd from \$OEM$\$$\System32 to $OEM$ and add "install.cmd" at the end of cmdlines.txt. Leave your install files in the $OEM$\$1\install folder.
Mikep7779 Posted July 21, 2008 Author Posted July 21, 2008 Your install.cmd is setup to be run from cmdlines.txt. Comment out or remove the guirunonce section in your winnt.sif.Move the install.cmd from \$OEM$\$$\System32 to $OEM$ and add "install.cmd" at the end of cmdlines.txt. Leave your install files in the $OEM$\$1\install folder.Thanks, i dont know why i had it set up that way. I only had a setup from 2 years ago left on a CD, tried to copy some of the stuff over. Guess it didnt work.Thanks!
Mikep7779 Posted July 21, 2008 Author Posted July 21, 2008 (edited) Your install.cmd is setup to be run from cmdlines.txt. Comment out or remove the guirunonce section in your winnt.sif.Move the install.cmd from \$OEM$\$$\System32 to $OEM$ and add "install.cmd" at the end of cmdlines.txt. Leave your install files in the $OEM$\$1\install folder.Thanks, i dont know why i had it set up that way. I only had a setup from 2 years ago left on a CD, tried to copy some of the stuff over. Guess it didnt work.Thanks!Did what you said, and then i rechecked everything. Still no go. All the files end up on the HDD, but the cmd just isnt running. I have to be missing somthing else.Here are more of the settings"cmdlines.txt:[COMMANDS]"Install.cmd"I have my Install.cmd in the $OEM$ with the cmdlines.txt, im just out of idea on why it wont run. Edited July 21, 2008 by Mikep7779
MHz Posted July 22, 2008 Posted July 22, 2008 Steam install will not work as you overwrite the registry entries with the following SendTo entries. The SendTo entries may fail as whitespace exists in the path in which no double quotes used to keep the path together as one string. I would guess that cleanup will work as expected.It is mentioned in the unattended guide about using quotes and using a backslash to escape them. Escaped double quotes will be added to registry where as the outer double quotes will not. Below shows your code with escaped double quotes added. Simply clicking on the CMD file adds the entries to the registry for you to examine for being correct. Remove the registry entries when the test is done.cmdow @ /HID@echo offSET KEY=HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\RunOnceExREG ADD %KEY% /V TITLE /D "Installing Applications" /fREG ADD %KEY%\002 /VE /D "Steam" /fREG ADD %KEY%\002 /V 1 /D "\"%systemdrive%\install\Applications\steam.msi\" /qn" /fREG ADD %KEY%\003 /VE /D "Additions to Sendto" /fREG ADD %KEY%\003 /V 1 /D "\"%systemdrive%\install\Applications\ftp sendto.cmd\"" /fREG ADD %KEY%\099 /VE /D "Cleaning Up and Rebooting" /fREG ADD %KEY%\099 /V 1 /D "\"%systemdrive%\install\cleanup.cmd\"" /fEXITThe entries of concern are the entries with known or possible whitespace but I double quoted all to show a thorough example.
Mikep7779 Posted July 22, 2008 Author Posted July 22, 2008 Holy hell, I didnt even see those. I now understand that the white space was causing the issue. Thanks for the help, i will test it in the morning.Thanks again.
Mikep7779 Posted July 22, 2008 Author Posted July 22, 2008 Even after the fixes, the cmd still wont run, i may just scrap it all and start from scratch.
emgee1465 Posted July 23, 2008 Posted July 23, 2008 I believe that what you're calling 'Install.cmd' should be 'RunOnceEx.cmd'?
Martin H Posted July 24, 2008 Posted July 24, 2008 Please double-check that you have done the following, as this setup should be working fine :\$OEM$\cmdlines.txt\$OEM$\Install.cmd\$OEM$\$1\Install\cmdlines.txt :[COMMANDS]"Install.cmd"winnt.sif :[Unattended] OemPreinstall=Yes(+ remove the GuiRunOnce part)Then you just need to check that all the paths defined in Install.cmd are correct and that if you are on Win2k, then you need to add reg.exe to your install-source... Also, sorry for nitpicking here, but if you have cmdow.exe on your install-source, then i would ditch the '@echo off' after 'cmdow @ /hid' and instead use '@cmdow @ /hid', but this is unrelated to your issue, though...
Recommended Posts
Please sign in to comment
You will be able to leave a comment after signing in
Sign In Now