How to move the Firefox or Chrome cache to a RAM disk and speed up surfing by 20

Started by Lazybones, April 04, 2011, 11:25:07 AM

Previous topic - Next topic

Lazybones

http://downloadsquad.switched.com/2010/11/10/how-to-move-the-firefox-or-chrome-cache-to-a-ram-disk-and-speed/

I just did this, and so far it seem that FireFox 4.0 with a ram disk KILLs Chrome 10.0 with a ram disk. I mean cached pages you go back to in FF open instantly in most cases, chrome still spins for a noticeable second or two.

To be far there could be plugins slowing them both down in different ways, however I run similar plugins on both.

Edit: note there is a cost to start-up and shutdown time for loading and saving the ram-disk to the hard-drive.. However it is dependent on how BIG you make the ram disk. I think the immediate performance boost to things like your web-browser are worth it however.

Thorin

That looks kinda cool!  Apparently Firefox 4 already has a RAM-disk-based cache of some sort, according to the comments on that thread.
Prayin' for a 20!

gcc thorin.c -pedantic -o Thorin
compile successful

Darren Dirt

Quote from: Thorin on April 04, 2011, 12:45:09 PM
Apparently Firefox 4 already has a RAM-disk-based cache of some sort, according to the comments on that thread.

to quote that comment...
There's no need for the extra software in Firefox. Everything is there in about.config.
1) Set 'browser.cache.disk.enable' to false
2) Set 'browser.cache.memory.enable' to true.
3) Create 'browser.cache.memory.capacity' if it doesn't exist.
4) Set 'browser.cache.memory.capacity' to the desired size of the RAM cache in kilobytes.
_____________________

Strive for progress. Not perfection.
_____________________

Lazybones

Although you can turn DISK Cache OFF, the performance is not the same.

reading the docs on browser.cache.memory.capacity it doesn't do what you think it does.

I tested both methods, the ram disk is incredibly fast, where as disabling disk cache and relying on FF memory cache was not.. There may be a way to tweak it however I suspect that the advantage of a LARGE persistent ram cache is still there.

Lazybones

Just an FYI, I just setup my new computer, it has the same amount of RAM and same hard drive as my work laptop but the CPU and bus should blow my work laptop away.. I immediately noticed the IE and Firefox where slower on my new computer, so I setup the RAM disk on it.

YES, this tweak for browsing is almost a night and day difference, unless maybe if you have a crazy fast SSD drive already.