Muokkaa

Jaa


Kill Tool

The Kill tool, kill.exe, terminates one or more processes and all of their threads. This tool works only on processes running on the local computer.

Where to get Kill Tool

Kill.exe is included in Debugging Tools for Windows.

Kill Tool command-line options

kill [/f] { PID | Pattern* }

Parameters

/f Forces the termination of the process without prompting the user for confirmation. This option is required to terminate a protected process, such as a system service.

PID Specifies the process identifier (PID) of the task to be terminated.

To find the PID for a task, use TaskList in Microsoft Windows XP and later or TList in Windows 2000.

Pattern*
Specifies all or part of the name of a task or window. The Kill tool terminates all processes whose process names or window names match the pattern. The asterisk is required.

Before using a pattern that might match many process or window names unintentionally, use the tlist pattern command to test the pattern. See TList for details.

Examples

The following command terminates processes whose names begin with "myapp."

kill myapp*

The following command terminates the process whose process ID (PID) is 2520:

kill 2520

The following command terminates processes whose names begin with "my*." It does not prompt for confirmation. This command succeeds even when this process is a system service:

kill /f my*

See also

Tools Included in Debugging Tools for Windows