O'Reilly logo

LPI Linux Certification in a Nutshell, 3rd Edition by James Stanger, Bruno Gomes Pessanha, Stephen Addison Schneiter, Adam Haeder

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Name

mount

Syntax

mount [options] device
mount [options] directory
mount [options] device directory

Description

Used to mount filesystems into the filesystem hierarchy. The first and second forms consult /etc/fstab and mount the filesystem located on device or intended to be attached to directory, respectively. In both cases, information necessary to complete the mount operation is taken from /etc/fstab. The third form is independent of /etc/fstab and mounts the filesystem on device at mount point directory.

The mount command accepts two kinds of options: command-line and mount. The command-line options provide general direction for the mount command. The mount options are used to specify additional information about the device being mounted.

Command-line options

-a

Mounts all of the partitions specified in /etc/fstab, except those with the noauto option.

-h

Displays help on the mount command.

-o mount_options

Specifies mount options on the command line.

-r

Mounts the filesystem as read-only.

-t fstype

Specifies that the filesystem to be mounted is of type fstype. This option is typically used interactively when no entry for the mount exists in /etc/fstab.

-v

Sets verbose mode.

-w

Mounts the filesystem in read/write mode.

Mount options

A number of parameters are available as options for mounting filesystems. These options may be specified in /etc/fstab or as arguments of the -o command-line mount argument. These options modify the way mount configures the mounted filesystem. Some of the options can provide ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required