Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I thought I've read somewhere that you can take a slice of RAM and turn it into a partition with a FS on it and everything. What is the relevant terminology and the tools to accomplish this?

I need this to seemlessly (from the POV of an application) optimize the access to some files.

share|improve this question
up vote 2 down vote accepted

That is true. There are several options for that, depending on your needs.

The two filesystems types to do that are ramfs and tmpfs. See this page for information on their differences and how to use them.

Beware though (if that is not obvious) that data are such partitions cannot be persistent. On reboot, all data is lost.

share|improve this answer
"if that is not obvious" good one. I used "volatile" in the title, dammit! :D +1 and accepted. Thanks :-) – Flavius A May 27 '11 at 7:21
@Flavius A - also note that most systems already have a tmpfs mounted at /dev/shm (in the linked article too), and set to a size of 50% of the system RAM. – JimB May 27 '11 at 14:39
Great point @JimB. /dev/shm is indeed very practical for volatile data to be stored in RAM. – ℝaphink May 27 '11 at 14:43

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.