Sunday, May 01, 2005
taskkill.exe
I was looking for a way to kill running tasks in from the command line in XP, and i came across info about taskkill.exe
This does the trick but ain't available with XP Home. It will work with XP Home however, so you can download it here. It's in the ZIP file:
taskkill.zip
(It was recently pointed out to me that the version above is a German version! So here's the English version: taskkill_en.zip)
If you want instructions, here is Microsoft's documentation: M$ taskkill.exe documentation
And here is some help and examples from computerhope: Computerhope taskkill.exe help
This does the trick but ain't available with XP Home. It will work with XP Home however, so you can download it here. It's in the ZIP file:
taskkill.zip
(It was recently pointed out to me that the version above is a German version! So here's the English version: taskkill_en.zip)
If you want instructions, here is Microsoft's documentation: M$ taskkill.exe documentation
And here is some help and examples from computerhope: Computerhope taskkill.exe help
Comments:
Links to this post:
<< Home
I guess because it originally came from a German version of XP!
I'll see if I can swap it for an English version :)
I'll see if I can swap it for an English version :)
How do I get it to run through a batch file. I need to kill processes on a lot of computers, and i don't want to type each computer name into the command line. I'd rather do it once and just run it as a batch and as a scheduled task every day at 9AM.
Jeff,
See my links above for the taskkill.exe syntax and some examples. You have to know a bit about writing atch files yourself because it's not my strong point ;)
I tried executing taskkill using a wildcard ('*') character in the computer name or IP address (when using the /s switch) but it didn't work.
So all I can suggest is writing your batch file like this:
c:\taskkill /s {computer_name_1} {parameters}
c:\taskkill /s {computer_name_2} {parameters}
c:\taskkill /s {computer_name_3} {parameters}
So you hard code the computer names in the batch file. If the names are always the same, then at least you'll only have to do this once.
If you don't know the names, but do know the IP addresses, use those instead.
If you're dealing with a lot of IP addresses, find a friend to write you a batch file which loops thru all the IP addresses. I can't write batch file code off the top of my head, but here's the pseudocode:
Where x=1 until 254
Do c:\taskkill /s 192.168.1.x {parameters}
Regards,
Josh
See my links above for the taskkill.exe syntax and some examples. You have to know a bit about writing atch files yourself because it's not my strong point ;)
I tried executing taskkill using a wildcard ('*') character in the computer name or IP address (when using the /s switch) but it didn't work.
So all I can suggest is writing your batch file like this:
c:\taskkill /s {computer_name_1} {parameters}
c:\taskkill /s {computer_name_2} {parameters}
c:\taskkill /s {computer_name_3} {parameters}
So you hard code the computer names in the batch file. If the names are always the same, then at least you'll only have to do this once.
If you don't know the names, but do know the IP addresses, use those instead.
If you're dealing with a lot of IP addresses, find a friend to write you a batch file which loops thru all the IP addresses. I can't write batch file code off the top of my head, but here's the pseudocode:
Where x=1 until 254
Do c:\taskkill /s 192.168.1.x {parameters}
Regards,
Josh
for taskkill you dont have to specify and computer name etc, just whether it is an image or not then the .exe extension. just thought that might help if you havent already solved this
Post a Comment
Links to this post:
<< Home