Re: Script to install windows Service Pack 4
From: Torgeir Bakken (MVP) (Torgeir.Bakken-spam_at_hydro.com)
Date: 03/01/04
- Next message: Martin Vliem: "Re: ADSI - VBscript - Changepassword method - BUG?"
- Previous message: Jehos: "NTFS Security in WMI - Need Help"
- Messages sorted by: [ date ] [ thread ]
Date: Mon, 01 Mar 2004 03:12:53 +0100
JerryWoodstock wrote:
> I am new to scripting so please bare with me i am triying
> to install service pack 4 for windows 200o to the
> machines on our lan. How should i go about this? I realize
> there are better ways to do this through SMS SUS or Group
> Policies in AD but we do not have any of these set up .
You could consider to implement the free Microsoft Software Update
Services (SUS) to push service packs and security upgrades. It works
without having AD, and the users don't need to be local admins either.
More information and links to SUS resources in this post:
http://groups.google.com/groups?selm=403623CA.55E8FCBE@hydro.com
> So we have to do it throught the log on script i have this
> so far
> - Copy Service Pack 4 with File System Object From Network
> Share to Users Computer.
Actually, I would advice against copying the SP4 file (w2ksp4_en.exe) to
the local computer. You should just run the file from the network share,
it will extract itself to the local disk anyway and install from there
(even if you put w2ksp4_en.exe on the local disk, it will extract itself
anyway) . Copying the file locally first will just cost you more install
time (and minimum required free disk space would be increased with 130 MB
as well).
> - Run Service Pack With Approproiate Switches with
> Shell.exec command.
I suggest you take a look at the post in the link below, it installs
SP4 on Win2k and SP1 on WinXP, with a progress bar (the one provided
by the service pack itself). If the users press Cancel in the first
part of the SP install where the Cancel button is available (during
the detection phase), the script will put up a message box saying
"You are not supposed to press cancel, installation will run again",
and then it will start the installation again.
http://groups.google.com/groups?threadm=3F8208C6.FBCEECB1%40hydro.com
Some notes on the code in the link above:
The first If test (If sOStype = "WinNT" Then) will make the service
pack install on only workstations and not servers (remove the test if
it doesn't apply to your environment).
The script is using the functions GetOsVersionNumber and GetSPNumber
without including the code, they are available here (as well as the
sub "ShutDown"):
http://groups.google.com/groups?selm=3EB70B7E.12C8CE54%40hydro.com
> Problems i am having trouble finding Solutions for
> -Users Cannot install Software on machines only Admins
> Have These Privilages SO How Do i Make USeres Have Admin
> Permissons for a limited time or/and how do i log off and
> log in as Local Admin?
Some Runas wrapper utilities or alternatives that might help you:
http://groups.google.com/groups?selm=3FE0B42C.773CA875%40hydro.com
But I would strongly recommend you to look into the MS SUS product
to avoid this issue.
> - How Can i shut Mcafee Virus Scanner off with VB Script?
I have no idea, but we install service packs with Norton/Symantec
Corporate Edition antivirus running without any problems.
> - IS there an Easy Way to Prevent USers From Using
> Keyboard while Software is installing ie. not CTRL+ALT+Del
> midway through?
No.
> - How can i display a progress bar so users know where in
> the Instalation we are?
If using the progress bar that comes builtin with the service pack
install isn't good enough, you can e.g. use the Internet Explorer
object to create one.
Some nice progress bar examples by Joe Earnest:
http://groups.google.com/groups?selm=%23BDv%24av%24DHA.1288%40TK2MSFTNGP10.phx.gbl
Some without a progress bar but where you can dynamically put out
information about what is going on :
http://groups.google.com/groups?selm=3EA302E5.5BAE90EB%40hydro.com
-- torgeir Microsoft MVP Scripting and WMI, Porsgrunn Norway Administration scripting examples and an ONLINE version of the 1328 page Scripting Guide: http://www.microsoft.com/technet/scriptcenter
- Next message: Martin Vliem: "Re: ADSI - VBscript - Changepassword method - BUG?"
- Previous message: Jehos: "NTFS Security in WMI - Need Help"
- Messages sorted by: [ date ] [ thread ]