XP swap file or what?

Discussion in 'Windows Desktop Systems' started by dave holbon, Dec 2, 2002.

  1. dave holbon

    dave holbon Moderator

    Messages:
    1,014
    Location:
    London England
    It’s always interesting to view people’s conception about the swap file in XP as even the most experienced personnel keep getting it wrong, well nearly.

    Microsoft quote: -
    In a default Windows XP installation, Windows creates the page file in the root folder on the same drive that holds the Windows system files. The size of the page file is determined by the amount of RAM in your system: By default, the minimum size is 1.5 times the amount of physical RAM on your system, and the maximum size is 3 times that value. You can see the page file in a Windows Explorer window if you configure Windows to show hidden and system files; look for Pagefile.sys in the root of your system drive.
    Lets look at the two most extreme examples: -

    1. 4 gig ram on an Intel 3Ghz CPU.

    This would install XP with a swap file of approx (6gig min to 12gig max) swap file.

    2. 68meg on an AMD 500Mhz,

    This would install XP with a swap file of approx (111meg to 204meg) swap file.

    Both are clearly completely (in)correct but are reversed in practice since service pack one (nothing new here then) as the amount of memory a computer actually uses is not a fixed algorithm (unknown).

    a. XP/NT/2000 cannot operate stably without a swap file, any swap file.
    b. You cannot completely remove the swap file, even though you have the option and think you have/can.
    c. Never move the swap file from the root directory or when XP crashes you will be left with nothing. Only system managers with the correct training can do this.
    d. XP always uses system ram first and only when this is exhausted does it revert to the hard drive (swap file). This is always true.
    e. You can’t optimise the swap file unless you are an XP expert with the correct training. Having said this if you have 4gig of memory and a smallish hard drive setting it to it’s minimum setting which I determine to be about 500meg should suffice. But you will be taking a risk; it’s a question of resources.

    Remember that XP/NT/2000 are Unix based not DOS so you need to reconcile that the kernel relies on the swap file as part of the operating system which DOS could not comprehend until Windows 3.1 was released.
     
  2. Perris Calderon

    Perris Calderon Moderator Staff Member Political User

    Messages:
    12,332
    Location:
    new york
    as a whole, dave that's a very nice post.

    though as for (e), I believe the swapfile can be slightly improved for some but not all users, who would like to raise the initial minimum...though I agree, for most purposes, and most users, the default is actually the best choice.

    I also think that experimenting with a smaller swapfile then the default, (as you suggest might be possible with 4 gigs of ram), is an experiment that has nothing as a reward if successful, and a performance hit the user might not even recognize if the experiment is flawed.

    don't forget...if you are actually short of hardrive space, xp will actually try to get by with as small a pagefile as it can stand...one of the main reasons, even if you don't have a hell of a lot of space available, the default will probably serve best

    always good to see you Dave...where ya been?
     
  3. dave holbon

    dave holbon Moderator

    Messages:
    1,014
    Location:
    London England
    Ten beers away only!
     
  4. gothic

    gothic LinuXPert

    Messages:
    453
    Location:
    Cornwall Nr. England
    Always had an allergy with the swap file. Studied many white papers and articles on it, none agree on size/position etc. I have a fair bit of ram (1 gig DDR) but have set aside a little partition of 300 meg solely for the use of the pagefile.sys which I make a fixed size. Because there are so many 3rd party applications which refuse to function without the swap file I have been unable to be rid of it completely. (Photoshop and Reason being 2 prime examples!!)
    I think it's always been a case of "Each to his own", but still strenuously oppose the damn thing now that we have much more capable machines with larger capacity RAM and HDD.

    TOK