3.2. Mounting a File System
Before you can mount a GFS2 file system, the file system must exist (refer to
Section 3.1, “Making a File System”), the volume where the file system exists must be activated, and the supporting clustering and locking systems must be started (refer to
Configuring and Managing a Red Hat Cluster). After those requirements have been met, you can mount the GFS2 file system as you would any Linux file system.
Mounting Without ACL Manipulation
mount BlockDevice MountPoint
Mounting With ACL Manipulation
mount -o acl BlockDevice MountPoint
-o acl
GFS2-specific option to allow manipulating file ACLs.
BlockDevice
Specifies the block device where the GFS2 file system resides.
MountPoint
Specifies the directory where the GFS2 file system should be mounted.
In this example, the GFS2 file system on /dev/vg01/lvol0 is mounted on the /mygfs2 directory.
mount /dev/vg01/lvol0 /mygfs2
mount BlockDevice MountPoint -o option
The
-o option argument consists of GFS2-specific options (refer to
Table 3.2, “GFS2-Specific Mount Options”) or acceptable standard Linux
mount -o options, or a combination of both. Multiple
option parameters are separated by a comma and no spaces.
Note
The mount command is a Linux system command. In addition to using GFS2-specific options described in this section, you can use other, standard, mount command options (for example, -r). For information about other Linux mount command options, see the Linux mount man page.
|
Option
|
Description
|
|---|
acl
|
Allows manipulating file ACLs. If a file system is mounted without the acl mount option, users are allowed to view ACLs (with getfacl), but are not allowed to set them (with setfacl).
|
data=[ordered|writeback]
|
When data=ordered is set, the user data modified by a transaction is flushed to the disk before the transaction is commited to disk. This should prevent the user from seeing uninitialized blocks in a file after a crash. When data=writeback mode is set, the user data is written to the disk at any time after it is dirtied; this does not provide the same consistency guarantee as ordered mode, but it should be slightly faster for some workloads. The default value is ordered mode.
|
ignore_local_fs | | Caution: This option should not be used when GFS2 file systems are shared. |
|
Forces GFS2 to treat the file system as a multihost file system. By default, using lock_nolock automatically turns on the localcaching and localflocks flags.
|
localcaching | | Caution: This option should not be used when GFS2 file systems are shared. |
|
Tells GFS2 that it is running as a local file system. GFS2 can then turn on selected optimization capabilities that are not available when running in cluster mode. The localcaching flag is automatically turned on by lock_nolock.
|
localflocks | | Caution: This option should not be used when GFS2 file systems are shared. |
|
Tells GFS2 to let the VFS (virtual file system) layer do all flock and fcntl. The localflocks flag is automatically turned on by lock_nolock.
|
lockproto=LockModuleName
|
Allows the user to specify which locking protocol to use with the file system. If LockModuleName is not specified, the locking protocol name is read from the file system superblock.
|
locktable=LockTableName
|
Allows the user to specify which locking table to use with the file system.
|
quota=[off/account/on]
|
Turns quotas on or off for a file system. Setting the quotas to be in the account state causes the per UID/GID usage statistics to be correctly maintained by the file system; limit and warn values are ignored. The default value is off.
|
upgrade
|
Upgrade the on-disk format of the file system so that it can be used by newer versions of GFS2.
|
Table 3.2. GFS2-Specific Mount Options