Problem solve Get help with specific problems with your technologies, process and projects.

Taskkill Terminates Hung Processes

Thanks to Sergey Tkachenko at I just learned about a handy Windows command I’d never heard of before. It’s called Taskkill (or Taskkill.exe, if you prefer). Because Taskkill terminates hung processes in Windows it lives up to its name quite nicely. Better yet, it works with condition tests called filters. Thus you can use it to kill tasks whose names or process IDs you don’t even know.

An Example of how Taskkill Terminates Hung Processes Might Help

This sounds great in the abstract, but what does the syntax look like? Here’s a command line that kills all tasks in Windows with a status of “NOT RESPONDING” that shows the power of this command:

taskkill.exe /F /FI "status eq NOT RESPONDING"

Taskkill Terminates Hung Processes

Taskkill terminates any and all hung Windows processes quickly and easily.

Let me explain the attributes and values included to help make more sense of what’s going on here:

/F: means to force termination of the process that meets the filter condition
/FI: applied any of a number of filters as specified in the text attribute following surrounded by quotes

The text attribute “status eq NOT RESPONDING” tells the command to identify all running tasks that show the “NOT RESPONDING” (that is, “hung”) status in Task Manager. Thus, this command translates into terminate all tasks that are hung. Pretty handy, eh? I only learned about it an hour ago, and I’ve already been able to put it to good use.

Complete Taskkill Details

As always, TechNet is your go-to resource to get the details on Windows commands. The complete syntax for Taskkill is available in the … wait for it … Windows XP Command Line Reference. Apparently, this has been around for a while without yours truly being aware of it. Should you be in the same boat, or otherwise, the Taskkill reference should come in handy either way. Be sure to check it out, and remember to use it the next time one of your browser windows or some other app goes astray. It beats killing all the processes related to a multi-tabbed application and then having to start over, that’s for sure!

Start the conversation

Send me notifications when other members comment.

By submitting you agree to receive email from TechTarget and its partners. If you reside outside of the United States, you consent to having your personal data transferred to and processed in the United States. Privacy

Please create a username to comment.