mount.glusterfs: A more explicit check to avoid identical mounts

Change check condition from
"[[:space:]+]${mount_point}[[:space:]+]fuse" to
"[[:space:]+]${mount_point}[[:space:]+]fuse.glusterfs". Fix false
postive check result for mount points of other FUSEes, such as "fuse.sshfs".

Change-Id: I13898b50a651a8f5ecc3a94d01b3b5de37ec4cbc
fixes: bz#1640026
Signed-off-by: Han Han <hhan@redhat.com>
This commit is contained in:
Han Han 2018-10-15 09:53:06 +08:00 committed by Amar Tumballi
parent cf5b13896d
commit 87613d265a

View File

@ -762,7 +762,7 @@ EOF
}
# Simple check to avoid multiple identical mounts
if grep -q "[[:space:]+]${mount_point}[[:space:]+]fuse" $mounttab; then
if grep -q "[[:space:]+]${mount_point}[[:space:]+]fuse.glusterfs" $mounttab; then
warn "$0: according to mtab, GlusterFS is already mounted on" \
"$mount_point"
exit 32;