Brad Wardell's views about technology, politics, religion, world affairs, and all sorts of politically incorrect topics.
Using the task manager to make Windows XP perform better
Published on October 22, 2003 By Draginol In Personal Computing

My work machine stays up for weeks and often months at a time. In fact, the only time it gets rebooted is when our office loses power (which is too frequently, yea I should get a UPS).

People are often shocked at this. How do I keep my system running for so long, especially given how hard I push it day in and day out while running all the major components of Object Desktop? On Windows XP, it's actually pretty easy -- once you know what affects stability.

It all starts with the task manager.  To get to that, hit CTRL-SHIFT-ESC. When you do that, the task manager in Windows XP will come up.

Whenever you have a problem with your system, whether it be acting slow or saying it's out of memory or just acting weird, you'll want to pull up the task manager.

Once you do that, go to the Performance tab.  Check and see how much RAM is in use.  A lot of young techies get obsessed with the amount of memory committed. Don't.  Check to see if your CPU meter is pegged too high, check to make sure you're not using a ridiculous amount of memory (I have 1 gig installed so 419MB in use is no biggie).  But most importantly: Check the handles in use.  This is what slows down your system.

The # of handles in use should never grow much beyond 12,000.  When you get to 15,000 handles, weird things can start to happen and you'll feel your system slow down. This is where most people just reboot. They'll throw up their hands and say "Well, time to reboot." But that's unnecessary because the task manager can tell you what program(s) are using up those handles.

So now click on the processes.  You'll want to go to View->Select Columns and choose the items that are chosen here.  You want to know things like the handle count, the GDI objects, and the User Objects.  If any of those numbers are >2,000 on a given item, that item is doing something bad.

Once you have that set up. Look at the column headers. Sort by the ones I've highlighted in yellow first. Is something using up most of your CPU? Then kill it if it's not supposed to. Is something using more than 2000 handles? If so, you should probably kill that too. Same for User Objects and GDI Objects.

And then finally, sort by memory usage and then VM size. Don't worry too much about those numbers unless you're running low on RAM. The VM Size column isn't terribly useful anyway because it double counts libraries being loaded (i.e. a program that needs to read .PNG files will load a library that uses that but another one that uses the same library will get that counted too. Mem Usage is the one to keep an eye on.  But again, even there, don't sweat that number too much unless it's using a signficant percentage of your installed memory.  Internet Explorer is using 21 megs of RAM. Sounds like a lot right? But that's only 2% of my installed memory.  Back in the old DOS days of 640K 2% would be just over 12K of memory.

CPU, Handles, GDI Objects, User Objects, these are the things to keep an eye on. If you kill processes that are using up an unusual amount of these resources, you can keep your system up indefinitely.

 


