10/23/2009 12346 views
I am trying to use the SysInternals tool Psexec to execute a command on some remote servers. We need to run gpupdate /force on a few servers.

I have tried the following.

psexec \\server01 gpupdate /force

psexec @MyFile.txt gpupdate /force (where MyFile.txt has a list of the servers we need to update)

And both give back the same error:


Refreshing Policy...

Failed to refresh User Policy. Error - The system cannot find the file specified
. Exiting...
Computer Policy Refresh has completed.

To check for errors in policy processing, review the event log.
gpupdate exited on server1 with error code 0.

Not sure why this is failing.....
0 Comments   [ + ] Show comments


Rating comments in this legacy AppDeploy message board thread won't reorder them,
so that the conversation will remain readable.

All Answers

My guess is that the account you're using to run PSExec isn't valid on the target. You have a couple of choices:

- Run PSExec as either the System account using the '-s' argument or specify valid credentials in the command line, using the -u <username> and -p <password> arguments. Bear in mind that the password will be passed across the network in plain text.

- Specify that the update is to Computer policy only by using GPUPDATE's '/TARGET' argument, as in 'GPUPDATE /FORCE /TARGET:COMPUTER'
Answered 10/24/2009 by: VBScab
Red Belt