Optmising Win2K Page file size

g__day

Distinguished
Jul 25, 2001
14
0
18,510
I'd be greatful for any advice on how to optmise your pagefile setting if you run Win2k + SP2 on machines with

128MB physical ram - typical m/m internet and games machine
256MB ditto
384MB same again
512MB same again

Does Win2K auto setting work well or should you hard code in Min and Max settings?
 

ejsmith2

Distinguished
Feb 9, 2001
3,228
0
20,780
Well, there's about 4 or 5 different ways to do it, but here's what I do:

First off, when win2k installs, the default 384+ meg swap file is in about 25-30 fragments. WTF?!??!?!

Anyway, I turn it down to 2meg, and restart. Then defrag. Restart, and defrag again. It moves just a little bit more. Then I crank the swap file up to 1x-4x the Ram size, depending on what I use. I don't use photoshop or flaskmpeg a lot on my laptop, so I never crank it up above 1x with 144meg of ram.

You can use Diskeeper (retail) to defrag the swap file completely. The LT version is the defrager that's with win2k, but the retail version has quite a few more options.
 

Snorklis

Distinguished
Jul 11, 2001
108
0
18,680
hi!

I have a small program that defrags the swap and system files very good. Its called pagedfrg.exe and exists on sysinternals.com
take a look!
 
G

Guest

Guest
Hi,

I just noticed your posting and the answers you got are not complete and does not answer your question, so I wanted to reply at the risk of being a little late...

Windows 2000 sets the swap file to a default of RAM+12MB but it is FREE TO MANIPULATE THE SWAP FILE as it wishes, enlarging and shrinking the swap file as required. This causes fragmentation of the swap file and, as mentioned already, the built-in defrag will NOT defragment the swap file at all. The alternative, other than "zeroing" the swap file, rebooting, defragging it, then resetting it on a REGULAR basis, is to set a FIXED MINIMUM AND MAXIMUM setting as you had asked in your posting. If you don't do this, you will ALWAYS have the risk of a badly fragmented swap file - as this is a dynamically changing file which Windows 2000 can adjust in size, and fragmentation occurs for exactly this reason-changing information (files) on the PC.

A good way to determine the swap file size is to use the Windows Administrative tools>Performance counters for the PAGING FILE. Under PERFORMANCE OBJECT drop down list, select PAGING FILE and under counters select %USAGE PEAK. Also, select the PROCESS performance object and select PAGE FILE BYTES as the counter with "_Total" as the instances to monitor ALL YOUR RUNNING PROCESSES. The %usage should be high (perhaps, around 80-90%) for the size of paging file you select as min and max. - this tells you that your system is using most of your paging file, even with programs which use up a lot of memory and/or with multiple applications open. Try testing with many apps open, or a large photo with high resolution open (perhaps using a PhotoShop-like program) and see if your paging file size is enough. If the percentage is low, then reduce the pagefile min and max sizes.

If you ever get a message that Windows is increasing your paging file size because it was too small/insufficient, you would obviously know right away it is too small without trying a performance test.

Make sure you select the SAME PAGING FILE SIZE for min and max and use the above performance if you want to guide you in your selection or to monitor your page file usage after you select a size.

I recommend that you can start with DOUBLE PHYSICAL RAM with all the memory configurations you mentioned, although, by using the above performance monitor you can see if your page file may be TOO LARGE, especially for a system which already has 512MB of RAM for example!

Another thing is not to set the paging file too large, especially if you already have 256MB or more of RAM as this can really WASTE hard drive space. This is why using the Performance monitoring tools will help you determine with more accuracy, the size of the paging file so you don't waste unnecessary HDD space with a paging file which is 4x of RAM (as one person suggested). Very few programs will require such a large page file unless your RAM is 128MB or less and you use programs relying heavily on RAM.

Good luck. Write back if you are unclear about the performance monitor.

John