Re: Get command line of a running process (local/remotely)?

Tech-Archive recommends: Repair Windows Errors & Optimize Windows Performance



Joseph M. Newcomer wrote:
But that is the default command line used when SCM is instructed to start the service. You
can call the StartService API and specify a different command line. The Registry entry is
only used if you do a "Start" from the Services snap-in or have an auto-start service.
joe


Those services are our services, but I don't want to change any of their code, (to write to a DB/log a message and so on), as that would mean a full test cycle.
In any case, they do log the information I need but getting that data remotely might be just as hard.

I know the name of the services and they do start with the server, (they are autostart services).

Granted, it is possible that IT could write an app to launch the service using StartService(...) or something similar but I think that would be an overkill for what I want to do.
And there is no real financial incentive for them to do that anyway.

Yes in an ideal world I would ask the service what the true/real command line is but I might only be able to add this in future releases of our services. For now, a query to the registry might be more cost effective if not the 'best' approach.

Regards,

Simon
.



Relevant Pages