ramdisk
storageLinux/Unix
The ramdisk command is one of the most frequently used commands in Linux/Unix-like operating systems. ramdisk Create and manage RAM-based virtual disk drives
Quick Reference
Command Name:
ramdisk
Category:
storage
Platform:
Linux/Unix
Basic Usage:
ramdisk [options] [arguments]
Common Use Cases
Syntax
ramdisk [options] [size]
Options
Option | Description |
---|---|
-m, --mount=PATH |
Mount point for the RAM disk |
-f, --format=TYPE |
Filesystem type to use (ext4, ext3, ext2, xfs, etc.) |
-u, --unmount=PATH |
Unmount and remove a RAM disk at the specified path |
-l, --list |
List all active RAM disks |
-p, --permissions=MODE |
Set permissions for the mount point (octal mode) |
-o, --owner=USER |
Set owner for the mount point |
-g, --group=GROUP |
Set group for the mount point |
-s, --stats |
Show RAM disk statistics |
-b, --backup=FILE |
Use backup file for persistence |
-h, --help |
Display help information |
-v, --version |
Display version information |
Examples
How to Use These Examples
The examples below show common ways to use the ramdisk
command. Try them in your terminal to see the results. You can copy any example by clicking on the code block.
# Basic Examples Basic
sudo ramdisk 512M