Jump to content

cmdlines.txt problem


RyanVM

Recommended Posts


OK, then I really have no clue why it's not working :)

This is my cmdlines.txt (location $OEM$\):

[COMMANDS]
".\update.bat"

This is my update.bat (location $OEM$\):

CLS
@echo off
TITLE Installing WindowsXP SP1 Hotfixes
ECHO.
ECHO Installing q282010: Jet 4.0 Service Pack 7...
start /wait %systemdrive%\Updates\q282010.exe /Q /U /Z
ECHO.
ECHO Installing q322011: Cannot Preview a Fax in the Fax Console...
start /wait %systemdrive%\Updates\q322011.exe /Q /U /Z
ECHO.
ECHO Installing q323255: Unchecked Buffer in Help May Allow Attacker to Run Code...
start /wait %systemdrive%\Updates\q323255.exe /Q /U /Z
ECHO.
ECHO Installing q327405: Security and Privacy Information Update...
start /wait %systemdrive%\Updates\q327405.exe /Q:A /R:N
ECHO.
ECHO Installing q327979: Game Stops Responding When Introductory Video Is Played...
start /wait %systemdrive%\Updates\q327979.exe /Q /U /Z
ECHO.
ECHO Installing q328310: Flaw in Message Handling Could Enable Privilege Elevation...
start /wait %systemdrive%\Updates\q328310.exe /Q /U /Z
ECHO Installing q329048: Unchecked Buffer in File Decompression May Allow Bad Code...
start /wait %systemdrive%\Updates\q329048.exe /Q /U /Z
ECHO Installing q329115: Certificate Validation Flaw May Enable Identity Spoofing...
start /wait %systemdrive%\Updates\q329115.exe /Q /U /Z
ECHO.
ECHO Installing q329170: SMB Signing Flaw May Allow Group Policy Modification...
start /wait %systemdrive%\Updates\q329170.exe /Q /U /Z
ECHO.
ECHO Installing q329256: Inconsistent Gap Count Can Cause 1394 Enumeration Failure...
start /wait %systemdrive%\Updates\q329256.exe /Q /U /Z
ECHO Installing q329390: Unchecked Buffer in Windows Shell May Allow Compromizing...
start /wait %systemdrive%\Updates\q329390.exe /Q /U /Z
ECHO.
ECHO Installing q329441: Cannot Create Network Connection After Windows XP Restore...
start /wait %systemdrive%\Updates\q329441.exe /Q /U /Z
ECHO Installing q329623: Problems with InterVideo DVD Software...
start /wait %systemdrive%\Updates\q329623.exe /Q /U /Z
ECHO.
ECHO Installing q329692: Explorer.exe May Generate Error When Folder Closed...
start /wait %systemdrive%\Updates\q329692.exe /Q /U /Z
ECHO.
ECHO Installing q329834: Unchecked Buffer in PPTP May Allow DoS Attacks...
start /wait %systemdrive%\Updates\q329834.exe /Q /U /Z
ECHO.
ECHO Installing q330512: Processor State Not Restored If CPU at 100 Percent...
start /wait %systemdrive%\Updates\q330512.exe /Q /U /Z
ECHO.
ECHO Installing q330994: April 2003 Cumulative Patch for Outlook Express...
start /wait %systemdrive%\Updates\q330994.exe /Q:A /R:N
ECHO.
ECHO Installing q331953: RPC Endpoint Mapper Flaw Could Allow DoS Attacks...
start /wait %systemdrive%\Updates\q331953.exe /Q /U /Z
ECHO.
ECHO Installing q810032: Panasonic DV Camera May Not Enumerate...
start /wait %systemdrive%\Updates\q810032.exe /Q /U /Z
ECHO.
ECHO Installing q810243: Playback Support for WindowsXP Media Center Edition Files...
start /wait %systemdrive%\Updates\q810243.exe /Q /U /Z
ECHO Installing q810272: Audio Test Causes Computer to Stop Responding...
start /wait %systemdrive%\Updates\q810272.exe /Q /U /Z
ECHO.
ECHO Installing q810565: Links Open in Internet Explorer Instead of Default...
start /wait %systemdrive%\Updates\q810565.exe /Q /U /Z
ECHO.
ECHO Installing q810577: Unchecked Buffer in Redirector Allows Privilege Elevation...
start /wait %systemdrive%\Updates\q810577.exe /Q /U /Z
ECHO Installing q810833: Unchecked Buffer in Locator Service May Allow Code to Run...
start /wait %systemdrive%\Updates\q810833.exe /Q /U /Z
ECHO Installing q811493: Buffer Overrun in Kernel Message Handling May Allow                             Privilege Elevation...
start /wait %systemdrive%\Updates\q811493.exe /Q /U /Z
ECHO.
ECHO Installing q811630: HTML Help Update...
start /wait %systemdrive%\Updates\q811630.exe /Q /U /Z
ECHO.
ECHO Installing q812035: Crash Occurs in Ks.sys on Intel CPUs with Hyper-Threading...
start /wait %systemdrive%\Updates\q812035.exe /Q /U /Z
ECHO Installing q812415: Problems When Computer with Many Drives Enters S1 State...
start /wait %systemdrive%\Updates\q812415.exe /Q /U /Z
ECHO.
ECHO Installing q813503: Adding and Removing IFRAME with Filters Crashes IE...
start /wait %systemdrive%\Updates\q813503.exe /Q:A /R:N
ECHO.
ECHO Installing q814033: Cannot Install Driver Updates from Windows Update...
start /wait %systemdrive%\Updates\q814033.exe /Q /U /Z
ECHO.
ECHO Installing q814078: Flaw in Windows Script Engine May Allow Code Execution...
start /wait %systemdrive%\Updates\q814078.exe /Q:A /R:N
ECHO.
ECHO Installing q814995: Some Compatibility Fixes Don't Work After q328310 Update...
start /wait %systemdrive%\Updates\q814995.exe /Q /U /Z
ECHO.
ECHO Installing q815485: WPA Wireless Security Update...
start /wait %systemdrive%\Updates\q815485.exe /Q /U /Z
ECHO.
ECHO Installing q816073: Compile on WindowsXP System Slower Than WindowsNT System...
start /wait %systemdrive%\Updates\q816073.exe /Q /U /Z
ECHO.
ECHO Installing q816868: Error Message: "Internet Explorer Cannot Download File"...
start /wait %systemdrive%\Updates\q816868.exe /Q:A /R:N
ECHO.
ECHO Installing q817287: Windows Update 643 Error and Catalog Database...
start /wait %systemdrive%\Updates\q817287.exe /Q:A /R:N
ECHO.
ECHO Installing q817606: Buffer Overrun in Windows Could Lead to Data Corruption...
start /wait %systemdrive%\Updates\q817606.exe /Q /U /Z
ECHO.
ECHO Installing q817778: Advanced Networking Pack for Windows XP...
start /wait %systemdrive%\Updates\q817778.exe /Q /U /Z
ECHO.
ECHO Installing q817787: Media Player Skin Downloading May Allow Code Execution...
start /wait %systemdrive%\Updates\q817787.exe /Q:A /R:N
ECHO.
ECHO Installing q820128: Windows XP Service Pack 1 Kernel Rollup Hotfix Package...
start /wait %systemdrive%\Updates\q820128.exe /Q /U /Z
ECHO.
ECHO Installing q820291: "Set Program Access and Defaults" Icon and Help Content...
start /wait %systemdrive%\Updates\q820291.exe /Q /U /Z
ECHO.
ECHO Installing q820761: Microsoft Data Access Components 2.8...
start /wait %systemdrive%\Updates\q820761.exe /C:"dasetup.exe /q /n" /q
ECHO.
ECHO Installing q821253: Update For Windows Error Reporting...
start /wait %systemdrive%\Updates\q821253.exe /Q /U /Z
ECHO.
ECHO Installing q821557: Unchecked Buffer in Shell May Allow System Compromizing...
start /wait %systemdrive%\Updates\q821557.exe /Q /U /Z
ECHO.
ECHO Installing q821581: Performance Data from BootVis.exe Is Corrupted or Missing...
start /wait %systemdrive%\Updates\q821581.exe /Q /U /Z
ECHO Installing q822603: Windows XP SP1 USB 1.1 and 2.0 Driver Update...
start /wait %systemdrive%\Updates\q822603.exe /Q /U /Z
ECHO.
ECHO Installing q822925: August 2003 Cumulative Patch for Internet Explorer...
start /wait %systemdrive%\Updates\q822925.exe /Q:A /R:N
ECHO.
ECHO Installing q823559: HTML Converter Buffer Overrun May Allow Code Execution...
start /wait %systemdrive%\Updates\q823559.exe /Q /U /Z
ECHO.
ECHO Installing q824105: Flaw in NetBIOS Could Lead to Information Disclosure...
start /wait %systemdrive%\Updates\q824105.exe /Q /U /Z
ECHO.
ECHO Installing q824146: Buffer Overrun in RPCSS May Allow Code Execution...
start /wait %systemdrive%\Updates\q824146.exe /Q /U /Z
ECHO.
ECHO Installing DirectX 9.0b...
start /wait %systemdrive%\Updates\dx9\dxsetup.exe /opk
ECHO.
ECHO Installing q825116: DirectX 9.0b TV Tuner Update...
start /wait %systemdrive%\Updates\q825116.exe /Q /U /Z
ECHO.
ECHO Applying Registry Tweaks...
REGEDIT /S %systemdrive%\Updates\reghacks.reg
ECHO.
EXIT

