How do you bind mount a GFS2 file-system?

Solution Verified - Updated

Environment

  • Red Hat Enterprise Linux Server 5 (with the High Availability and Resilient Storage Add Ons)
  • Red Hat Enterprise Linux Server 6 (with the High Availability and Resilient Storage Add Ons)
  • Red Hat Enterprise Linux Server 7 (with the High Availability and Resilient Storage Add Ons)
  • Red Hat Enterprise Linux Server 8 (with the High Availability and Resilient Storage Add Ons)

Issue

  • How can you bind a GFS2 filesystem to a mount point?

Resolution

For RHEL 5 ( rgmanager ):

For RHEL 6 ( rgmanager ):

For RHEL 7 and 8 ( pacemaker ):

  • When using a gfs2 active/active filesystem the resource can be cloned for concurrent bind mounts on multiple servers:

      # After creating the original filesystem resource:
      # pcs resource create <resource id> Filesystem device=<original mount point> directory=<new mount point> fstype=none options=bind clone interleave=true --group <gfs2 group>
      
      $ pcs resource create bindmnt Filesystem device=/mnt/gfs1 directory=/bind fstype=none options=bind clone interleave=true --group gfs2grp-clone
    
SBR
Components
Category
Tags

This solution is part of Red Hat’s fast-track publication program, providing a huge library of solutions that Red Hat engineers have created while supporting our customers. To give you the knowledge you need the instant it becomes available, these articles may be presented in a raw and unedited form.