Virtual Memory

Posted by: visuvius

Virtual Memory - 03/09/2002 18:16

What is virtual memory and why is XP telling me that i don't have enough of it. I had just just down Battlefield 1942, and there was nothing else open, except for antivirus. I've got 256mb of pc2700.
Posted by: tfabris

Re: Virtual Memory - 03/09/2002 19:02

Virtual memory is another word for disk space.
Posted by: Laura

Re: Virtual Memory - 03/09/2002 19:27

Under Win98 you can set this under control panel/system/performance. I'm not sure under XP where it would be. It always warns you if you change it yourself instead of letting Windows control it.
Posted by: Shonky

Re: Virtual Memory - 04/09/2002 01:36

Virtual memory is another word for disk space.

No offence, but from the FAQ master I think that's a pretty average answer.

Virtual memory allows a program to use more memory than is physically available. Physical memory is actual RAM. Basically virtual memory is a special section of hard drive space (file or partition). When you run a lot of programs the ones you aren't using get "swapped" out to disk temporarily to free up some RAM for programs the you are currently using. When you go back to these swapped out programs, they are loaded back from disk to RAM (possibly other programs get swapped out then).

Un*x type OSes generally have dedicated partitions for this swap space while Micro$oft OSes generally have one large file on the main drive (although it can be multiple files spread across drives). XP for example does have an upper limit on the amount of swapfile space you can have. In the case of my 512Mb machine it has defaulted to a minimum of 384 and a max of 768Mb. A standard x86 PC is limited to a 4Gb virtual address space.

If XP is telling you you have run out of virtual memory you have probably run out of either swap space or disk space although I'd bet that message would come up in the case you were severely lacking in physical RAM too. Eventhough you have closed everything, I'd still recommend a reboot. You'd be amazed what sort things a reboot can fix.

Just because you have enough disk space doesn't mean you can run everything though. If you don't have enough physical RAM and try to do too much, you will get "thrashing" where the OS tries to swap stuff frantically to and from the disk so it can run all the processes. You can't run processes from virtual memory - the process must be swapped back to RAM first.

I would have thought BF1942 would have run on 256Mb but I heard from someone here it's a pretty intensive program and requires a fair amount of CPU/GPU (and possibly RAM too). In the case of a game you probably don't want to be relying on virtual memory at all.

My suggestion is try the reboot with as little as possible running in your system tray (download managers, ICQ, IM etc). Worst case look for another 256Mb stick of RAM. I found 512 over 256 helped quite a bit on XP although I run quite a few apps at once. However I did achieve similar levels of multitasking success on old PC with Win98 and only 192Mb

HTH
Posted by: oliver

Re: Virtual Memory - 04/09/2002 02:27

I've noticed that Battlefield 1942 uses around 250-280mb of ram. I couldn't believe it when i saw it.
Posted by: davec

Re: Virtual Memory - 04/09/2002 06:57

Well that's no surpirse with the number of kills you were racking up last night Oliver...
We had 4 of us in there last night till 2AM Central time, it was fun, but we need more in there to offset Oliver's domination...
BTW I use the name Senko when I'm in the battlefield, just so y'all know who you're killing...
Posted by: tfabris

Re: Virtual Memory - 04/09/2002 11:58

No offence, but from the FAQ master I think that's a pretty average answer.

Good point. But I was just trying to tell him why that particular game software was complaining. In his particular case, I was pretty sure that the game was merely complaining about a lack of disk space (or possibly the game forcing the OS to complain). I didn't figure an extended discussion on the subject was needed, just a quick answer so he could get the game running.
Posted by: johnmcd3

Re: Virtual Memory - 04/09/2002 12:28

still, after a point, windows won't resize its swap space past some maximum value that it's determined for your system. he could have 100 GB free and still get that answer. so going out and buying a bigger hard drive is almost certainly not going to help.

he really needs more ram, but in the short term he just needs to go to control panel->system->advanced->performance options->advanced->change and put in some larger values. if he only has 256 mb of ram i'd say 512-768 might be a good range to put in, but it depends on his system.

john
Posted by: visuvius

Re: Virtual Memory - 04/09/2002 12:37

Thanks for the reply. I fully understand now.

Man, i love this board, just a wealth of knowledge...

btw. seriously guys, BF1942, we need to schedule something.
Posted by: tfabris

Re: Virtual Memory - 04/09/2002 12:39

Assuming it's really Windows doing the complaining. Sometimes these games do their own memory management (creating their own temp files) and will put up their own error boxes complaining about virtual memory. I was working from that assumption first.