Comments (Page 3)
4 Pages1 2 3 4 
on Jul 27, 2006
My computer uses 302,218(that's big) handles and it still stays running for days without rebooting.
on Jul 28, 2006
Hey guys, can anybody tell me what the "SVCHOST.EXE" process is all about? It uses almost 2,000 handles and it has "sub-friends"!

http://www.google.com/search?q=svchost.exe
on Aug 08, 2006
Tarkus, thanks for the link. Been fretting about just that very thing. Now have more tools and knowledge re:SVCHOST.EXE issues Draginol, thanks for the thread, too!
on Aug 30, 2006
First of all Thanks for all this info.

on my System when I started reading this and all the comments it was 2,800 NOW as I started typing it is at 3,018 for the handles for CPU , User Objects and GDI Objects are all at 0 (zero)
Memory Usage 240k, VM size 28k...
Now for my question. If I end the process of the System will it stop everything to where I will have to reboot. And how do I restart the system with out rebooting...

But this is just the tip of my problems that I have.
Please help if you can Thanks.

One day my computer runs grate another day it is slow ok, ok its slow everyday just some days its worse.
It will freeze opening a window or program I will go to TM (task Manager) and it dose not like to end process.

And most days when I Boot (start) my computer this one (svchost.exe) takes ALL memory well 97% there is 7 of them running but just one that dose it for about 5 to 6 minutes, if I don’t stop it .
Here is some info on my computer that mite help.

System:
Microsoft Windows XP Professional Version 2002 Service Pack 2
Computer:
Intel® Pentium® 4 CPU 1600MHz 1.59 GHz, 1.00 GB of RAM
Graphics card:
Nvidia GeForce FX 5200 128MB
On a Crappie Hewlett-Packard HP Pavilion xt948
Other then it being an HP this should be a good fast computer
Now for the Security: I have and use

Advanced Registry Optimizer 1.2.8
Avast! Antivirus Professional 4.7 build: Aug2006 (4.7.871) Xtreme Toolkit 1.9.4.0
CleanUp! 4.5.2
eTrust EZ Firewall 5.1.039.004 I have the rest of the suit just do not use
Lavasoft Ad-Aware SE Professional builds 1.05. Have Ad-Watch SE Professional do not use
MSConfig CleanUp 1.0
Spy Sweeper 2.2.0.44
XoftSpy 4.22

Just these start on start up:
Avast! Antivirus Professional 4.7
eTrust EZ Firewall

If I move any window around it makes a ghost as I move it as though my G card is not good enough for all the graphics but have NO problem with Games... I have an old driver for my G card 6.1.7.7 but the newer one dose not works as well (8.9.??)

Oh and my CPU clocks out at 100% a lot

Please, Please Help me
on Aug 30, 2006
P.S
and I had to re-install window more the ten times and it lookd like i will have to do it again
this is my first computer i got it 11/11/2001 even sent it back to HP to have it fixed when it was under waranty but all i seen that they did was take off the stickers that they put on it when it was made.. Made me mad that they did that to .

oh and i have upgrated my hard drive from 80GB to 160GB plus Have an 80GB hard drive
C:/ is 160GB Master F:/ is 80GB Slave ( storeage of all the stuff to reinstall with pix , music and download to


Took out C:/ 80GB to replace it with the 160GB why because so tech guy from a computer place told me that it sounds like my hard drive was BAD that is why it was always crashing .. But I found out that it was not true do to it still dose it
and i unpluged F:/ and pluged in the one that came with the computer and reformatted it and it work good well same as it did . so now i have a back up for a back up they just wanted my money but fooled them Best Buy got it $75.00 for 160GB hard drive grate price beings an 80GB was $99.00 plus
on Aug 30, 2006
Gawd. Or just disable process that are useless for 99% of the people, even power users such as myself. On system boot I only have 22 processes running, and that includes Windowblinds, two instances of Sysmetrix and Trillian. Nice an lite!
on Aug 31, 2006


e help


on Oct 23, 2006
Here's a free handy tool for personal use that can be used to tell you what those processes are and whether it's safe to shut it down etc,if link fails goolge for uniblue processlibrary

http://www.processlibrary.com/freetools/
look for "processlibrary.com Quick Access" should be at top and clik on download



EDIT:forgot to mention don't panic it requires internet access to display web page explanation of what the particular process is
on Dec 16, 2006
Wow just found this, hope someone is still reading this. it's a Great Article, like alot of people, though I use the task manager I didn't think about using the other columns. My biggest question is what's up with the svchost.exe... when XP first came out I would only have about 2 processes running now I have 7 running; 2 in network service and 1 on local service and the rest in system. I just reinstalled my OS, so i know it's anything that's shouldn't be there I guess. On top of all that svchost uses about 1500 handles (that normal?)
on Jan 08, 2007
Thank you for this informative article. What is funny is I DO use my Task Manager to check on the System, but I really didn't understand what I was doing. But Now I am learning. Thanks
on Mar 15, 2007
This was a very important find for me, and wanted to thank you for the excellent tip of watching handles. I am involved with developing scores of integrated systems for a specialized application. Several of my customer's systems will run only 3 to 5 days before requiring rebooting. I had attributed the problem to my software, because my software is always the major package running on the system when the system starts producing severe errors. However, after reading your article, there appears to be another culprit.

Discovery: A single program sold with the Netgear USB wireless adaptor that we use on many of our systems (RtlWake.exe) continually racks up handles until the system runs out of resources. The problem is less pronounced on Windows 2000. On one Win2000 system that had been running for a week, the handle count for this software was at about 300,000 and climbing.

SYMPTOMS in WINDOWS 2000:The errors reported on Windows 2000 is: ERROR_RESOURCE_TYPE_NOT_FOUND (Error 1813). When this error occurs, then Windows is completely unable to print the Start menu, and will not allow a regular shutdown (it believes that you don't have enough permission to shutdown).

SYMPTOMS in WINDOWS XP: The handle count issue is MUCH worse in XP (compared to Win2000) as the count grows much faster. No error messages are reported in our Windows XP systems. The key event is that Windows has trouble repainting controls on the screen. Then the whole system freezes quickly after the paint problems.

For several weeks, we have been watching Available Memory only. Memory was dropping consistently at about 4 megabytes an hour in XP systems. I suspected that a serious memory leak existed in my software. However, according Task Manager Processes menu, our software does not leak memory. Also, the symptoms described above occurred when there was still 25 GB of memory remaining in one test system. So examining the Handle Count was a real break-through. I now conclude that Available Memory dropped only as one symptom of the huge accumulating Handle Count.

Thank you very much for this helpful article. You've saved me and my colleagues a great deal of trouble!


on Jan 26, 2009
Thanks for the info!
on Jan 26, 2009

Thank you sacol95 for making this hit the 'recent activity' list or I might never have seen it.

My XP desktop seldom gives me enough trouble to require a reboot, but it happens with a degree of regularity.  I just took a peek at TM & lo & behold: Symantec's wfxctrl32.exe (WinFax Pro) was sitting at 1.6 million (that's right, million) handles & climbing at a steady 2 handle per second clip.  I leave this running in my SysTray as my 'always on' incoming fax receiver.  Maybe not anymore.  After reading Brad's original post, it's a miracle the rig hasn't choked to death already.  Too bad, WinFax Pro is a pretty good app otherwise, though I have enough history with Symantec products that I'm not at all surprised.

on Jan 26, 2009

excellent...i wonder if this is pretty much the same on vista...there are a few different column names in vista task manager  but i wonder if its basically the same idea?....excellent post

on Jan 27, 2009

jojo25
excellent...i wonder if this is pretty much the same on vista...there are a few different column names in vista task manager  but i wonder if its basically the same idea?....excellent post

I think it should be somewhat the same in vista however i think there are more handles in vista, I run my vista 32 24/7, with on average 18k to 21k handles, mainly I run folding@home program which takes up 50% cpu but i can still run games on lower graphic levels quite fine, not sure how tell which process tke up how many handles.

4 Pages1 2 3 4