Run command on every windows workstation

0

I just found out that I need to add a persistent static route to each and every workstation on my network of 80 Windows XP & Windows 7 Workstations. How do I add a persistent route to every workstation at once on a windows network (without having to RDC into each and every workstation)?

Example: route add -p

I know how to execute the command, just need to do it in bulk.

TheFrack

Posted 2014-06-26T19:43:11.163

Reputation: 279

1In order to help you, we need to know more about the situation. Are the PC's in a domain? Do they connect to the same network? That kind of info. In case of a domain, the domain controller can provide a logon script and you can simply add it there. If not, it is going to be harder. – LPChip – 2014-06-26T19:49:30.397

look into WMI scripting. you can run a command on every PC in a domain if you set it up right. – Frank Thomas – 2014-06-26T19:50:56.143

Yes, of course they are in a domain. And yes, as I stated, they are on the same network. – TheFrack – 2014-06-27T12:40:38.843

Answers

3

Assuming you have admin rights on the stations and have the relevant ports open and the relevant services configured properly you can use one of this options:

  1. Using GPO to deploy a script that add that route. That, of course, will apply only after rebooting.
  2. Using WinRM and Powershell you can run this commands remotely. That option require to configure this on every station, either with GPO or manually. Also, you'll need port 5985 open.
  3. Using Sysinternals' PsExec you can run this commands remotely. That option, usually, doesn't require any prior configuration. Also, you'll need port 389 open (which should be open if you're in a domain).

I think that option 1 is the easiest in your situation, but the two other options might help you more in the future.

EliadTech

Posted 2014-06-26T19:43:11.163

Reputation: 2 076