Last active
July 21, 2023 20:07
-
-
Save st3b1t/e8e1b0efaf3ebabf72d9da3a12a81d88 to your computer and use it in GitHub Desktop.
create ramdisk on a Linux distro
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
#path of the ramdisk | |
PATH=/media/ram | |
#automount ad startup | |
AUTO=",auto" | |
#disk size | |
SIZE=2G | |
sudo mkdir -p /media/ram | |
sudo echo "tmpfs $PATH tmpfs size=$SIZE,rw$AUTO,user,noatime,x-gvfs-show 0 0" >> /etc/fstab | |
sudo mount -a |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment