run a chkdsk under 2008r2 (or regular 2008, or w7), use all your memory

I run chkdsk.exe pretty often on my machines, mainly because I’m paranoid about data integrity since I have a lot of data spread across many hard drives. On my server I was trying to run chkdsk.exe on a couple of drives at once, thinking I could save myself some time.


When the machine slowed down to a crawl, I started by looking at the disk utilization to see what was going on. It was expected that this would slow down the machine, but these are non system disks, physically separate from anything that should directly impact system performance. After killing two of the three chkdsk’s, I was left with the one on the “J” drive, so I decided to check disk performance with the performance monitor.


Here you can see that aside from the chkdsk itself, there is some pretty significant writing taking place to the pagefile located on my “G” drive… Which shouldn’t take place since this machine has 8gb of ram and with no virtual machines running, never uses more than 1 gig. (No vm’s are running during all of this.) Of course, hitting the pagefile so much implies that the server is running out of memory, so let’s go see what the memory tab looks like.


Here you can see that there is 0 free memory (as in zero)! Then you can look at the processes and see that chkdsk.exe is using 7.0 gigs of memory! What? This must be a bug.. a leak.. right? Something must be wrong. Well, guess what? Apparently this is by design… from what I have been able to gather after reading various forums and blogs, the w7/2008 server version of chkdsk will use all the available ram in an attempt to speed up the chkdsk.

Here’s a Microsoft article that mentions it.

Now there has been a lot of sky is falling type talk over this subject, and there are many people who have stated that their machines crashed as a result of this. To be clear in my case the machine does continue to function, although it does it very slowly. In my opinion, this behavior, even if by design, is very bug-like and mimics a memory leak in every way, just without the crash at the end. (And the memory clears up when chkdsk is done.) This seems like an odd way for Microsoft to design this, and I would prefer some other way to limit the ram used by this process.


Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s