Ai Dreams Forum

Games => Gaming => Topic started by: GT40 on December 04, 2008, 07:35:38 pm

Title: Load the SL cache in RAM?
Post by: GT40 on December 04, 2008, 07:35:38 pm

Hi everyone! :)

I live my Second Life with an old (5 years!) Pentium IV 2.4 GHz (with XP SP3), a 512 MB RAM only and a 1024 MB virtual memory.

I noticed with the Task Manager that, with my SL adjustments, I never use more than 800 MB of the virtual memory. So I only need 0.5 + 0.8 = 1.3 GB for the total memory.

To reduce accesses to the HD, I plan to increase the RAM to 2 GB (and of course, to get rid of the virtual memory).

So, after doing that, I will still have 2 - 1.3 = 0.7 GB free in the RAM, when running SL.

Now my question: wondering if it's possible to dedicate a part of that area to the SL cache, for minimizing accesses to the HD, during SL sessions. I mean, is it possible to load the cache in the RAM, as I was doing with DOS 6 and Windows 3.1, 15 years ago? ;D

An idea? Thanks in advance.

Title: Re: Load the SL cache in RAM?
Post by: Maviarab on December 04, 2008, 09:45:48 pm
No idea GT, any kind of forum for Sl or faq type thingy you can access?

You can't be the only person to have thought about this?
Title: Re: Load the SL cache in RAM?
Post by: GT40 on December 05, 2008, 10:57:04 am

Thanks Mav. I unsuccessfuly googled and you're right, maybe on SL forums. But it's finally a general question about computers.

PCs from the last century were easier to understand. A config.sys, an autoexec.bat and the memory was under control. Now Windows is the chief and the user just may choose the size of the virtual memory. ;D

Title: Re: Load the SL cache in RAM?
Post by: GT40 on December 05, 2008, 12:20:14 pm

Just googled again (sl load cache ram). Not the only one with that question.

You know what? The page in pole position is... the page you're reading now! ;D

Title: Re: Load the SL cache in RAM?
Post by: Maviarab on December 05, 2008, 12:29:36 pm
Lol really?

Well, when you figure it out be sure to add it here so others know :)
Title: Re: Load the SL cache in RAM?
Post by: GT40 on January 24, 2009, 07:24:53 pm

Oh, by the way, the good question was: "How to create a Ramdisk?". SL or not SL. ;D

A lot of answers after googling, like this:

http://www.mydigitallife.info/2007/05/27/free-ramdisk-for-windows-vista-xp-2000-and-2003-server/

Title: Re: Load the SL cache in RAM?
Post by: GT40 on February 02, 2009, 03:23:37 pm

Hello happy taxpayers! You remember my question: "Is it possible to load the SL cache in RAM?". It's time to put a final point to the topic: the answer is "Yes"! :)

As written above, I've finally upgraded my P4 2.4, increasing the RAM from 512 MB to 2 GB. And got rid of the swap file (no virtual memory). Just with that, SL (and not only SL, lol) was running really better. Then I've tried this program:

http://www.mydigitallife.info/2007/05/27/free-ramdisk-for-windows-vista-xp-2000-and-2003-server/

Free and very easy to use. Before starting SL, you launch the program and create a place in RAM for the SL cache. That new cache must obviously be declared in SL settings. No need to reserve more than 400 or 500 MB for it (seems useless).

Now SL is really more pleasant to use (I didn't say perfect, lol). The hard drive is very rarely working. Before, sometimes the screen was frozen during 10 or 20 sec, when the disk was doing its job! Of course, after turning the PC off, the cache is deleted but it's not a problem with a fast connection. And finally a good thing.

Now I've some little experiments to do:

- maybe try other ramdisk programs
- create a batch file (if possible) to automatize the process
- load the Temp & Tmp (and why not, Temporary Internet Files) folders in RAM too

But all that is another story... :)

Title: Re: Load the SL cache in RAM?
Post by: Freddy on February 02, 2009, 04:31:09 pm
Sounds good GT40, maybe you could do a step-by-step guide for anyone else wanting to try this.  Feel free to put it in another thread or I can make a complete article of it if you wish.  Have fun!
Title: Re: Load the SL cache in RAM?
Post by: GT40 on February 02, 2009, 10:07:49 pm

Many thanks, Freddy. I only wanted to verify if my idea could work. Just a specific use of a ramdisk. Nothing new.

A lot of ramdisk softwares on the web. Sophisticated or not. Free or not. Not easy to write a generic tutorial, lol. But I guess what I wrote above is enough for most people who want to try that.:)

Title: Re: Load the SL cache in RAM?
Post by: Art on February 05, 2009, 12:38:47 am
Has anyone thought of trying to use a thumbdrive, flashdrive, etc. as a ramdrive as a lot of them can be had for cheap (bought a 4 gig Data Traveler w/Kingston memory for $10.00 at Big Lots [Discount store])?  It could be like doing an inexpensive memory upgrade on / for an older computer.

Just a thought....
Title: Re: Load the SL cache in RAM?
Post by: GT40 on February 05, 2009, 12:46:15 pm

Really GREAT idea, Art!! 8)

Starting to try it with a 1GB USB storage key, after reading your post. It works fine and

