Best use of a RAM disk?

Just wondering, have you ever made anything useful with a RAM disk in production? I wonder if the performance benefit they afford possibly outweighs their temporary nature in a specific circumstance.

I've only ever used one once, and it wasn't for performance. It was when I needed some writable disk space on a server showing hard drive errors – it gave just enough space for me to install the 3ware RAID utility to identify the dodgy disk.

How have you used a RAM disk in production?


Solution 1:

I setup a ramdisk on my mailgateway.
There clamav has a 256MB ramdisk for scanning attachements.

It runs since almost three years, I think its ok :)

Solution 2:

Absolutely.

Diskless nodes that have their root FS on a read-only NFS share and strategically mounted tmpfs filesystems to allow writing to various parts of the filesystem hierarchy (eg: /tmp).