And lastly, this is my winnt.sif:

[Data]
AutoPartition=0
MsDosInitiated="0"
UnattendedInstall="Yes"

[Unattended]
AutoActivate=No
UnattendMode=DefaultHide
OemSkipEula=Yes
OemPreinstall=Yes
TargetPath=\WINDOWS
UnattendSwitch="no"
WaitForReboot="No"
DriverSigningPolicy=Ignore
Repartition=No
OemPnPDriversPath="Drivers\AMD"

[GuiUnattended]
EncryptedAdminPassword=NO
OEMSkipRegional=1
TimeZone=35
OemSkipWelcome=0

[UserData]
FullName=""
OrgName=""

[Display]
BitsPerPel=32
Xresolution=1024
YResolution=768
Vrefresh=75

[TapiLocation]
CountryCode=1

[RegionalSettings]
LanguageGroup=1
Language=00000409

[Identification]
JoinWorkgroup=WORKGROUP

[Networking]
InstallDefaultComponents=No

[NetAdapters]
Adapter1=params.Adapter1

[params.Adapter1]
INFID=*

[NetClients]
MS_MSClient=params.MS_MSClient

[NetServices]
MS_SERVER=params.MS_SERVER

[NetProtocols]
MS_TCPIP=params.MS_TCPIP

