RE: a .bat file to execute something into a different server
- From: Anteaus <Anteaus@xxxxxxxxxxxxxxxxxxxxxxxxx>
- Date: Fri, 31 Jul 2009 03:15:01 -0700
net start >running.txt
if executed on the server, will create a file listing the running services.
You could schedule this to run at suitable intervals, and deposit its output
into a visible share, such as Q:
A slightly more sohisticated method would be to use AutoIt's ProcessExists()
fucntiion to poll the required services and produce a report.
It is in fact possible to launch a process on a remote computer, see
http://technet.microsoft.com/en-us/sysinternals/bb897553.aspx
but this requires Domain Admin or server local-admin credentials to be
stored on the local computer, and thus exposes the server to all sorts of
security issues. In principle I don't recommend doing this kind of thing.
"HuanManwe" wrote:
.
Hello,
what I want to do is:
1.- Use a .bat file to get into a Win2003 Server (already done)
2.- Execute there "start services.msc" (I can only make it work
locally)
The idea was to see if certain services were started or not. For
example the IIS Server. But at least I needed to execute something
there.
This is what I've done until now.:
Code:
--------------------
@echo off
net use Q: \\servername domainname /user:serverIP\adminname password /PERSISTENT:NO
pause
echo We're in but now I try and execute services.msc:
START C:\WINDOWS\system32\services.msc
goto end
:end
echo End of process
--------------------
Can you help me?
Thank you all in advance.
--
HuanManwe
- References:
- a .bat file to execute something into a different server
- From: HuanManwe
- a .bat file to execute something into a different server
- Prev by Date: a .bat file to execute something into a different server
- Next by Date: Re: a .bat file to execute something into a different server
- Previous by thread: a .bat file to execute something into a different server
- Next by thread: Re: a .bat file to execute something into a different server
- Index(es):
Relevant Pages
|