Link to home
Start Free TrialLog in
Avatar of JeffBeall
JeffBeallFlag for United States of America

asked on

windows xp virtual memory

back in the day, i remember hearing that if you put the virtual memory of winXP on a seperate hard drive ( so the system disk is on IDE1, and the disk with the virtual memory is on IDE2 ) then you will see a performance increase.
i have tried this and it did seem to work. however as the drive aged i think it made things worse - or maybe the disk just needed formatting - but anyhow, it got me thinking. what if you could make windows virtual memory only exist in the actual memory?
so in any flavor of windows, is there a way to force virtual memory to just run in actual memory and NOT on the hard drive?
ASKER CERTIFIED SOLUTION
Avatar of lamaslany
lamaslany
Flag of United Kingdom of Great Britain and Northern Ireland image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Then it wouldn't be 'virtual'.  The purpose of 'virtual' memory is to swap out sections of RAM (real) memory that are not being currently used to make room for something that is needed.  It makes 512MB of RAM act (slowly) like 2GB of RAM.
Avatar of JeffBeall

ASKER

i get the whole "virtual" thing. but it seems to me to be an out dated concept left over from the days when ram wasn't cheap and before 64bit addressing came around and windows couldn't address a huge amount of ram.
i must admit that windows 7, to me, seems to handle memory very well.
i just always look for ways to increase speed.
SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Virtual memory helps the OS manage real ram more efficiently, and it doesn't matter whether it's Linux or Windows (although each os uses it differently), in the end it's better for the OS no matter how much physical ram you have installed. You are best off leaving it on. Also, you might even want to enable it on the system drive (usually C:) so that windows gets a full dump file in the case it crashes, otherwise you just get a mini dump file which does not help in most of the cases of troubleshooting the root cause.
Putting the pagefile in RAM is a BAD idea.
The pagefile is not virtual memory, although much user level Microsoft documentation implies that it is. Virtual memory is broad topic and the pagefile is only a small part of it.

The pagefile is used as a place to offload rarely used data, thus leaving more RAM available for more important purposes. If the pagefile is in RAM this will mean moving data from one place in RAM to another place in RAM. In many cases there will be exact duplicates of data in two places in RAM. I call that wasteful and a serious waste of precious RAM.

Paging isn't exclusive to the pagefile. Paging involves executable files, DLL's, cached data files, etc., and this form of paging does not use the pagefile at all. Of all paging only about 10% will involve the pagefile. Placing the pagefile in RAM will do nothing for the other forms of paging, and thanks to the RAM lost to the pagefile, there be more of it.

Many people misinterpret the Task Manager display and see a large amount of "Available" memory and consider this free and unused memory. Not so. Most of this will actually be in use. In a modern OS having memory that is both in use and available is not a contradiction.

However much RAM you have you will better served by letting the system manage it as it wants to. It really does know best.

People who promote putting the pagefile in RAM are doing it out of ignorance of how the pagefile is used.

There is much more that could be said about this but I will stop now.
i like these questions when i learn new things.
given what has been said though. it really did seem like a boost in performance when i put the page file or "virtual memory" on a drive other than the system drive. i'm not sure why that would be.
SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
I remember that I used the suggestion to disable the virtual memory once.
But I constantly got the "low virtual memory" pop-up message.
I had a lot of Ram and wanted to force windows to use it but windows rejected the high speed Ram and wanted to use slow pagefile !
I was forced to re-enable that stupid pagefile !
Having 3 Gigabytes of ram and not using it to speed-up things!
SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
^^ same here ^^  If you have a LOT of memory and I'm not just talking 8G of ram or don't run many memory intensive operations at once you can improve things but you will never get rid of the pagefile.
Putting it on a SSD will speed things up but a ramdisk will actually slow things down. And yes putting the pagefile on a separate spindle does improve things as long as that drive is mainly a storage drive and not accessed a lot. If you have 3G or more you might want to stop windows from offloading its dll's and to keep them in memory (memory is faster than a hard disk).. at the moment I have 2.507G cached ram, and 2.454 available of my total 8G of Ram. (69% of physical memory) and the only thing other than perfmon is my sidebar gadgets accessing the pagefile.
SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
The article mentioning the /3GB switch above is correct but so many people misinterpret it. It has nothing to do with how much RAM you have or how it will be used. It also has nothing to do with the pagefile.

By default the 4GB virtual address space is split 2GB system - 2 GB per process. This is independent of RAM size. The switch changes this to 2 GB system - 3 GB per process. Only processes that explicitly indicate this will benefit and most are not. It also has some negative implications.

Do not use the switch unless you have applications that either require or will significantly benefit from it. Otherwise it will likely impair performance.

With or without the switch, RAM allocation between the system and applications is dynamically controlled by the memory manager. It has always been this way on the NT platform.
By now I learned that:
1) Pagefile can not be disabled completely.
2) Putting pagefile on Ram is not a good idea. (Is it possible at all? how? ! ! !)
3) Defragmenting the pagefile has a great effect on performance. (I knew it already and do it regularly)
4) Putting pagefile on separate HDD or SSD will improve performance greatly.

Alright.
Now let's get back to the authors question and ask a related question! (I ask for permission of the author!)
Why you say that putting a pagefile in another drive will increase performance?
I remember that once I used a software (I think it was "Tweak XP") and it shrunk my system drive and made a separate drive and put pagefile in it. The software said that after rebooting you'll see a performance increase. I had it for a while and never saw an increase (But may also decrease)!
What's the trick behind this?
kpax77, i don't mind you asking questions in my question. i believe in the Exchange part of this website. we all benefit by the questions people ask.
as far as the performance benefit. i think i saw benefits. however it was on older IDE computers. i have not tried this with SATA. and like WireDWolf mentioned, maybe it wouldn't work with SATA.
since it is releated to IDE which is going away, this could be a dated question, however, i am learning things about memory handling, so i guess it's still good to ask.
SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
wow! what a great response! thanks for all the comments.