Can't terminate psexec process with either ^C or ^Z

13,250

From another command window or from the "Run" box, you can use PSKill, also from Sysinternals. It is capable of killing a remote process.

Usage: pskill [-t] [\\computer [-u username [-p password]]] <process ID | name>
 -t    Kill the process and its descendants.
 -u    Specifies optional user name for login to
       remote computer.
 -p    Specifies optional password for user name. If you omit this
       you will be prompted to enter a hidden password.

Alternatively, you could RDP (or any similar method) to the remote machine and kill the task from the task manager.

Once the process is terminated, the command window should return to the prompt.

Share:
13,250
daisy
Author by

daisy

Updated on September 18, 2022

Comments

  • daisy
    daisy over 1 year

    I couldn't terminate a remote process started through psexec, I've tried ^C and ^Z, but that doesn't kill the process.

    enter image description here

    What other choice do I have, other than closing the cmd window?