mirror of
https://github.com/ivuorinen/cheatsheet-tldr.git
synced 2026-02-24 06:51:59 +00:00
Update cheatsheets
This commit is contained in:
12
tldr/mount
12
tldr/mount
@@ -14,23 +14,23 @@ source: https://github.com/tldr-pages/tldr.git
|
||||
|
||||
- Mount a device to a directory:
|
||||
|
||||
`mount -t {{filesystem_type}} {{path/to/device_file}} {{path/to/target_directory}}`
|
||||
`mount {{[-t|--types]}} {{filesystem_type}} {{path/to/device_file}} {{path/to/target_directory}}`
|
||||
|
||||
- Create a specific directory if it does not exist and mount a device to it:
|
||||
|
||||
`mount --mkdir {{path/to/device_file}} {{path/to/target_directory}}`
|
||||
`mount {{[-m|--mkdir]}} {{path/to/device_file}} {{path/to/target_directory}}`
|
||||
|
||||
- Mount a device to a directory for a specific user:
|
||||
|
||||
`mount -o uid={{user_id}},gid={{group_id}} {{path/to/device_file}} {{path/to/target_directory}}`
|
||||
`mount {{[-o|--options]}} uid={{user_id}},gid={{group_id}} {{path/to/device_file}} {{path/to/target_directory}}`
|
||||
|
||||
- Mount a CD-ROM device (with the filetype ISO9660) to `/cdrom` (readonly):
|
||||
|
||||
`mount -t {{iso9660}} -o ro {{/dev/cdrom}} {{/cdrom}}`
|
||||
`mount {{[-t|--types]}} {{iso9660}} {{[-o|--options]}} ro {{/dev/cdrom}} {{/cdrom}}`
|
||||
|
||||
- Mount all the filesystem defined in `/etc/fstab`:
|
||||
|
||||
`mount -a`
|
||||
`mount {{[-a|--all]}}`
|
||||
|
||||
- Mount a specific filesystem described in `/etc/fstab` (e.g. `/dev/sda1 /my_drive ext2 defaults 0 2`):
|
||||
|
||||
@@ -38,4 +38,4 @@ source: https://github.com/tldr-pages/tldr.git
|
||||
|
||||
- Mount a directory to another directory:
|
||||
|
||||
`mount --bind {{path/to/old_dir}} {{path/to/new_dir}}`
|
||||
`mount {{[-B|--bind]}} {{path/to/old_dir}} {{path/to/new_dir}}`
|
||||
|
||||
Reference in New Issue
Block a user