this post was submitted on 19 Oct 2025
56 points (98.3% liked)
retrocomputing
5625 readers
64 users here now
Discussions on vintage and retrocomputing
founded 2 years ago
MODERATORS
you are viewing a single comment's thread
view the rest of the comments
view the rest of the comments
Just put
tmpfs /tmp tmpfs defaults,size=4G 0 0in /etc/fstab then reboot and /tmp will be a RAM drive. Set size to whatever you want the maximum size to be.This is what I do. But the thing is, I can only have so much RAM on my motherboard.
Alternatively, I've been using zram to better utilize the space, but the original issue remains.
A lot of Linux distros do this by default. Alternatively you can use /dev/shm when you need a RAM disk, since it's guaranteed to always be a RAM disk (whereas /tmp may or may not be).
The actual purpose of /dev/shm is shared memory (storing stuff in memory that's shared across multiple processes) but I see it used as a generic RAM disk all the time.