Jump to content

installing hotfixes from a cmd file


Recommended Posts

I am looking for way to install all of the 30 critical updates from say a cmd bat file or something like this, but first let me explain i have a toshiba laptop, and only have a restore cd, so its not possible to make a new installation cd.

So what i am looking to do its to create a cmd file to install the updates and then force as re-boot.

Does someone have anything like this, as all i can find is installtion cmd files for installing software and drivers.

I would be very greatfull if someone had a sample so i could also copy???

cheers :blushing:

Link to comment
Share on other sites


Hey,

I don't have a specific answer about installing all the hotfixes from a batch file, but I'd like to encourage you to take a look at that recovery CD and see if you could copy and customize it. It's probably just a normal windows install with a $OEM$ directory for the stuff toshiba added. You could probable add stuff right in their.

Most of the hotfixes I slipstream right into the windows installation using the /intergrate option of the hotfix (for the newer ones that support it)

You can check out unattended.msfn.org for some help on how to put all the updates into the windows cd you create. It's actually not so hard. I found it was worth the time to read those documents and cruise the forums for help and advice. The people who stop by here are very cool and help out a lot.

I'm guessing you could build a batch file of the hotfixes and install them all at once using the /quiet option, but you might have trouble with the order of the hotfixes. Some only work after others have been put in place.

good luck!

Link to comment
Share on other sites

you can find the switches for hotfixes by typing hotfix.exe /?

at a command prompt, where hotfix is the name of the hotfix.

I rename all mine to KB######.exe I think most of them would be

hotfix.exe /passive or /quiet /norestart and if you want to reboot

at the end use shutdown.exe -r -t 30 which gives a count down of 30

seconds. Also have you checked out the stick post 'HOTFIXES'

Link to comment
Share on other sites

  • 3 weeks later...

Hi first post.

You might try this site Updating XP SP2 and 2003 SP1 Without using Windows Update

ive used it to add the HotFixes in runonceex

his setup.cmd for win2k3

@Echo off
rem ////////////////////////////////////////////////////////////////////////////
rem // Setup.bat
rem // This Batch file runs the hotfixes for Windows 2003 SP1
rem // If the hotfix is already installed (checked by looking for reg key)
rem // then the installation is skipped.
rem ////////////////////////////////////////////////////////////////////////////

set Flags=/passive /norestart /nobackup

if "%~1" == "-p"  goto Process

rem ////////////////////////////////////////////////////////////////////////////

set RegKey=HKLM\Software\Microsoft\Updates\Windows Server 2003\SP2

rem ////////////////////////////////////////////////////////////////////////////
rem // Main routine
rem // %1 contains Options
rem //

color 17
title Windows Server 2003 SP1 - 13 Hotfixes

echo ::: Installing Updates :::
echo.

call %0 -p KB896422 "WindowsServer2003-KB896422-x86-enu.exe"
call %0 -p KB896358 "WindowsServer2003-KB896358-x86-enu.exe"
call %0 -p KB890046 "WindowsServer2003-KB890046-x86-enu.exe"
call %0 -p KB896428 "WindowsServer2003-KB896428-x86-enu.exe"
call %0 -p KB883939 "WindowsServer2003-KB883939-x86-enu.exe"
call %0 -p KB898792 "WindowsServer2003-KB898792-v2-x86-enu.exe"
call %0 -p KB903235 "WindowsServer2003-KB903235-x86-ENU.exe"
call %0 -p KB901214 "WindowsServer2003-KB901214-x86-ENU.exe"
call %0 -p KB893756 "WindowsServer2003-KB893756-x86-ENU.exe"
call %0 -p KB899591 "WindowsServer2003-KB899591-x86-ENU.exe"
call %0 -p KB899587 "WindowsServer2003-KB899587-x86-ENU.exe"
call %0 -p KB896727 "WindowsServer2003-KB896727-x86-ENU.exe"
call %0 -p KB899588 "WindowsServer2003-KB899588-x86-ENU.exe"

echo.
echo ::: Done :::

echo.
pause

goto END

rem ////////////////////////////////////////////////////////////////////////////
rem ////////////////////////////////////////////////////////////////////////////
:Process
rem //
rem // %2 will contain the KB number
rem // %3 will contain the Exe file name
rem // %4 will contain any options passed originaly
rem //

rem //
rem // See if the Reg key exists, this indicates whether patch has already
rem // been installed
rem //
reg query "%RegKey%\%2" > nul 2>&1
if errorlevel 1 goto NeedToInstall

echo %2 - Already Installed. Skipping.
goto EndProcess

:NeedToInstall
echo %2 - Installing
%3 %Flags%

goto EndProcess

:EndProcess
goto END

rem ////////////////////////////////////////////////////////////////////////////

:END

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...