From 5bfa198c2267b4180b54976b5ff42edc84c58cd9 Mon Sep 17 00:00:00 2001 From: Arthy Loganathan Date: Mon, 12 Jun 2017 18:36:51 +0530 Subject: Fix to match only the given volname in showmount Change-Id: I41290d79f016e590a936d031665259f61aa1474a Signed-off-by: Arthy Loganathan --- glustolibs-gluster/glustolibs/gluster/volume_libs.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'glustolibs-gluster') diff --git a/glustolibs-gluster/glustolibs/gluster/volume_libs.py b/glustolibs-gluster/glustolibs/gluster/volume_libs.py index a2ac55064..8a7806b04 100644 --- a/glustolibs-gluster/glustolibs/gluster/volume_libs.py +++ b/glustolibs-gluster/glustolibs/gluster/volume_libs.py @@ -423,7 +423,7 @@ def is_volume_exported(mnode, volname, share_type): cmd = "showmount -e localhost" _, _, _ = g.run(mnode, cmd) - cmd = "showmount -e localhost | grep %s" % volname + cmd = "showmount -e localhost | grep -w %s" % volname ret, _, _ = g.run(mnode, cmd) if ret != 0: return False -- cgit