Bind Mounts And File System Mount Order - Red Hat ENTERPRISE LINUX 5 - GLOBAL FILE SYSTEM 2 Manual

Hide thumbs Also See for ENTERPRISE LINUX 5 - GLOBAL FILE SYSTEM 2:
Table of Contents

Advertisement

Chapter 3. Managing GFS2
Alternately, you can use the following entry in the /etc/fstab file.
/usr/1386-bin
A bind mount can provide greater flexibility than a Context-Dependent Path Name, since you can
use this feature to mount different directories according to any criteria you define (such as the value
of %fill for the file system). Context-Dependent Path Names are more limited in what they can
encompass. Note, however, that you will need to write your own script to mount according to a criteria
such as the value of %fill.
Warning
When you mount a file system with the bind option and the original file system was
mounted rw, the new file system will also be mounted rw even if you use the ro flag; the
ro flag is silently ignored. In this case, the new file system might be marked as ro in the /
proc/mounts directory, which may be misleading.

3.13. Bind Mounts and File System Mount Order

When you use the bind option of the mount command, you must be sure that the file systems are
mounted in the correct order. In the following example, the /var/log directory must be mounted
before executing the bind mount on the /tmp directory:
# mount --bind /var/log /tmp
The ordering of file system mounts is determined as follows:
• In general, file system mount order is determined by the order in which the file systems appear in
the fstab file. The exceptions to this ordering are file systems mounted with the _netdev flag or
filesystems that have their own init scripts.
• A file system with its own init script is mounted later in the initialization process, after the file
systems in the fstab file.
• File systems mounted with the _netdev flag are mounted when the network has been enabled on
the system.
If your configuration requires that you create a bind mount on which to mount a GFS2 file system, you
can order your fstab file as follows:
1. Mount local filesystems that are required for the bind mount.
2. Bind mount the directory on which to mount the GFS2 file system.
3. Mount the GFS2 file system.
If your configuration requires that you bind mount a local directory or file system onto a GFS2 file
system, listing the file systems in the correct order in the fstab file will not mount the file systems
correctly since the GFS2 file system will not be mounted until the GFS2 init script is run. In this
case, you should write an init script to execute the bind mount so that the bind mount will not take
place until after the GFS2 file system is mounted.
30
/bin
none
bind
0 0

Advertisement

Table of Contents
loading

This manual is also suitable for:

Global file system 2

Table of Contents