[params.MS_TCPIP]
DNS=Yes
UseDomainNameDevolution=No
EnableLMHosts=Yes
AdapterSections=params.MS_TCPIP.Adapter1

[params.MS_TCPIP.Adapter1]
SpecificTo=Adapter1
DHCP=Yes
WINS=No
NetBIOSOptions=0

[Components]
accessopt=off
chat=off
dialer=off
hypertrm=off
iis_webadmin=off
indexsrv_system=off
media_clips=off
msmsgs=off
msnexplr=off
netoc=off
Pop3Service=off
Pop3Srv=off
WMPOCM=off
zonegames=off

[GuiRunOnce]
%systemdrive%\Updates\guiupdate.bat

Is there anything glaringly obvious that stands out to you in any of this?

Link to comment
Share on other sites

start /wait %systemdrive%\Updates\q282010.exe /Q /U /Z

Can't remember if you need quotes when using envronement variables... Perhaps

start /wait "%systemdrive%\Updates\q282010.exe" /Q /U /Z

If you put a "PAUSE" at the end, you will be able to see any error messages written to the screen.

Link to comment
Share on other sites

First of all, I wanted to thank you Webmedic and GreenMachine for such a nice explaination on the cmmlines.txt. Even myself was confuse at first about the rules and etc... Now I got good a concept and understanding of it. I went through my third time and I got everything running except still having trouble copying files over to the Default User folder.

I'm getting this error message when executing this statement in the tweaks.cmd.

Statement 1:

XCOPY /E /C /Y /Q /H ".\Profiles\*.*" "%ProfilesDir%\"

Error Msg 1:

Access Denied

Statement 2:

"COPY /y ".\Tweaks\winxp.bat.lnk" "%ProfilesDir%\Default User\Start Menu\Programs\Startup\"

Error Msg 2:

"Unable to create directory - E:\Default User"

Here is my code for tweaks.cmd

REM ----------------------------------------------------------------------
ECHO Customizing Windows using the Default User profile.
ECHO.

ECHO Importing Restiry Tweaks
START "Importing Restiry Tweaks" /WAIT REGEDIT /S ".\Tweaks\tweaks.reg"
ECHO.

ECHO Customizing the Quick Launch and Start Menu...
XCOPY /E /C /Y /Q /H ".\Profiles\*.*" "%ProfilesDir%\"
ECHO.

COPY /y ".\Tweaks\winxp.bat" "%ProgramFiles%\"
COPY /y ".\Tweaks\winxp.reg" "%ProgramFiles%\"
COPY /y ".\Tweaks\winxp.bat.lnk" "%ProfilesDir%\Default User\Start Menu\Programs\Startup\"
ECHO.

PAUSE
ECHO Press any key to continue...

EXIT

Here is my $OEM$ directory structure

$OEM$\Profiles\Default User\Application Data\
$OEM$\Profiles\Default User\My Documents
$OEM$\Profiles\Default User\Start Menu
$OEM$\Tweaks\

