Page 1 of 1

Windows Virtual Memory and Celestia

Posted: 11.02.2006, 16:37
by lacy
Forgive me if this has already been discussed, but I have been unable to find any posts on this subject.

Everytime I run Celestia, Windows gives me an error message claiming it is "running low on virtual memory". This occurs about after 10 minutes of running Celestia. If someone could help I would be grateful.

My system is as follows if that has any bearing:

Windows XP SP2
AMD 64 Athlon Processor at about 1.2 Ghz
512Kb Ram
100Gb Hard drive
ATI Radeon Xpress 200 Graphics Card.

Thanks for any info in advance.

L. Winston

Posted: 11.02.2006, 17:00
by Malenfant
First, make sure you're only running Celestia and no other programs in the background, they'll take up some of your RAM.

Second, you can increase your Virtual Memory (which is a kind of "RAM overflow" that Windows adds to the hard drive if it's not got enough RAM to handle programs) by going to Control Panel/System, clicking the Advanced Tab, and selecting the top "Performance" button. This should bring up another tabbed window with Visual Effects, Advanced, and Data Execution Prevention. That 'Advanced' tab should have a Virtual Memory button at the bottom. Click the 'Change' button there and pick a Custom size. The Windows default is 1.5 times the amount of RAM in your system, so your current Virtual Memory should be about 768 MB. Increase the maximum size to about 1.5GB and it should run a lot better (though your hard drive will be accessed more probably).

Third, you could just get more RAM :). Another 512MB should do it, but you'll have to check the innards of your computer to see if you have enough slots to physically add it.

Posted: 11.02.2006, 18:26
by selden
Don't forget that the amount of memory that Celestia needs is determined by how many Addons are installed and how many you've looked at. Celestia does not discard anything once it has been loaded for viewing. If you have many large Addons, you may need to specify a much larger maximum value than Malenfant suggests.

Posted: 11.02.2006, 20:42
by PlutonianEmpire
Malenfant wrote:First, make sure you're only running Celestia and no other programs in the background, they'll take up some of your RAM.

Second, you can increase your Virtual Memory (which is a kind of "RAM overflow" that Windows adds to the hard drive if it's not got enough RAM to handle programs) by going to Control Panel/System, clicking the Advanced Tab, and selecting the top "Performance" button. This should bring up another tabbed window with Visual Effects, Advanced, and Data Execution Prevention. That 'Advanced' tab should have a Virtual Memory button at the bottom. Click the 'Change' button there and pick a Custom size. The Windows default is 1.5 times the amount of RAM in your system, so your current Virtual Memory should be about 768 MB. Increase the maximum size to about 1.5GB and it should run a lot better (though your hard drive will be accessed more probably).

I increased mine to 2.6 gigabytes. would that work? :D

Posted: 11.02.2006, 23:42
by cartrite
I also got the same warning and..............low virtual memory

I would use caution when adjusting settings when you don't know what you are really doing. I lost an older hard drive a couple of days ago. I'm not sure why but I have been running some programs with very very large files. The seek head on a drive is the accillies heal. Virtual memory is a way to back up ram. When you make your virtual memory to large your hard drive is always working (swapping files). And if you over work your drive this could spell trouble.

cartrite

Posted: 12.02.2006, 00:14
by Malenfant
Here's the thing with virtual memory, as I understand it.

VM is essentially a holdover from the bad old days when most computers had less than 128MB of RAM. This just wasn't enough to run Windows and all the other stuff, so Virtual Memory was created to 'extend' the RAM. Nowadays though most people have 512 MB or more, and VM is just not necessary anymore.

Ideally windows wants to run all its processes in the RAM, but sometimes you're doing too much for this to be the case. So it sets up a 'Virtual Memory' - the pagefile.sys file - usually in the root C:/ directory of the hard drive. If you Ctrl-Alt-Del in XP or win2000 and look at the processes tab (do older versions have this too?), you can see how much memory each app is using.

If you have about 1 GB of RAM, then MOST of the time - if you're not using highly graphics intensive apps or games - you don't need Virtual Memory, and you can actually just turn it off. Right now I've got World of Warcraft, Firefox, Explorer, ICQ, NOD32, and svchost.exe (a windows network service, I believe) running right now, and along with all the other little 1-2 MB services they take up about 400MB of RAM (270 of which is WoW). With my 1GB of RAM - even with a memory hog like WoW running - I don't need virtual memory at all.

Basically, when you're running Celestia have the processes window open and keep an eye on the memory it uses up, along with all the other stuff there. If it's looking like all of that takes up more room than you have in your RAM then you'll need some extra Virtual Memory. As Cartrite says, this means you'll be accessing your hard disk a lot though - but the big problem with that really is that accessing the HDD is much slower than accessing RAM, so it'll slow your computer down from its ideal speed if you have to access the VM a lot. Plus of course it takes up space on your HDD, but nowadays that's becoming less of an issue.

I *think* that Windows XP at least auto-activates VM if it isn't already activated, if it actually finds that it needs the extra space. But again, if you're unsure about any of this, don't tinker with it!

(as an aside, I think this also means that adding more RAM won't actually help you at all unless your existing RAM is small enough to require extra Virtual Memory on the HDD. The extra RAM would shunt all that back onto the RAM where it belongs, but if you don't have this problem then all you're gaining is the ability to run more memory-hog programs at once)

EDIT: Also, most hard drives are pretty reliable nowadays. I suspect cartrite lost his old HDD because it was old, not because of anything to do with VM issues. Hard disks are made to be used a lot, after all ;). The trick is to get a disk from a reliable hard disk manufacturer (eg Samsung, Seagate), read some reviews in computer magazines if you can first. That said, the other day we had a brand new 200GB hard disk that failed after only about two days, so it's a bit of a crap shoot really :).

Posted: 12.02.2006, 00:20
by Malenfant
PlutonianEmpire wrote:I increased mine to 2.6 gigabytes. would that work? :D


Probably too much, that's taking up 2.6GB on your hard disk (nearly 5% of it). 1.5GB should be ok I think, depends on how much memory your Celestia is taking up though.

Posted: 12.02.2006, 20:42
by PlutonianEmpire
Malenfant wrote:
PlutonianEmpire wrote:I increased mine to 2.6 gigabytes. would that work? :D

Probably too much, that's taking up 2.6GB on your hard disk (nearly 5% of it). 1.5GB should be ok I think, depends on how much memory your Celestia is taking up though.

It's not just for celestia. I have "The Sims 2", "Simcity 4", and "Microsoft Flight Simulator 2004". That's why I did it, so I could run these games for longer periods of time with out that annoying "low on virtual memory" message. :)