cancel
Showing results for 
Search instead for 
Did you mean: 

A question regarding pagefile.sys

Oldjim
Resting Legend
Posts: 38,460
Thanks: 787
Fixes: 63
Registered: ‎15-06-2007

A question regarding pagefile.sys

A bit of history
When I originally built my present computer I allocated a 10GB partition for the swap file which is system managed and there was 4GB ram and there were no problems
With my rebuild the drives were left unchanged and all I changes was the motherboard, CPU and memory (now 8GB)
I just noticed that the swap file partition was showing as nearly full 300MB left which seemed odd as there was nothing special running
Rebooted the computer and the spare space is now 1.73GB
So what would cause windows to grab more of the space for pagefile.sys
Note that usually the computer isn't switched off just put into hybrid sleep
Would there be any real merit in moving the primary swap file to another drive so that there is much more capacity available
9 REPLIES 9
Anonymous
Not applicable

Re: A question regarding pagefile.sys

That would all depend on what software you are running, if you have anything with a leak it will simply allocate memory until you run out of disk space, if given a long enough life time.
If you can move the swap file then do so as that alone will give a boost in performance when used. But having said that 8GB is a lot of memory so it could be argued that you shouldn't really need a swap file at all, unless the entire memory footprint of what is running is > than 8GB. IF it is > than 8GB at start up then you have to ask yourself 'What's running and Why?'.
Also, I'll stand corrected but if your machine can hibernate then the pagefile should be >= the memory installed.
Oldjim
Resting Legend
Posts: 38,460
Thanks: 787
Fixes: 63
Registered: ‎15-06-2007

Re: A question regarding pagefile.sys

present memory usage is 2.5GB and I have a gadget running on the desktop monitoring memory and CPU usage and the memory usage doesn't get much more than 32% in normal use
Anonymous
Not applicable

Re: A question regarding pagefile.sys

Well I've just had a quick look at my own and there is a separate file for hibernation . I only have a 1GB pagefile as well and the machine as 16GB of RAM and is a VM as well.
If you want to run off hibernation you can use :
powercfg.exe /hibernate off
Oldjim
Resting Legend
Posts: 38,460
Thanks: 787
Fixes: 63
Registered: ‎15-06-2007

Re: A question regarding pagefile.sys

hiberfil.sys is a completely different thing and is located in the root of the c: drive
Anonymous
Not applicable

Re: A question regarding pagefile.sys

I realised that OJ as noted in my post, but the option to turn it off was me trying to be helpful. If you don't use it why waste the space!
Well you could of course get rid of the pagefile but it's not always recommended. Is it being used?
Oldjim
Resting Legend
Posts: 38,460
Thanks: 787
Fixes: 63
Registered: ‎15-06-2007

Re: A question regarding pagefile.sys

Because I always use hybrid sleep which means that if there is a power cut overnight everything is saved and the boot drive has stacks of spare space
The pagefile is being used but I really don't understand why Windows thinks it needs it
EDIT
Further reading shows that Windows sets the minimum swap file size as being equal to the system ram so that explains it
EDIT 2
Found out the reason - memory leak in Wolfenstein The New Order
ReedRichards
Seasoned Pro
Posts: 4,927
Thanks: 145
Fixes: 25
Registered: ‎14-07-2009

Re: A question regarding pagefile.sys

The other week I was working on a computer with a Corei7 processor and 8GB of RAM that was still a bit sluggish.  I came to the conclusion that the swap file (pagefile.sys) was too large.  I'm not sure if this is universal but If you let Windows choose the page file size it usually chooses between 1 and 1.5 x the RAM. But a 12GB file is a large entity and takes some time for the hard drive to read and write.  I came to the conclusion this might be slowing down the computer!  I even found a reference from a Windows luminary supporting the notion that the size of the swap file should be constrained - but I cannot find that again now that I want to.
Anonymous
Not applicable

Re: A question regarding pagefile.sys

Adding to what RR has said this may be of interest:
https://support.microsoft.com/en-us/kb/2860880
Oldjim
Resting Legend
Posts: 38,460
Thanks: 787
Fixes: 63
Registered: ‎15-06-2007

Re: A question regarding pagefile.sys

Now changed from System Managed to 1GB minimum 9.76GB maximum (partition size) and will see if there is any noticeable effect