Navigate / search

Using Taskkill to End Tasks (and end Task Manager)

A few days ago I was faced with the issue of Task Manager not responding…so how would I kill tasks…or, how do I kill Task Manager?

Not too many people know about taskkill, the command prompt’s End Task equivalent.

In my particular case I used:

taskkill /f /im Taskmgr.exe

If you are unsure of the Image Name, you can specify a wildcard in the syntax, ex. Task*. The Process ID can also be used. It can be found through Perfmon (Windows 2008) if Task Manager is unresponsive. Go to Start -> Run -> Perfmon.

Below is the full syntax and options available using Taskkill from the Command Prompt.

taskkill [/s Computer] [/u Domain\User [/p Password]]] [/fi FilterName] [/pid ProcessID]|[/im ImageName] [/f][/t]

/s computer

  • Specifies the name or IP address of a remote computer (do not use backslashes). The default is the local computer.

/u domain\user

  • Runs the command with the account permissions of the user specified by User or Domain\User. The default is the permissions of the current logged on user on the computer issuing the command.

/p password

  • Specifies the password of the user account that is specified in the /u parameter.

/fi FilterName

  • Specifies the types of process(es) to include in or exclude from termination. The following are valid filter names, operators, and values.
Name Operators Value
Hostname eq, ne Any valid string.
Status eq, ne RUNNING|NOT RESPONDING
Imagename eq, ne Any valid string.
PID eq, ne, gt, lt, ge, le Any valid positive integer.
Session eq, ne, gt, lt, ge, le Any valid session number.
CPUTime eq, ne, gt, lt, ge, le Valid time in the format of hh:mm:ss. The mm and ss parameters should be between 0 and 59 and hh can be any valid unsigned numeric value.
Memusage eq, ne, gt, lt, ge, le Any valid integer.
Username eq, ne Any valid user name ([Domain\]User).
Services eq, ne Any valid string.
Windowtitle eq, ne Any valid string.

/pid processID

  • Specifies the process ID of the process to be terminated.

/im ImageName

  • Specifies the image name of the process to be terminated. Use the wildcard (*) to specify all image names.

/f

  • Specifies that process(es) be forcefully terminated. This parameter is ignored for remote processes; all remote processes are forcefully terminated.

/t

  • Specifies to terminate all child processes along with the parent process, commonly known as a tree kill.

How to Secure Erase (reset) an Intel Solid State Drive (SSD)

By now many have heard about the performance degredation found in Intel SSDs due to the write/rewrite commands. Although they remain incredibly fast, there are some instances where you may wish to “reset” the drive or at least secure erase the drive for a second sale or install in a different computer or server.

An Intel quote: “An alternative method (faster) is to use a tool to perform a SECURE ERASE command on the drive. This command will release all of the user LBA locations internally in the drive and result in all of the NAND locations being reset to an erased state. This is equivalent to resetting the drive to the factory shipped condition, and will provide the optimum performance.”

The Center for Magnetic Recording Research no longer has HDDErase 3.3 on their website which is needed to secure erase the Intel X18-M, X25-M and X25-E. HDDErase 4.0 is not compatible with the Intel SSDs but should be used for all other hard drives. HDDErase 3.3 is available below:

Download HDDErase 3.3 (Intel SSD Compatible) here.

Included in the zip file are usage instructions. Be sure you can create a DOS 6.22 boot disk (in Windows XP explorer, right click on the “A drive” and select “format” and “create boot disk”). Then include the HDDErase.exe file on the disk.

You must also disable AHCI (SATA Mode) if enabled in your BIOS before you boot into DOS for the utility to run and work properly. Most BIOS will have an option to emulate IDE mode for SATA ports. Be sure to switch it back to AHCI once you are done.

Secure erasing the Intel SSD only takes about a minute.

 

IE8 Showing as Critical Update in XP

Internet Explorer 8 is showing up in Windows XP’s Windows Update as a critical update. Although this may be a good thing for developers (getting a “more” standards compliant browser out there), it can wreak havoc on networks with applications designed for IE6/7.

There is an IE8 Blocker toolkit from Microsoft. Simply download it and install on your network. It will disable the IE8 update through Windows Update.

http://go.microsoft.com/fwlink/?LinkId=133921

Computers and Capital Cost Allowance for Canada

Here’s a bit of info for the Canadian IT sector: In the new budget the Capital Cost Allowance for computer hardware has been temporarily increased to 100% (from 50%). This allows businesses to write-off 100% of the cost of computer hardware purchased between Jan 27th 2009 and Feb 1st 2011.

What does this mean for IT departments? Tough to say – it depends on the performance of the business itself to justify whether there are any tangible savings – there are many businesses that pay little or no tax already.

For those consultants with small businesses on their client list – you may wish to remind them of this development. It may allow them to increase their IT spending.

Read more here:

Canada’s Economic Action Plan – Budget 2009

Using the IE Content Advisor to block all Internet access

This is an old trick that was documented on the Microsoft website for Windows 95 – Windows 2000 but seems to have disappeared since. Here’s a basic retelling of the procedure to block all Internet access and allow only approved sites using the FREE content advisor found in Internet Explorer.

1. Copy the following text into Notepad and save it as “noaccess.rat” in the Windows\system32\ directory (or another directory of your choice). Be sure that the file extension is .rat and not .txt. You can download a zip file containing noaccess.rat here.

((PICS-version 1.0)
(rating-system “http://www.microsoft.com”)
(rating-service “http://www.microsoft.com”)
(name “Noaccess”)
(description “This file will block all sites.”)

(category
(transmit-as “m”)
(name “Yes”)
(label
(name “Level 0: No Setting”)
(description “No Setting”)
(value 0))
(label
(name “Level 1: No Setting”)
(description “No Setting”)
(value 1))))

2. In the “Control Panel” double-click on “Internet Options” and click on the “Content” tab. If in Internet Explorer, click on “Tools” and “Internet Options” and click on the “Content” tab.
3. Click “Enable.”
4. Inside the “General” tab click on “Rating System.”
5. Remove all entries and click “Add.” Add “noaccess.rat” from the Windows\system32\ directory.

6. Click on the “Approved Sites” tab and add all the websites you wish to allow access to.

UPDATE (Dec 14 2009): I have added the noaccess.rat and noaccess.txt files to a zip file that can be downloaded here.