Tuesday, March 21, 2006
Taskkill and Pskill
A very useful utility included with Windows XP and 2003 that a lot of folks may not be familiar with is Taskkill. This is installed in %WINDIR%\SYSTEM32\taskkill.exe. Here's some examples:
TASKKILL /S system /F /IM notepad.exe /T
TASKKILL /PID 1230 /PID 1241 /PID 1253 /T
TASKKILL /F /IM notepad.exe /IM mspaint.exe
TASKKILL /F /FI "PID ge 1000" /FI "WINDOWTITLE ne untitle*"
TASKKILL /F /FI "USERNAME eq NT AUTHORITY\SYSTEM" /IM notepad.exe
TASKKILL /S system /U domain\username /FI "USERNAME ne NT*" /IM *
If you're running Windows 2000, I like PSKILL as an alternative.