Optimal XP Pro Swap File Size?

Discussion in 'Computer Support' started by Tom, Feb 17, 2008.

  1. Tom

    Tom Guest

    Hi, what is the recommended swap file size for PCs running XP pro, 70GB-
    80GB HDD, when one PC has 512MB RAM installed and the other has 2GB RAM
    installed? Shoud XP determine the swap file size?

    Tom
    Tom, Feb 17, 2008
    #1
    1. Advertising

  2. Tom

    R. McCarty Guest

    There is a general "Rule" that the Pagefile should be 1.5 times physical
    RAM. However, the base size needs to equal Physical RAM to do a
    Full Memory dump. Actual usage varies according to what you use &
    how much RAM it requires. With current PCs having 1.0 Gigabytes or
    more you'll find that the Pagefile traffic is just around ~50-75 Meg with
    normal use.

    You can move it, resize it, defrag it and all other kinds of tweaks but
    it's easiest to just let Windows manage it. Some "Performance" sites
    recommend turning it off but that works against the design of a Virtual
    memory system.

    "Tom" <> wrote in message
    news:wiXtj.328$kI4.162@trnddc05...
    > Hi, what is the recommended swap file size for PCs running XP pro, 70GB-
    > 80GB HDD, when one PC has 512MB RAM installed and the other has 2GB RAM
    > installed? Shoud XP determine the swap file size?
    >
    > Tom
    >
    R. McCarty, Feb 17, 2008
    #2
    1. Advertising

  3. Yes, let XP manage the swap file.

    "Tom" <> wrote in message
    news:wiXtj.328$kI4.162@trnddc05...
    > Hi, what is the recommended swap file size for PCs running XP pro, 70GB-
    > 80GB HDD, when one PC has 512MB RAM installed and the other has 2GB RAM
    > installed? Shoud XP determine the swap file size?
    >
    > Tom
    >
    Colin Barnhorst, Feb 17, 2008
    #3
  4. Tom

    VanguardLH Guest

    "R. McCarty" wrote in message
    news:...
    > There is a general "Rule" that the Pagefile should be 1.5 times
    > physical
    > RAM. However, the base size needs to equal Physical RAM to do a
    > Full Memory dump.


    Actually the base pagefile size should be equal to the physical RAM
    size plus 64KB. This limitation is superfluous if you configure
    Windows to NOT save a dump, even a small one, when it crashes. This
    is not related to the 64KB size for the smallest size selectable for a
    crash dump logfile. I can't remember why I include this extra 64KB
    but it's something that has stuck with me for years of doing QA
    testing on multiple Windows platforms.

    > Actual usage varies according to what you use &
    > how much RAM it requires. With current PCs having 1.0 Gigabytes or
    > more you'll find that the Pagefile traffic is just around ~50-75 Meg
    > with
    > normal use.


    I use the general rule of setting pagefile space:

    - For 256MB, or less, set the minimum pagefile size to 384MB.

    - For more than 256MB but less than 1GB, set the minimum pagefile size
    to 1.5 times the size of physical RAM.

    - Above 1GB, set maximum pagefile size to 1 times the size of physical
    RAM.

    - These defaults may be overridden if you use an application that
    wants LOTS of pagefile space. Most end-users don't run
    enterprise-level applications on their workstations so this rarely is
    a need.

    - If there are multiple hard disks, split the pagefile across those
    hard disks (at 1 times the size of the physical RAM for the pagefile
    on each hard disk). The partition must obviously not be hidden for
    Windows to use that pagefile. Use only one pagefile in one unhidden
    partition per hard disk. This helps performance because Windows will
    first attempt to use pagefiles in partition on hard disks other than
    the partition in which Windows is installed to permit overlapped I/O
    to those hard disks. It is possible to allocate a tiny pagefile in
    the Windows partition and just use the pagefiles in the other
    partitions for virtual memory but I recommend the 1x size in case you
    later lose the other hard disk(s). Do not place multiple pagefiles in
    different partitions on the same hard disk.

    - If you enable dump file logging on a Windows crash, add 64KB to the
    minimum size. Unless you are a developer debugging your own
    application that crashes, the crash dump is rarely requested by
    technical support (they usually don't know what to do with it). Users
    don't know what to do with the dump logs. On my work host, crash
    logging is enabled (complete memory dump). At home, it is disabled
    (none).

    Often I use a simpler algorithm: 1.5x for under 1GB of RAM, 1x for 1GB
    and up, set minimum = maximum for the pagefile size, and disable crash
    dump logging.

    > You can move it, resize it, defrag it and all other kinds of tweaks
    > but
    > it's easiest to just let Windows manage it.


    Actually you will want to set the minimum and maximum pagefile size to
    the same value to reduce fragmentation of its file space on your hard
    disk. Set min and max to the same value and reboot to use the new
    values. However, to remove any defragmentation already present in the
    pagefile.sys file, you will need to use a defragmenter that will touch
    that file, like SysInternals' PageDefrag (free). There is another
    trick of deleting the pagefile.sys file by rebooting into Recovery
    Console mode, unhiding that file, renaming it to something else, and
    then deleting it, and reboot back into Windows.

    If you let Windows manage the pagefile size between two different
    values for minimum and maximum size, the pagefile is more likely to
    get defragmented. With minimum = maximum, there will probably be 2 or
    3 fragments for the pagefile but it won't get worse over time.

    > Some "Performance" sites
    > recommend turning it off but that works against the design of a
    > Virtual
    > memory system.


    Even if you had a terabyte of physical RAM, some pagefile space is
    always used by the OS and your applications. Applications may not
    function if there is no pagefile space (i.e., you have gobs of
    physical memory and set max size of the pagefile to zero). Even
    Windows might not run since it expects to put part of its Exec into
    the pagefile (which can be reduced with a registry tweak but not
    completely eliminated). Some applications know that their data
    sections or some code should be pushed into the pagefile because the
    performance of the application is not impacted by using the pagefile
    and they don't want to consume more physical RAM than they really
    need.

    An application may easily ask for hundreds of megabytes of storage
    (which goes through the Virtual Memory since Virtual Memory is always
    in operation even if the pagefile min and max are set to zero). Most
    users never see this. Include the VM Size column in the Processes tab
    of Task Manager. For example, I've seen some user proclaim that a
    particular anti-virus product has less memory consumption than some
    other anti-virus program that they want to pan but they never bother
    to check the TOTAL memory consumption by checking how much pagefile
    space is consumed by their favorite anti-virus program. You might see
    in Task Manager that your favorite program only consumes 10 to 20 KB
    of physical memory (under the Memory Usage column) but neglect to see
    that it eats up another 150MB in the pagefile. They don't realize
    their favorite program is a pig on memory consumption because most of
    the data and some of its code remains dormant until the active stub
    needs it. I've seen security suites that include privacy protection
    mechanisms, like site blocking, where the configured table of blocked
    URLs and sites is data that gets loaded into the pagefile and eats up
    100 to 150 MB just for that table.

    http://support.microsoft.com/kb/555223
    http://members.shaw.ca/bsanders/WindowsGeneralWeb/RAMVirtualMemoryPageFileEtc.htm
    http://smallvoid.com/article/windows-page-file.html
    VanguardLH, Feb 17, 2008
    #4
  5. Tom

    Guest

    "Tom" <> wrote:

    >Hi, what is the recommended swap file size for PCs running XP pro, 70GB-
    >80GB HDD, when one PC has 512MB RAM installed and the other has 2GB RAM
    >installed? Shoud XP determine the swap file size?


    With 2.5GB of ram and following the baseline you would have a huge
    pagefile.sys.

    Ram is faster than Disk Access, you have enough ram you can start
    cutting down on the swap file; you could even go without a swap file
    with 2.5 Gigs memory.

    I have 2.5 gigs of memory and a 300Meg swap file (pagefile.sys), I'm
    just not ready to run without a swap file.
    --

    It was an accident
    http://www.tutztutz.com/2008/02/freakiest-accidents-ever-captured/
    , Feb 17, 2008
    #5
  6. Tom

    Guest

    , Feb 17, 2008
    #6
  7. On Sun, 17 Feb 2008 14:13:48 GMT, "Tom" <> wrote:

    > Hi, what is the recommended swap file size for PCs running XP pro, 70GB-
    > 80GB HDD, when one PC has 512MB RAM installed and the other has 2GB RAM
    > installed?



    This is *not* the same for everyone with the same amount of RAM. The
    most significant criteria for determining the page file size needed
    are what apps you run, and how much you run simultaneously. The more
    you have running, the more total virtual memory (RAM plus page file)
    you need to accommodate it.

    Beware of advice to make it some factor of the amount of RAM you have;
    that's only significant with respect to dumps, and most people have no
    need of dumps.

    Contrary to the usual advice, the more RAM you have, the *less* page
    file you need (since the page file substitutes for RAM when you don't
    have enough).


    > Shoud XP determine the swap file size?



    Despite everything I said above, making the page file smaller than the
    Windows default accomplishes nothing but saving a small amount of disk
    space. Although that used to be a valuable thing to do, in these days
    of very inexpensive large disk drives, the value of doing that is
    insignificant, and most people should just accept the Windows default.

    --
    Ken Blake, Microsoft MVP - Windows Desktop Experience
    Please Reply to the Newsgroup
    Ken Blake, MVP, Feb 17, 2008
    #7
  8. Tom wrote:
    > Hi, what is the recommended swap file size for PCs running XP pro,
    > 70GB- 80GB HDD, when one PC has 512MB RAM installed and the other
    > has 2GB RAM installed? Shoud XP determine the swap file size?


    The proper setting for Virtual Memory in Windows XP - in my opinion - is
    "System Managed"...

    --
    Shenan Stanley
    MS-MVP
    --
    How To Ask Questions The Smart Way
    http://www.catb.org/~esr/faqs/smart-questions.html
    Shenan Stanley, Feb 17, 2008
    #8
  9. Tom

    philo Guest

    "Shenan Stanley" <> wrote in message
    news:u26J%...
    > Tom wrote:
    > > Hi, what is the recommended swap file size for PCs running XP pro,
    > > 70GB- 80GB HDD, when one PC has 512MB RAM installed and the other
    > > has 2GB RAM installed? Shoud XP determine the swap file size?

    >
    > The proper setting for Virtual Memory in Windows XP - in my opinion - is
    > "System Managed"...
    >
    > --
    > Shenan Stanley
    > MS-MVP
    >



    <snip>

    I agree...just let Windows manage it and forget it
    philo, Feb 17, 2008
    #9
  10. Tom

    Meat Plow Guest

    On Sun, 17 Feb 2008 11:33:16 -0700, Ken Blake, MVP wrote:

    > On Sun, 17 Feb 2008 14:13:48 GMT, "Tom" <> wrote:
    >
    >> Hi, what is the recommended swap file size for PCs running XP pro, 70GB-
    >> 80GB HDD, when one PC has 512MB RAM installed and the other has 2GB RAM
    >> installed?

    >
    >
    > This is *not* the same for everyone with the same amount of RAM. The
    > most significant criteria for determining the page file size needed
    > are what apps you run, and how much you run simultaneously. The more
    > you have running, the more total virtual memory (RAM plus page file)
    > you need to accommodate it.
    >
    > Beware of advice to make it some factor of the amount of RAM you have;
    > that's only significant with respect to dumps, and most people have no
    > need of dumps.
    >
    > Contrary to the usual advice, the more RAM you have, the *less* page
    > file you need (since the page file substitutes for RAM when you don't
    > have enough).
    >
    >
    >> Shoud XP determine the swap file size?

    >
    >
    > Despite everything I said above, making the page file smaller than the
    > Windows default accomplishes nothing but saving a small amount of disk
    > space. Although that used to be a valuable thing to do, in these days
    > of very inexpensive large disk drives, the value of doing that is
    > insignificant, and most people should just accept the Windows default.


    Some processes use the page file regardless. I agree with letting XP
    decide it's size. In linux my swap file doesn't exist because it's not
    needed with 4 gigs of ram (even with 1 or 2). Big diffference over XP's
    page file.
    Meat Plow, Feb 17, 2008
    #10
  11. On Sun, 17 Feb 2008 09:54:13 -0800, wrote:

    > "Tom" <> wrote:
    >
    > >Hi, what is the recommended swap file size for PCs running XP pro, 70GB-
    > >80GB HDD, when one PC has 512MB RAM installed and the other has 2GB RAM
    > >installed? Shoud XP determine the swap file size?

    >
    > With 2.5GB of ram and following the baseline you would have a huge
    > pagefile.sys.
    >
    > Ram is faster than Disk Access, you have enough ram you can start
    > cutting down on the swap file; you could even go without a swap file
    > with 2.5 Gigs memory.
    >
    > I have 2.5 gigs of memory and a 300Meg swap file (pagefile.sys), I'm
    > just not ready to run without a swap file.



    You should *never* run without a page file, no matter how much memory
    you have. If you did so, you wouldn't be able to use all the RAM you
    have. That's because Windows pre-allocates page file space, in
    anticipation of possibly needing to use it. Although that
    pre-allocation speeds up page file use if it's needed, in most cases
    if you have enough RAM, that pre-allocated space is never needed and
    never actually gets used.

    But if there is no page file, that pre-allocation has to get made in
    real memory (RAM) instead. That means that the space for that
    pre-allocation (and it can be substantial) is tied up and not
    available for any other use.

    --
    Ken Blake, Microsoft MVP - Windows Desktop Experience
    Please Reply to the Newsgroup
    Ken Blake, MVP, Feb 17, 2008
    #11
  12. Tom

    jorgen Guest

    Ken Blake, MVP wrote:

    > You should *never* run without a page file, no matter how much memory
    > you have. If you did so, you wouldn't be able to use all the RAM you
    > have. That's because Windows pre-allocates page file space, in
    > anticipation of possibly needing to use it. Although that
    > pre-allocation speeds up page file use if it's needed, in most cases
    > if you have enough RAM, that pre-allocated space is never needed and
    > never actually gets used.
    >
    > But if there is no page file, that pre-allocation has to get made in
    > real memory (RAM) instead. That means that the space for that
    > pre-allocation (and it can be substantial) is tied up and not
    > available for any other use.


    Can you point to some technical papers at microsoft to back that up?
    jorgen, Feb 17, 2008
    #12
  13. Tom

    R. McCarty Guest

    http://en.wikipedia.org/wiki/Virtual_memory

    Virtual Memory systems has been around for a long time. The
    DEC VAX computer system ran VMS ( Virtual Memory System ).
    Some of the creators of VMS where responsible for the original
    Windows NT OS.

    Even if you turn off the pagefile, XP will create a temporary one in
    C:\Windows\System32 as TempPF.Sys

    "jorgen" <na@invalid> wrote in message
    news:%...
    > Ken Blake, MVP wrote:
    >
    >> You should *never* run without a page file, no matter how much memory
    >> you have. If you did so, you wouldn't be able to use all the RAM you
    >> have. That's because Windows pre-allocates page file space, in
    >> anticipation of possibly needing to use it. Although that
    >> pre-allocation speeds up page file use if it's needed, in most cases
    >> if you have enough RAM, that pre-allocated space is never needed and
    >> never actually gets used.
    >>
    >> But if there is no page file, that pre-allocation has to get made in
    >> real memory (RAM) instead. That means that the space for that
    >> pre-allocation (and it can be substantial) is tied up and not
    >> available for any other use.

    >
    > Can you point to some technical papers at microsoft to back that up?
    R. McCarty, Feb 17, 2008
    #13
  14. Tom

    Guest

    jorgen <na@invalid> wrote:

    >Ken Blake, MVP wrote:
    >
    >> You should *never* run without a page file, no matter how much memory
    >> you have. If you did so, you wouldn't be able to use all the RAM you
    >> have. That's because Windows pre-allocates page file space, in
    >> anticipation of possibly needing to use it. Although that
    >> pre-allocation speeds up page file use if it's needed, in most cases
    >> if you have enough RAM, that pre-allocated space is never needed and
    >> never actually gets used.


    >> But if there is no page file, that pre-allocation has to get made in
    >> real memory (RAM) instead. That means that the space for that
    >> pre-allocation (and it can be substantial) is tied up and not
    >> available for any other use.


    >Can you point to some technical papers at microsoft to back that up?


    I just deleted my Pagefile.sys (no page file setting), and ran PerfMon
    It's a lot different than last time I used it; Lots of .net settings.
    But set: .NET CLR memory

    "This counter displays the amount of virtual memory (in bytes)
    currently committed by the Garbage Collector. (Committed memory is the
    physical memory for which space has been reserved on the disk paging
    file)."

    Shows 0, nada

    And I still get my kills in COD4 :}

    --

    Lineage ][
    http://flashgame.plaync.jp/dwarfcomplete.jsp
    , Feb 17, 2008
    #14
  15. Tom

    Guest

    "R. McCarty" <> wrote:

    >http://en.wikipedia.org/wiki/Virtual_memory
    >
    >Virtual Memory systems has been around for a long time. The
    >DEC VAX computer system ran VMS ( Virtual Memory System ).
    >Some of the creators of VMS where responsible for the original
    >Windows NT OS.


    The AmigA never used a swap file, did with 10megs what it takes
    windows 256megs and a swap file to do. And you just pushed the button
    to turn them off, no asking the system if it was ready of not.

    > Even if you turn off the pagefile, XP will create a temporary one in
    >C:\Windows\System32 as TempPF.Sys


    I don't find that file (TempPF.Sys) anywhere on the OS partition or
    C:\ drive

    >"jorgen" <na@invalid> wrote in message
    >news:%...
    >> Ken Blake, MVP wrote:
    >>
    >>> You should *never* run without a page file, no matter how much memory
    >>> you have. If you did so, you wouldn't be able to use all the RAM you
    >>> have. That's because Windows pre-allocates page file space, in
    >>> anticipation of possibly needing to use it. Although that
    >>> pre-allocation speeds up page file use if it's needed, in most cases
    >>> if you have enough RAM, that pre-allocated space is never needed and
    >>> never actually gets used.
    >>>
    >>> But if there is no page file, that pre-allocation has to get made in
    >>> real memory (RAM) instead. That means that the space for that
    >>> pre-allocation (and it can be substantial) is tied up and not
    >>> available for any other use.

    >>
    >> Can you point to some technical papers at microsoft to back that up?

    >


    --

    Lineage ][
    http://flashgame.plaync.jp/dwarfcomplete.jsp
    , Feb 17, 2008
    #15
  16. Tom

    jorgen Guest

    R. McCarty wrote:

    > Even if you turn off the pagefile, XP will create a temporary one in
    > C:\Windows\System32 as TempPF.Sys


    I think that only goes for Windows 2000 and earlier

    http://support.microsoft.com/kb/257758
    jorgen, Feb 17, 2008
    #16
  17. Tom

    jorgen Guest

    R. McCarty wrote:
    > http://en.wikipedia.org/wiki/Virtual_memory
    >
    > Virtual Memory systems has been around for a long time. The
    > DEC VAX computer system ran VMS ( Virtual Memory System ).
    > Some of the creators of VMS where responsible for the original
    > Windows NT OS.


    Virtual memory "space" is not equal the paging file. A page can be
    backed up by real ram, a paging file or something else
    jorgen, Feb 17, 2008
    #17
  18. On Sun, 17 Feb 2008 21:38:55 +0100, jorgen <na@invalid> wrote:

    > Ken Blake, MVP wrote:
    >
    > > You should *never* run without a page file, no matter how much memory
    > > you have. If you did so, you wouldn't be able to use all the RAM you
    > > have. That's because Windows pre-allocates page file space, in
    > > anticipation of possibly needing to use it. Although that
    > > pre-allocation speeds up page file use if it's needed, in most cases
    > > if you have enough RAM, that pre-allocated space is never needed and
    > > never actually gets used.
    > >
    > > But if there is no page file, that pre-allocation has to get made in
    > > real memory (RAM) instead. That means that the space for that
    > > pre-allocation (and it can be substantial) is tied up and not
    > > available for any other use.

    >
    > Can you point to some technical papers at microsoft to back that up?



    http://support.microsoft.com/kb/889654, which includes the sentence
    "When no page file exists, or the page file is insufficient, the
    system reserves some virtual memory in the physical memory for its
    paging needs."

    --
    Ken Blake, Microsoft MVP - Windows Desktop Experience
    Please Reply to the Newsgroup
    Ken Blake, MVP, Feb 17, 2008
    #18
  19. No, it applies post W2k as well.

    "jorgen" <na@invalid> wrote in message
    news:...
    > R. McCarty wrote:
    >
    >> Even if you turn off the pagefile, XP will create a temporary one in
    >> C:\Windows\System32 as TempPF.Sys

    >
    > I think that only goes for Windows 2000 and earlier
    >
    > http://support.microsoft.com/kb/257758
    Colin Barnhorst, Feb 17, 2008
    #19
  20. Tom

    jorgen Guest

    Colin Barnhorst wrote:
    > No, it applies post W2k as well.
    >


    So where is it? I don't have any temppf on my xp, as i can see. The
    article also says it "may" be created. I'm guessing it is creating a
    temporary one to make sure there is enough memory for the user to go in
    and setup a correct configuration
    jorgen, Feb 17, 2008
    #20
    1. Advertising

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

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Mike

    swap disk size

    Mike, Feb 5, 2004, in forum: Computer Support
    Replies:
    14
    Views:
    816
  2. bmoag

    Optimal Win XP swap file size

    bmoag, Apr 1, 2005, in forum: Computer Information
    Replies:
    0
    Views:
    362
    bmoag
    Apr 1, 2005
  3. Mel Comisarow

    Optimal size of photosensor

    Mel Comisarow, Feb 10, 2005, in forum: Digital Photography
    Replies:
    23
    Views:
    688
    Roger N. Clark (change username to rnclark)
    Feb 25, 2005
  4. One4All

    Disconnect Between HD File Size & PS's File Size

    One4All, Sep 9, 2007, in forum: Digital Photography
    Replies:
    8
    Views:
    346
    One4All
    Sep 12, 2007
  5. John Smith

    Optimal DPI for a Canon Pro 9500 Printer ???

    John Smith, Aug 6, 2008, in forum: Digital Photography
    Replies:
    2
    Views:
    868
    tomm42
    Aug 6, 2008
Loading...

Share This Page