On an embedded system, we have a a 512Kb static ram on a character device /dev/mem.

We're currently using it by memory-mapping the file directly in our application with a mmap.

I would like to mount it as a file-system to enable the following use-cases:

  • manage stored data with system utilities
  • fast and reliable storage for important data (eg. rsyslog disk queue)
  • buffer data to be written on flash device

Would it make sense to mount it as a file-system?
How could I do it? Maybe using a loop device to make the file a block device?
What file-system should I consider?

  • Pardon me for being thick, but does the kernel maintain page descriptors for this ram? If so, then pramfs is possibly the solution to your problem, pramfs.sourceforge.net Commented Oct 17, 2016 at 9:53
  • Sorry, I meant if not, but I wrote if so instead, exactly the opposite... Commented Oct 17, 2016 at 12:20
  • Thank you @MariusMatutiae: pramfs seems exactly what I need. I wont be able to test it as I'm tied to an ancient sdk, but I'll consider it for future projects. Please post an answer and I'll mark it as accepted. Commented Oct 18, 2016 at 9:20

1 Answer 1


I would consider pramfs: the developers state:

Many embedded systems have a block of non-volatile RAM separate from normal system memory, i.e. of which the kernel maintains no memory page descriptors. For such systems it would be beneficial to mount a read/write filesystem over this "I/O memory", for storing frequently accessed data that must survive system reboots and power cycles or volatile data avoiding to write on a disk or flash. An example usage might be system logs under /var/log or debug information of a flight-recorder.

It has several advantages over traditional filesystems, is lightweight, and supports extended attributes, ACLs, security labels and freezing.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .