Disable The Windows Swapfile!!

Electronic Punk

willalwaysbewithyou
Staff member
Political Access
Joined
2 Dec 2001
Messages
18,694
If you ave enought memory (eg I have 512 SDRAM) you can disable the swap file, prevent any swapping and therefore observe an increase in speed.

Thanks to mkanet for the information, here is what I did:

Go to this registry location:

[HKEY_LOCAL_MACHINE\SYSTEM\ControlSet001\Control\Session Manager\Memory Management]

Then set "DisablePagingExecutive" to "1"

Then you need to go into the advanced settings of XP for performance, and make sure you dont have swap enabled on any of your drives.

Reboot...

Thats it.


-=-=-=

I am using it now and Internet Explorer is loading instantly without even readding the HDD visably.
Here is a screenshot of my task manager and as you can see mym commit charge is tiny... Reduced from 200 megs before running this tweak, let me know how you guys get on...
 
Its a gr8 tip for those of us who have a lot of RAM!! :)

One problem though: If you have the Paging File disabled, Adobe Photoshop won't open up. Photoshop needs virtual memory enabled ... just thought I should point this out.

I luv tweaking!! :p
 
I recommend against disabling the paging file no matter how much memory you have. You can simply set it to a small number (50 mb -- 100 mb, whatever) and that will insure that any programs that look for a swap file will be able to run, yet it is small enough that it will not be a drag on performance (assuming you believe that a swapfile can be a drag....I have 512mb w/a 768 mb static swap file and I'm very happy with the performance of my system - but certainly everyone is different).
 
Originally posted by Electronic Punk
If you ave enought memory (eg I have 512 SDRAM) you can disable the swap file, prevent any swapping and therefore observe an increase in speed.
Sorry, but this is "common misconception number 312" (or maybe 313; I lose track).
Then set "DisablePagingExecutive" to "1"
This only disables paging of certain parts of the OS, not paging in general. It's an unnecessary mod at best -- if you have enough RAM, the parts of the OS you are using will stay in memory anyway; if you don't have enough RAM, you really WANT the OS to be pageable just like everything else.
Then you need to go into the advanced settings of XP for performance, and make sure you dont have swap enabled on any of your drives.
That would be "paging", not swapping (big difference), but anyway --

Windows XP is a virtual memory operating system. It will ALWAYS page from and to disk; this is an essential part of how a VM OS works.

For a given workload and a given amount of RAM, there always will be about the same amount of paging to and from disk. All you are doing by getting rid of the pagefile is making the OS page more to other files.

There MAY be a small performance benefit, depending on what types of virtual address space (those backed by the paging file, vs. those backed by other files) are being accessed more often. There can just as easily be a performance hit.

Getting rid of the paging file also drastically increases your chances of seeing the infamous "running low on virtual memory" popup. Think of the paging file as a safety net. If you don't need it, having it there doesn't hurt anything. If you do need it, it's really better to have it than to hit the ground...
I am using it now and Internet Explorer is loading instantly without even readding the HDD visably.
Post hoc fallacy. You rebooted, right? Everything's different.
Here is a screenshot of my task manager and as you can see mym commit charge is tiny... Reduced from 200 megs before running this tweak, let me know how you guys get on...
"Commit charge" is not the amount of stuff in the paging file. It is the amount of virtual memory currently allocated of the type that is backed by the paging file (if any), if it can't all be kept in RAM. But on systems with today's typical large RAM loads, most of the "commit charge" is actually in RAM.

Btw, the "PF usage" graph is the same as the "commit charge" counter. Does it not strike you as odd that your system shows a nonzero "PF usage", even though you have no paging file? That is because "PF usage" shows only the ... well, I explained it above.

If you want to know how much is REALLY *in* the paging file, see the Performance applet, Pagefile object, %usage counter.
 
Re: Re: Disable The Windows Swapfile!!

Originally posted by jeh

Sorry, but this is "common misconception number 312" (or maybe 313; I lose track).

This only disables paging of certain parts of the OS, not paging in general. It's an unnecessary mod at best -- if you have enough RAM, the parts of the OS you are using will stay in memory anyway; if you don't have enough RAM, you really WANT the OS to be pageable just like everything else.

That would be "paging", not swapping (big difference), but anyway --

Windows XP is a virtual memory operating system. It will ALWAYS page from and to disk; this is an essential part of how a VM OS works.

For a given workload and a given amount of RAM, there always will be about the same amount of paging to and from disk. All you are doing by getting rid of the pagefile is making the OS page more to other files.

There MAY be a small performance benefit, depending on what types of virtual address space (those backed by the paging file, vs. those backed by other files) are being accessed more often. There can just as easily be a performance hit.

Getting rid of the paging file also drastically increases your chances of seeing the infamous "running low on virtual memory" popup. Think of the paging file as a safety net. If you don't need it, having it there doesn't hurt anything. If you do need it, it's really better to have it than to hit the ground...

Post hoc fallacy. You rebooted, right? Everything's different.

"Commit charge" is not the amount of stuff in the paging file. It is the amount of virtual memory currently allocated of the type that is backed by the paging file (if any), if it can't all be kept in RAM. But on systems with today's typical large RAM loads, most of the "commit charge" is actually in RAM.

Btw, the "PF usage" graph is the same as the "commit charge" counter. Does it not strike you as odd that your system shows a nonzero "PF usage", even though you have no paging file? That is because "PF usage" shows only the ... well, I explained it above.

If you want to know how much is REALLY *in* the paging file, see the Performance applet, Pagefile object, %usage counter.
WHEN I D O that i get vss errors?
 
Well, I will go spank my sources. A good read. Thanks for the info.
 
Originally posted by Electronic Punk
Well, I will go spank my sources. A good read. Thanks for the info.
spanka.gif
 
Re: Re: Re: Disable The Windows Swapfile!!

Originally posted by BMWCHUBB
WHEN I D O that i get vss errors?
When you do what? Try to run the Performance applet? You didn't disable the "performance logs and alerts" service, did you? :D
 
Allan brings out a good point. Some programs will not work without a swapfile, regarding of how much RAM your computer has. Just set it to a small fixed size, such as 50 - 100 MB.
 
Originally posted by Frank Lavallee
Just set it to a small fixed size, such as 50 - 100 MB.

Frank, jeh brings out good points concerning the swap file...are you saying you dissagree with him?
 
Hello, Dirk. I just signed up with this forum today. It's good to see some of you guys on this forum, like TweakXP and SpeedGuide.

Dealer, my only disagreement with any posts on this thread would be with someone who says to disable virtual memory(the swapfile) completely. I think that the majority of us will agree that a swapfile, even a small one, is necessary to have, in order to keep ALL programs running.
 
Hi Frank...I saw your website...excellant...you should post the link, I don't have it.

I asked if you dissagreed with jeh, because he's saying a large swap file is neccesary for smoothe performance,...that xp will page somewhere else if the swap file is too small...

I can't find the link to his thoughts, but I'll post something later today...for now, this is a start...he's got a more in depth explanation over at tweak...give his name a search
 
Thanks for the nice comment about my website, Dealer. I'm still pretty new to XP and have a lot to learn about it, so my website is directed towards those who still use 95 and 98(I still have 98SE on my desktop and still enjoy using it). For the benefit of anyone else who wants to look at it, the URL is http://9337387.home.icq.com/index.html :D Jeh may be right about the swapfile, but I'm not experienced enough to question his theory.
 
Originally posted by dealer
I asked if you dissagreed with jeh, because he's saying a large swap file is neccesary for smoothe performance,...that xp will page somewhere else if the swap file is too small...
Er, no. Those two sentences aren't equivalent.

If you change the first one to read "large enough", and the second to "XP will simply page more to other files if the page file is too small", that's much closer.

Which begs the question, what's "large enough"? With 512 MB or more RAM and a light app mix (no huge Photoshop edits, for ex.) 50 or 100 MB might well be plenty. If you want to be precise, go to Perfmon, Pagefile object, and look at the "%usage peak" counter. Multiply by your current pagefile size. That's your bare minimum. You probably want it to be at least double that size, though, probably more like four times, to avoid free space allocation delays. (so much for being precise!)

The other side of the coin is that a too-large pagefile doesn't hurt anything, except of course the loss of disk space; it in no way encourages more paging to disk. Again, think of a safety net... a larger one doesn't encourage you to fall more; it just provides better coverage in case you do fall.
 
Well I take my hat off to JEH. Nice and understandable for us idiots out here.

And also to dealer for making JEH reply
 
Jeh:

I've got a 30 GB hard drive on my Windows XP laptop, so conserving hard drive space isn't a real issue with me, especially since 26 GB of it is still free.

If a 50 - 100 MB swapfile is going to do the job though, I see no sense in me using a 768 MB swapfile.

Just MY personal preference. :)
 

Members online

No members online now.

Latest profile posts

Also Hi EP and people. I found this place again while looking through a oooollllllldddd backup. I have filled over 10TB and was looking at my collection of antiques. Any bids on the 500Mhz Win 95 fix?
Any of the SP crew still out there?
Xie wrote on Electronic Punk's profile.
Impressed you have kept this alive this long EP! So many sites have come and gone. :(

Just did some crude math and I apparently joined almost 18yrs ago, how is that possible???
hello peeps... is been some time since i last came here.
Electronic Punk wrote on Sazar's profile.
Rest in peace my friend, been trying to find you and finally did in the worst way imaginable.

Forum statistics

Threads
62,015
Messages
673,494
Members
5,621
Latest member
naeemsafi
Back