Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

running bat file from another pc

Status
Not open for further replies.

jakess

Technical User
Apr 17, 2000
418
ZA
I want to run a bat file which is place on a server from my pc Win2000 and NT4. It must run on the server and not on my pc. how do i create such a shortcut on my pc?
 
The Windows 2000 resource kit includes rcmdsvc.exe and rcmd.exe for performing remote commands and rconsole for opening a remote console. One of these should do what you are looking for. Kevin Mattson
MCP
 
Thanks...but how do i get it working with NT4
 
can anyone please respond to my NT question....i need to run a bat file from a diffrent pc on our LAN but want the file to run on the server
 
And you probably want to do this for free...

WinVNC is as close as you will get, lucky for you it is pretty good.
But it won't do what you want. You stated that you want to start a batch file on this PC and have the CPU of another computer finish the program. That is a tall order for us mere mortals. The holy grail of hackerdom this is.

It would be far easier and cheaper to change what you want.
Tao is the mobius. The ribbon of heaven and earth, you cannot lose your way.
 
my apologies.. i didn't explain myself very clear
I know VNC but i'm sure there must be another way.
ok here is the problem again...i have a bat file which is placed on the server and i want a user to run the file from his\her pc using NT4 and Win2000. Basically want a shortcut on their desktop but it must run on the server.
 
I got ya, but there still needs to be some mechanism on the server that executes the batch file in the context of that server, e.g., remotely.

So you need something like a web server with ASP that will host a function to call the batch file in the context of the server. So you could write a ASP page with VBScript that performs the same action.

Generally speaking, to do this you need some server process and IIS 4.0 will do, if this is loaded on the server. Or, if the Windows Scripting Host is loaded on the server, that presents another opportunity. However, this seems a bit unlikely in both cases due to security issues, but only you know this for certain. Let us know.

Regards,

Mike Tao is the mobius. The ribbon of heaven and earth, you cannot lose your way.
 
Set up RCMD on the server. Place a bat file on the users desktop with this line. As stated above, rcmd is a resource kit utility. Follow these steps to create rcmd on the server. sc.exe is another resource kit utility.
copy rcmdsvc.exe \\myserver\myshared\winnt
sc \\myserver create "remote command" binpath= c:\winnt\rcmdsvc.exe

rcmd \\servername path to batch file on server
ex:)
rcmd \\myserver d:\winnt\system32\cmd.exe
place rcmd.exe in the workstations %WINDIR%\system32
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top