run commands at remote servers
Windows Server Forum Index Windows Server
Server discussion on Windows platform.
 
 FAQFAQ   MemberlistMemberlist     RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 
 
Google
 
Web winserverhelp.com
run commands at remote servers

 
Post new topic   Reply to topic    Windows Server Forum Index -> Programming
Author Message
Jrex7
Guest





Posted: Wed Dec 22, 2004 11:47 pm    Post subject: run commands at remote servers Reply with quote

I need to create a script that will run a set of commands at a few remote
servers then reboot the servers.
I will be running the same commands at all the remote servers. All servers
have the same name except for a number designation at the end of the name.
example:
On Server001, run command1 and wait untill the command funishes, then run
command2 and wait until it finishes, then when finished running the two
commands reboot this server. then satart same process on Server002.

Any on writing this script will be appreciated.
Back to top
Gabe - GMail
Guest





Posted: Thu Dec 23, 2004 10:30 pm    Post subject: Re: run commands at remote servers Reply with quote

Have you looked at using Psexec? It runs programs remotely from with the
remote system.

PsExec is documented at:
http://www.sysinternals.com/ntw2k/freeware/psexec.shtml

Gabe
"Jrex7" <Jrex7@discussions.microsoft.com> wrote in message
news:70EFE585-D7F4-4460-80DD-E267EDE3E688@microsoft.com...
Quote:
I need to create a script that will run a set of commands at a few remote
servers then reboot the servers.
I will be running the same commands at all the remote servers. All servers
have the same name except for a number designation at the end of the name.
example:
On Server001, run command1 and wait untill the command funishes, then run
command2 and wait until it finishes, then when finished running the two
commands reboot this server. then satart same process on Server002.

Any on writing this script will be appreciated.
Back to top
Jrex7
Guest





Posted: Fri Dec 24, 2004 1:39 am    Post subject: Re: run commands at remote servers Reply with quote

Thank you Gabe, I will be looking into this utility.
I would still want to know hot to accomplish this using a script.

"Gabe - GMail" wrote:

Quote:
Have you looked at using Psexec? It runs programs remotely from with the
remote system.

PsExec is documented at:
http://www.sysinternals.com/ntw2k/freeware/psexec.shtml

Gabe
"Jrex7" <Jrex7@discussions.microsoft.com> wrote in message
news:70EFE585-D7F4-4460-80DD-E267EDE3E688@microsoft.com...
I need to create a script that will run a set of commands at a few remote
servers then reboot the servers.
I will be running the same commands at all the remote servers. All servers
have the same name except for a number designation at the end of the name.
example:
On Server001, run command1 and wait untill the command funishes, then run
command2 and wait until it finishes, then when finished running the two
commands reboot this server. then satart same process on Server002.

Any on writing this script will be appreciated.



Back to top
Wensi Peng
Guest





Posted: Sun Dec 26, 2004 11:49 am    Post subject: Re: run commands at remote servers Reply with quote

If your computers have WMI installed ( WMI built-in on XP and W2K) try to
create a process on a remote computer, then use SHUTDOWN.exe form RK.
See Listing14.10 in << Windows 2000 Scripting Guide>>.

I am using my scripts to apply patches/hotfixes or gathering information on
800 W2K servers from a single server.

Wensi Peng
"Jrex7" <Jrex7@discussions.microsoft.com> wrote in message
news:C16173CC-4253-47CF-B232-C33B06292289@microsoft.com...
Quote:
Thank you Gabe, I will be looking into this utility.
I would still want to know hot to accomplish this using a script.

"Gabe - GMail" wrote:

Have you looked at using Psexec? It runs programs remotely from with the
remote system.

PsExec is documented at:
http://www.sysinternals.com/ntw2k/freeware/psexec.shtml

Gabe
"Jrex7" <Jrex7@discussions.microsoft.com> wrote in message
news:70EFE585-D7F4-4460-80DD-E267EDE3E688@microsoft.com...
I need to create a script that will run a set of commands at a few
remote
servers then reboot the servers.
I will be running the same commands at all the remote servers. All
servers
have the same name except for a number designation at the end of the
name.
example:
On Server001, run command1 and wait untill the command funishes, then
run
command2 and wait until it finishes, then when finished running the two
commands reboot this server. then satart same process on Server002.

Any on writing this script will be appreciated.



Back to top
 
Post new topic   Reply to topic    Windows Server Forum Index -> Programming All times are GMT
Page 1 of 1

 
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum




New Topics Powered by phpBB