XP Pro - Swap File Size for Modern Systems

J

Jeff McAhren

Sorry for this question, but I have read so much contradictory data on this,
I can't get a straight answer. I seems that while opinions are plentiful,
not many seem to be based on fact, or the rules date back to the days when a
nice system had a 4GB disk and 16MB of RAM.

What is the optimal size for the swap file for Windows XP Pro. I currently
have 256MB RAM, but I'm planning on adding another 256MB (512MB total) in
the not too distant future.

This is my home computer. I use it for normal the home stuff (email,
internet, excel, word, money), and for home movie editing / encoding and DVD
burning, which is very resource intensive.

Is it still recommended to make the swap file size static? Should it indeed
be on it's own partition? What is the optimal cluster size for that
partition?

Thanks!

Jeff McAhren
 
R

Richard Harris

Generally it's best to let Windows handle it all on it's own. However you
say you're gonna be doing encoding and stuff, and it might be best to have a
decidated drive/partition so you can keep it defragged and clean.

Rich
 
C

Carey Frisch [MVP]

For best performance, leave the page file on the same
partition Windows XP is installed on. Moving the page
file to a different partition, on the same drive, will actually
degrade performance due to additional seek time.

Virtual Memory in Windows XP
http://aumha.org/win5/a/xpvm.php

Windows XP runs best when installed on a drive or partition
formatted NTFS using the default 4KB cluster size.

--
Carey Frisch
Microsoft MVP
Windows XP - Shell/User

Be Smart! Protect your PC!
http://www.microsoft.com/security/protect/

------------------------------------------------------------------------------------------


| Sorry for this question, but I have read so much contradictory data on this,
| I can't get a straight answer. I seems that while opinions are plentiful,
| not many seem to be based on fact, or the rules date back to the days when a
| nice system had a 4GB disk and 16MB of RAM.
|
| What is the optimal size for the swap file for Windows XP Pro. I currently
| have 256MB RAM, but I'm planning on adding another 256MB (512MB total) in
| the not too distant future.
|
| This is my home computer. I use it for normal the home stuff (email,
| internet, excel, word, money), and for home movie editing / encoding and DVD
| burning, which is very resource intensive.
|
| Is it still recommended to make the swap file size static? Should it indeed
| be on it's own partition? What is the optimal cluster size for that
| partition?
|
| Thanks!
|
| Jeff McAhren
 
R

Rick \Nutcase\ Rogers

Hi,

If you want full memory dumps for analyzing crashes, then you want the
minimum size to at least be equal to the installed ram. If you don't, then
set a minimum size equal to that which is in normal use. To determine this
"optimal" size for your system, you yourself must monitor its size - no one
is going to be able to tell you what that is. It depends on your usage
habits and the software your load. I notice that you include video editing -
this in itself occupies a fairly large amount of ram, and the more you have
the better off you'll be. I would *suggest* that you set your minimum size
to ~512MB at this point and see how it goes. Do not under any circumstances
set a maximum, unless you like 'out of memory' errors.

The default cluster size for NTFS is 4k, and you should leave that alone. If
you are using FAT32, you should leave that at the default cluster size for
the partition as well. If you want to put the page file on a separate
partition, that is fine, but put it on a partition that is not used for
anything else. You probably should get a better understanding of what
virtual memory is before you begin, this page may help:
http://aumha.org/win5/a/xpvm.htm

--
Best of Luck,

Rick Rogers aka "Nutcase" MS-MVP - Win9x
Windows isn't rocket science! That's my other hobby!

Associate Expert - WinXP - Expert Zone
 
R

R. McCarty

There is no "Optimal" size for the Pagefile.Sys. That being said
Windows merges both Physical memory and the Pagefile to create
the Virtual memory. Like yourself, I've read all the Tips & Tricks,
Tech Notes and other documentation and have come to this
conclusion. I have the System performance counters loaded so I
can monitor the "True" pagefile usage. I've had static Pagefiles,
No Pagefiles, System managed and every other permutation of it.

In reality, my pagefile use never exceeds 35% of a 128 Megabyte
minimum pagefile. You can drive yourself crazy trying different
locations and all the other settings. Windows XP does a good
job at managing "Memory". It's best to just have a Pagefile with
a minimum of 128 and a maximum of 512+. The arguments about
a dedicated partition, second drive, etc all may have some small
effect -But the end result is almost always no difference.

It's more important to limit the services and processes that are
running on your system, than twiddling with the Pagefile.Sys.
 
J

Jeff McAhren

Thanks for the info!

