I have more than enough ram in my computer (8GB), which hardly gets used. In the most cases my desktop and apps use up in 2-3GBs out of it, on the other hand I do not have an SSD.

My system is 64bit Debian Wheezy.

I wonder if there is any framework which copy regularly used files like thunderbird, firefox, openoffice, vlc, pidgin to a ramdisk at every start to speed up access.

This is obviously doable by with an init shellscript after each boot then have symlinks setup for those files later on but maybe there is a complete solution to do this already...


Are there any optimizations for the linux kernel (3.14) which can take advantage of large amount of memory better than a stock kernel? If so what are those?


In this case disabling swap partition completely is a good idea right?


migrated from serverfault.com Oct 3 '14 at 12:10

This question came from our site for system and network administrators.

  • Buying an SSD is much easier. And they're pretty cheap now. – Michael Hampton Oct 3 '14 at 15:41

any framework which copy regularly used files

Simply cat'ing them into /dev/null will populate the VFS cache. But this degrades even in the absence of any further I/O or memory demand. If it were me, I might consider creating a tmpfs then creating a unionfs with the storage device filesystem containing the content to cache - rather than messing around with symlinks (but you still need to populate it.

A much simpler solution would be to use the tmpfs as a bcache device. (but make sure you destroy and rebuild the bcache during the startup sequence).

Question 2: there are things you can do to tune the VFS, but I suspect they won't have much impact.

Qusetion 3: Absolutely not - you'll get best usage out of any caching if you preserve it between power cycles - i.e. using hibernate-to-disk rather than a shutdown/restart - and this (normally) uses swap.


There are different readahead programs for Linux, which pre-fetch disk memory. They are called e.g. readahead-fedora and preload.

The was also systemd-readahead for systemd-based init systems, but it was removed again in more recent versions.


In this case disabling swap partition completely is a good idea right?

Yes, you may move your swap from HDD/SDD to RAM. The latest Linux kernels include ZRAM module inside, so you may use your swap in RAM. That will give you much better speed of swapping operations, but will in some times increase CPU load.

You may read about it on https://wiki.debian.org/ZRam

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy