[Ocfs2-tools-devel] [PATCH] o2cb: fix systemd o2cb.service failure

Junxiao Bi junxiao.bi at oracle.com
Tue Oct 13 19:27:43 PDT 2015


Configfs may have been mounted by "modprobe -s configfs" in
load_filesystem() on ol7 which has systemd supported, in this
case, mount_filesystem() will fail and o2cb.service can't be
started. To fix this, check fs mount status when mount fail,
if already mounted, don't return error.

Signed-off-by: Junxiao Bi <junxiao.bi at oracle.com>
---
 vendor/common/o2cb.init.sh |    1 +
 1 file changed, 1 insertion(+)

diff --git a/vendor/common/o2cb.init.sh b/vendor/common/o2cb.init.sh
index dedb408..e8d5e8d 100755
--- a/vendor/common/o2cb.init.sh
+++ b/vendor/common/o2cb.init.sh
@@ -610,6 +610,7 @@ mount_filesystem()
     mount -t ${FSNAME} ${FSNAME} ${MOUNTPOINT}
     if [ $? != 0 ]
     then
+        check_filesystem "$FSNAME" "$MOUNTPOINT" && return 2
         echo "Unable to mount ${FSNAME} filesystem" >&2
         return 1
     fi
-- 
1.7.9.5




More information about the Ocfs2-tools-devel mailing list