Here it is below. Save your script to a .bat file and run accordingly.
Main Topics
Browse All TopicsHey Guys,
I'm sure you guys out there who have used psexec will be able to answer this one fairly easily. I have written up a quick batch that allows me to run a utility remotely on computers over the network one at a time but I was looking to alter it so that the batch file could process a list of computers rather than one at a time. I need to run this utility remotely on approximately 40 computers so you could see the one at a time becoming a tedious process. I know PSEXEC is able to process a list but I can't seem to figure it out on my own and the /? from the command line is pretty confusing.
Again, the batch I have attached works fine, but it only works with the computername listed. I need to figure out how to get it to work pulling from a list instead. Anyone have any experience with this utility?
This Question has been solved and asker verified All Experts Exchange premium technology solutions are available to subscription members.
Experts Exchange has been collecting answers to technology questions since 1996…3 million and counting! If you have a question, chances are we already have your answer.
If you can't find the exact answer you're looking for, ask our exclusive community of 50,000 experts. You’ll get a personalized answer from a trusted professional.
Thousands of free tech tips, tricks, how-to’s and tutorials are available in our peer reviewed articles section. See for yourself how smart our experts are, no login required.
Access the answers to your technology questions today.
30-day free trial. Register in 60 seconds.
Members of the expert community talk about why the experience at Experts Exchange is different than what you will find anywhere else.

Try it out and discover for yourself.
30-day free trial. Register in 60 seconds.
Join the community of experts here and help other tech pros by answering question in your area of expertise. You can earn FREE access to all Experts Exchange's premium features and resources.
Try this:
The "File.exe" will have to be in the same location on your system for the copy to work. Make sure that the folder where psexec is at as well as the location of your file are in the %System Path% and you should have no issues with this.
This example paths to a .csv, but a .txt will work just as well.
@nappy_d:
Hola!
RE: "He has a batch file that he wants run on multiple computers. not a .exe file."
The script I mentioned will do just that.
See,
"psexec @C:\TEMP\list.csv" - This will start psexec and tell it to use this list of devices as opposed to a single device.
" -u MyDomain\Username" This will use the login ID specified, yet prompt for a password. That's more secure than using the "-p PASSWORD" option.
" -c c:\file.exe" - This section copies the file.exe from the local machine to the remote machine so that psexec can use it. Note: It must be in the same path as where you copy it to; ie C:\temp\file.exe to C:\Temp\file.exe or C:\MyBatch.cmd to C:\MyBatch.cmd This can be any kind of file as long as you can run it from a command line with no other pop-ups to click on, etc.
Hope that helps clear things up!
=)
Business Accounts
Answer for Membership
by: DanCh99Posted on 2009-02-16 at 15:54:47ID: 23655167
http://forum.sysinternals. com/forum_ posts.asp? TID=9850