Link to home
Start Free TrialLog in
Avatar of azstbzimms
azstbzimms

asked on

Remotely Run a Group Policy Update

Looking for a VBscript that will refresh group policy on a remote computer.  (the equivalent of running gpupdate /force from the command line of a local machine).  I'd like to launch the script from my WinXP machine, have it ask me for a computer name, and then refresh the group policy on the target machine.  This is in a W2K3 environment.
Thanks!
ASKER CERTIFIED SOLUTION
Avatar of Rob Williams
Rob Williams
Flag of Canada image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
By the way if you want to apply it to a series of computers you can use a text file list of computers and include that in the command rather than one specific PC. See the syntax in the link above.

Also because gpupdate often returns a response asking if you want to log off now, to deal with that you may want to use the  /logoff or /boot switches with the gpupdate command.
http://technet2.microsoft.com/windowsserver/en/library/6880fef3-76b7-4eb3-b993-fa00799615851033.mspx?mfr=true
Avatar of j0rdan
j0rdan

If your PC has the 2k3 AdminPak, I would *highly* recommend SpecOps GPUpdate add-in for the AD snap-in.

http://www.specopssoft.com/products/specopsgpupdate/

It integrates into the snap-in and will let you run multiple commands to any computer on the domain (including gpupdate, reboot, etc).
Thanks azstbzimms.
Cheers !
--Rob