Whamcloud - gitweb
LU-10098 scripts: Fix mounted check in Lustre RA 51/29351/3
authorNathaniel Clark <nathaniel.l.clark@intel.com>
Fri, 6 Oct 2017 16:49:23 +0000 (12:49 -0400)
committerOleg Drokin <oleg.drokin@intel.com>
Mon, 6 Nov 2017 03:42:39 +0000 (03:42 +0000)
commitdf96fab178534adb34067b20490a2d0629aabe2f
treef119f78c77a192e875a904fa6cb69026aa6e7c0a
parent97fe84143da81d42770ae29298403aad80103f94
LU-10098 scripts: Fix mounted check in Lustre RA

The "Lustre" resource agent for pacemaker can mis-identify a resource
as being mounted if it's mountpoint is a substring match for anything
else in /proc/mounts.  Change the lustre_is_mounted() function to
check to make sure it's a lustre fs mounted at mountpoint and the
"source" (i.e. device) is the target we expect.

Signed-off-by: Nathaniel Clark <nathaniel.l.clark@intel.com>
Change-Id: Ib877b0dc3d3ce0d93fd4663aa2418ac21d670428
Reviewed-on: https://review.whamcloud.com/29351
Tested-by: Jenkins
Reviewed-by: Malcolm Cowe <malcolm.j.cowe@intel.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Olaf Faaland-LLNL <faaland1@llnl.gov>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
contrib/scripts/pacemaker/Lustre