I'm glad you mentioned monitoring the various services. I do make an
effort to understand what is running and why, but I'm not very good at it.
What is a good resource for determining what all of the various services are
(both windows and non-windows services), and what can be safely stopped?
The service info in the OS doesn't tell you what really relies on the
service, and what will happen if you disable it.

Thanks!
 
R

R. McCarty

The following web-site is the "De-facto" reference for Windows
XP services.
http://www.blackviper.com/WinXP/servicecfg.htm

Each service lists it's dependencies in the MMC. Just double-
click each Service name and then the Dependency tab.

I would recommend before you change service start modes,
you do a full Image backup of your system.

This is usually a read-up first and allocate a good amount of
time to experiment process. (No Alcohol or Lots of Coffee!).
 
J

Jeff McAhren

Excellent, Thanks!!!!!

When you say "Image".... do you recommend Windows "Automated System
Recovery", or do you recommend something like Norton Ghost? I would love
to understand how I can "reset" my machine after mucking it up by installing
random shareware for 12 months.

Sorry for all the questions, I'm setting up my first XP Pro machine... I
have been using Win2k Pro for the last four years.
 
R

R. McCarty

"Image" backup denotes a compressed, single module that contains
an exact,full copy of the partition or full drive. Norton Ghost or their
Drive Image software is what I use. Also, there are products like
BootITNG, True Image and others. The two key points about an
image is 1st - Use the verify data option so you can be assured that
the image itself is reliable and 2nd store the image off the PC itself.
(Copy or burn it to CD-R or DVD disks). Some people store their
images on a removable disk drive, but the problem with that is that
all magnetic media is subject to "Crashes".
Sometimes it is even a good idea to actually restore the image to
your drive to ensure that you are covered. Nothing is worse than
needing a Image backup and finding out it is "Corrupted." or
unusable.
 
K

Ken Blake, MVP

In
Jeff McAhren said:
What is the optimal size for the swap file for Windows XP Pro. I
currently have 256MB RAM, but I'm planning on adding another 256MB
(512MB total) in the not too distant future.


There is no "optimal size" that's right for everyone. It depends
on what apps you run.

I recommend that you have a relatively small minimum (200MB or
so), but leave the maximium very large so it can grow if your
apps should need it. There's no downside to doing this; if it
never needs to grow to that maximum, it doesn't hurt you in any
way.

This is my home computer. I use it for normal the home stuff (email,
internet, excel, word, money), and for home movie editing / encoding
and DVD burning, which is very resource intensive.

Is it still recommended to make the swap file size static?


If by "static" you mean the same fixed size for minimum and
maximum, that was *never* a good thing to do.

Should it
indeed be on it's own partition?


No. Doing that puts it farthur from the other frequently-used
data on the drive, increases head movement to and from, and
therefore decreases performance. Putting it on a second
*physical* drive is a good idea (unless that second drive is much
slower than the first). For best performance the page file should
be on the most-used partition of the least-used physical drive.
For almost everyone with a single physical drive, that's the same
partition that Windows is installed on.
 
A

Al Dykes

Thanks for the info!

I'm glad you mentioned monitoring the various services. I do make an
effort to understand what is running and why, but I'm not very good at it.
What is a good resource for determining what all of the various services are
(both windows and non-windows services), and what can be safely stopped?
The service info in the OS doesn't tell you what really relies on the
service, and what will happen if you disable it.

Thanks!

Task Manager is the seay way to get a quick idea of what's running
on your machine and how big each one is;

Right Mouse Click on the task bar, pick task manager. The process tab
tells you what and how big, the performace tab tells you how much
memory you have left.

For a deeper understanding run perfmon.exe


When I know what my requirements are I like to set the MIN amd MAX
equal, then do a stand-alone defrag to make one big swap file. I've
seen developer's systems with the swap file broken into litterly
hundreds of fragments.

I can imagine a memory manager that would actually take advantage of
parts of the pagefile.sys spread around on the drive to minimize
seek time, but if I'm right I doubt that XP does it.
 
B

Barry Watzman

This is a controversial subject and in my experience there is NOT any
consensus on this subject. Personally, I beleive that a static swap
file does slightly improve performance, and I use 2.5x RAM for 256 megs
or less, but only 2x RAM for 512 megs or more.
 
A

Al Dykes

This is a controversial subject and in my experience there is NOT any
consensus on this subject. Personally, I beleive that a static swap
file does slightly improve performance, and I use 2.5x RAM for 256 megs
or less, but only 2x RAM for 512 megs or more.


Putting swap and TEMP on a second drive can help performance,
depending on the workload, but with only one drive, keep it in
your main paritiion.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top