How to Create Ramdisks in Linux
- 1). Connect to your Linux computer and start a terminal.
- 2). Type "su", press "Enter," enter your administrator password and press "Enter." If you are on a Debian base distribution such as Ubuntu, add "sudo" before each command and enter your administrator password after pressing "Enter."
- 3). Type "mkfs -q /dev/ram1 XXX". Replace "XXX" with the value for the size of the ramdisk you want to create. Press "Enter."
- 4). Type "mkdir -p /mnt/ramcache". Press "Enter." Replace the name "ramcache" with any name that fits your naming standards.
- 5). Type "mount /dev/ram1 /mnt/ramcache".
- 6). Type "df -H | grep ramcache" to check that the ramdisk is available.
Source...