-Kenneth

Link to comment
Share on other sites

By the way, anyone know how to automote so Windows automitcally sort the "All Program" folder in Start Menu with this hack:

; Start Menu - Enable automatic sorting by alphabetial order in Start Menu
[-HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\MenuOrder\Start Menu]
[-HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\MenuOrder\Start Menu2]
[-HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\MenuOrder\Favorites]

You have to run this registry tweak whenever you manually re-organize the icons or folders in the "All Program" folder to make auto sorting again.

Currently I have to run a batch file in the Startup Folder to regedit. Is there another way to do it without this batch hack?

-Kenneth

Link to comment
Share on other sites

Statement 1:

XCOPY /E /C /Y /Q /H ".\Profiles\*.*" "%ProfilesDir%\"

Should read
Statement 1:

XCOPY ".\Profiles\*.*" "%ProfilesDir%\" /E /C /Y /Q /H

Statement 2: For some reason either %PROFILESDIR% is evaluating to NULL, and the drive E is used, as there is no drive letter in the path. Or perhaps you previously defined PROILESDIR to be "E:\"? If not, I would think that E: is the CD drive letter, which would explain the "Unable to create directory - E:\Default User" error - cannot create a directory on the CD. If you are unsure of the PROFILESDIR value, you can add this to your batch file:

ECHO PROFILESDIR is %PROFILESDIR%

and it will show you on the screen where it thinks the profiles are to be kept.

PROFILESDIR is undefined after the cmdlines.txt portion of setup, and could cause both your problems if it is undefined. If you get the first statement working, you do not need the second statement: just put your files in the Profiles directory, with the proper directory structure.

I have never found a way to prevent Windows from re-defining the Start Menu Sort Order whenever MenuItems are re-arranged, or new programs are added, but I have not looked too far as my solution works fine. (I never re-arrange by hand, and it is VERY rare that I add a new program.)

Link to comment
Share on other sites

start /wait %systemdrive%\Updates\q282010.exe /Q /U /Z

Can't remember if you need quotes when using envronement variables... Perhaps

start /wait "%systemdrive%\Updates\q282010.exe" /Q /U /Z

If you put a "PAUSE" at the end, you will be able to see any error messages written to the screen.

I'll add quotes and put a pause at the end and see if it helps. Problem is, I don't think the batch file is being called in the first place :)

Link to comment
Share on other sites

Thanks RyanVM and GreenMachine for the replies. Yes, I'm using the PAUSE trick to check and verify my testing. :) And Yes, you are right about the xcopy switches needs to be after the source. I was trying to make my cmd file have a consist look but guess not all command switches can added after the command. hehe...

In another topic, you show us to use the SET and PAUSE command to get a list of environment variables. Indead the %profilesdir% doesn't exist. But the %userprofile% does exist. I'll try use it and see what happen. I'll let you guys know what the result is.

If it is possible, how do you create your own environment variable? And where you do specify that at?

-Kenneth

Link to comment
Share on other sites

The SET command takes care of the variables - adds, deletes, modifies and lists 'em. You can do it from the command prompt or in a batch file, there is not really much to it. Type set /? for usage ...

SET VARNAME=VARVALUE ; You have the variable name VARNAME assigned the value VARVALUE

SET VARNAME= ; Variable VARNAME is gone

SET X=%VARNAME% ; X now equals VARVALUE

Link to comment
Share on other sites

Thanks for the explaination. I'll test them. Can you explain how to the NET command syntax? When I do a net /?, it only display a list of switches but provide not explaination or examples how to use it.

In my user.cmd

@ECHO OFF

REM ----------------------------------------------------------------------
ECHO Setting Up User Accounts
ECHO.

ECHO Creating a default user account with no password set
net user "Sky" /add
net localgroup "Administrators" "Sky" /add

PAUSE
Press any keys to continue...

EXIT

When executed, I'm getting this error message but the Sky user is created and seem to work fine even thought I got the above message. To be safe, I wanted to correct it.

The user or group acount specified cannot be found.

The user was successfully created but could not be added to the USERS local group.

-Kenneth

Link to comment
Share on other sites

  • 4 years later...
The SET command takes care of the variables - adds, deletes, modifies and lists 'em. You can do it from the command prompt or in a batch file, there is not really much to it. Type set /? for usage ...

SET VARNAME=VARVALUE ; You have the variable name VARNAME assigned the value VARVALUE

SET VARNAME= ; Variable VARNAME is gone

SET X=%VARNAME% ; X now equals VARVALUE

Whats this part for? I'm not familiar with this.

Link to comment
Share on other sites

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...