views:

238

answers:

5

I've got a situation where i have one system running a master application that communicates with slave applets on other systems, problem is, i can't guarentee that the slave applets will be running, nor that an operator can physically utilize the system to start the applet (and I'm also assuming they don't know how to use Remote desktop, these are minimum wage test operators)

Is there an easy way to remotely launch an executeable on another system?

security is not a concern here as this is a closed network.

+5  A: 

If you're on the same network and have access credentials (username+password) to the remote computer, then Mark Russinovich's PsExec is just the tool you need.

Piskvor
A: 

here's a 2 step solution

  1. Write a batch file to kick start the application/service in the context
  2. Have the batch file on a shared network path which can be accessed from the machine would like to launch the application/service.

Honestly, I would suggest the PsExec solution by Piskvor. But you can try out this as well ;)

AB Kolan
A: 

You can use the Windows AT command to schedule tasks on a remote machine.

Jason DeFontes
+1  A: 

Any chance of converting the remote applets into Windows services? They can be configured to start when the system starts; to retry if they fail; and to notify someone if there are problems. They're quite trivial to create with Visual Studio.

John Saunders
I'd like to know more about this, please update with more information, I had considered it but do not know about about services.
Firoso
Also could this be easily implemented with WCF in a way that the master sends commands to the services and then subscribes to events/errors/etc.? I've JUST started looking at WCF, I'm more than happy to open a new question related to this to let you respond.
Firoso
See http://msdn.microsoft.com/en-us/library/9k985bc9.aspx. They're quite easy because when you create one, all the infrastructure is in place. Just override the OnStart method.
John Saunders
re WCF, I'm not certain, but I believe you can create WCF service that will start up when a request is received. Such a service can do anything, including run a workflow.
John Saunders
+5  A: 

WMI is your friend. See the following article which covers starting processes locally and remotely using WMI:

How To: (Almost) Everything In WMI via C# Part 2: Processes (CodeProject)

Kev

Kev