- the cache is saved after the computer has been turned off
- the full RAM is always available
- the access to the cache (of course slower than to the RAM) seems good enough

Just two little things to add:

- About the cache size, SL seems having some difficulties to fill more than 250 MB. Even if, when the cache is on the hard drive, it can grow bigger because of the previous sessions. So a 250 MB cache seems sufficient.

- If you use a ramdisk, when you turn your computer off and then on, the ramdisk is still here. Of course empty, but no need to recreate it everytime you use SL.

Thanks again. :)

Title: Re: Load the SL cache in RAM?
Post by: Art on February 06, 2009, 12:19:02 am
Very cool! Glad it seems to be working for you!! ;D
Title: Re: Load the SL cache in RAM?
Post by: GT40 on February 06, 2009, 12:26:36 pm

Just a little bemol about the USB key. If you forget to unplug it before turning your computer off, the cache becomes corrupted.

Tired of plugging/unplugging, so I finally came back to a permanent 256 MB ramdisk, dedicated the cache. Very very nice SL now (I mean, not too bad, lol), even if it eats 1/8 of the RAM. But of course, you can delete the ramdisk when you want, if you need the full memory for a specific use.

By the way 256 MB, it was the RAM size of my computer, when it was brand new. ;D

Title: Re: Load the SL cache in RAM?
Post by: Art on February 07, 2009, 03:37:21 pm
GT,
Wonder why there seems to be a 256 meg limitation? There are huge flash/thumb drives available so it might be a constraint within the program....

Hmmm....Well you could always try using an external hard drive, more memory or both!

Title: Re: Load the SL cache in RAM?
Post by: GT40 on February 08, 2009, 05:28:09 pm

You're right, Art, there is no rational reason to limit the SL cache to 256 MB. But...

1- as I wrote above, my SL is unable to significately fill a bigger cache, on a ramdrive or an USB key (maybe because of my "modest" graphics settings?).

2- in wikis and other forums, we can often read recommendations like this:

"I recommend a reasonable setting around 250MB. You can set it higher, but then I'd recommend purging the cache occasionally to keep it working efficiently. Higher cache sizes tend to slowly degrade performance over time. If you set it too low, then you're always downloading things over and over again. 250 seems like a reasonable compromise in size and performance."

3- SL (the program) seems unable to correctly manage its own cache. Personally noticed before reading many posts about that, lol. And easy to verify. Go to a place in SL. Wait until all the elements are downloaded. Then go elsewhere and do the same thing. Then go back to your previous place. Sometimes (I mean, very often), SL must reload all the elements from its site. Elements which are supposed to be in the cache! Even with a big cache.

That's why now, I don't change anything anymore to my SL. According to the old well-known theory... ;D


Title: Re: Load the SL cache in RAM?
Post by: Art on February 08, 2009, 11:37:58 pm
OK...it just occurred to me that what we're talking about here is a CACHE program...one that basically stores enough data to be able to re-read the same data at a later time / date without wasting a lot of time.

It stands to reason that if a cache were allowed to become extremely large then the entire purpose of the cache would be defeated for it would take far too long to locate then extract the much needed information / data. This would in turn cause the program to slow down on the user's end.

I think when they said to let the program manage it's own memory cache, it is most likely the best thing to do.

We're trying to wring a bit more effectiveness from a system that's already doing a pretty fair job.

"Sorry Captain, but I'm givin' er all I've got" - Scotty
 :D
Title: Re: Load the SL cache in RAM?
Post by: GT40 on February 09, 2009, 12:20:56 pm

Lol, Art. And if the secret of a smart SL were having just a brand new PC, with a powerful CPU, a lot of RAM, a fast hard drive and a good graphics card? Wondering... ;D

Title: Re: Load the SL cache in RAM?
Post by: Art on February 10, 2009, 12:29:40 am
Well GT, my friend, unfortunately, it is often true with a lot of things in life...

Size does matter!! :o
Title: Re: Load the SL cache in RAM?
Post by: GT40 on February 10, 2009, 12:03:07 pm

 ;D ;D ;D

 :(

Title: Re: Load the SL cache in RAM?
Post by: GT40 on May 11, 2009, 12:10:13 pm

EPILOGUE - Not a good idea. Finally...

I started my little experiments with the SL cache because... I like to do little experiments. Also because I always thought that the cache was not effective enough:

http://jira.secondlife.com/browse/VWR-9509

And finally, after testing different configurations (cache in RAM or on HD, 250 to 500 MB), I went back to a classic cache. Just a few figures:

When I start SL and arrive on the welcome/logging page, SL uses 85 MB in RAM. Then, after rezzing, the used RAM increases and increases during a SL session. With my low Preference Settings, I always need less than 650 MB. It means (IMHO) that SL stores all the needed things (loaded from the cache or from the internet) in this part of the RAM.

I also noticed that a cache in RAM loads less datas than a cache on HD, in the same conditions. A cache in RAM seems useless.

And after testing a lot, I finally found no real difference between the loading speeds, with always the same anomalies explained above. A cache in RAM avoids the hard drive to work, but a cache on hard drive is more comfortable.

But it was worth to try. ;D