in reply to How do i kill a process on a remote win32 machine

Actually I meant a program or a process. Stopping a service would not have been a problem. I can find the right pid, but how to kill it on a remote machine using only perl and no external software.

Thanks

/cab
  • Comment on Re: How do i kill a process on a remote win32 machine

Replies are listed 'Best First'.
Win32::Process is your mod
by Marza (Vicar) on Apr 02, 2002 at 20:52 UTC

    Sorry, usually when I get a process question, they mean service....

    Take a look at this mod.

    You will have a function

    Win32::Process::KillProcess($pid, $exitcode)

    Terminates any process identified by $pid. $exitcode will be set to the exit code of the process.

    http://aspn.activestate.com/ASPN/Reference/Products/ActivePerl/site/lib/Win32/Process.html