diff options
author | ShwethaHP <spandura@redhat.com> | 2018-01-23 12:28:50 +0530 |
---|---|---|
committer | Nigel Babu <nigelb@redhat.com> | 2018-01-30 04:58:53 +0000 |
commit | 24eee0352397cfa8b51d467eb1bd46f710124012 (patch) | |
tree | ca0914ef1b85f7b0af2aaed9ea8a1d77d2091dbc /glustolibs-gluster/glustolibs | |
parent | 9c5e828e51ca14ec5151a629175ed95cce0106fe (diff) |
Check if volume type is 'distribute' before checking if self-heal-daemons are online
Change-Id: I25424dd182c347a0570713ada8d2de611840fef3
Signed-off-by: ShwethaHP <spandura@redhat.com>
Diffstat (limited to 'glustolibs-gluster/glustolibs')
-rw-r--r-- | glustolibs-gluster/glustolibs/gluster/heal_libs.py | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/glustolibs-gluster/glustolibs/gluster/heal_libs.py b/glustolibs-gluster/glustolibs/gluster/heal_libs.py index 3da020380..1de540836 100644 --- a/glustolibs-gluster/glustolibs/gluster/heal_libs.py +++ b/glustolibs-gluster/glustolibs/gluster/heal_libs.py @@ -96,6 +96,13 @@ def are_all_self_heal_daemons_are_online(mnode, volname): False otherwise. NoneType: None if unable to get the volume status """ + from glustolibs.gluster.volume_libs import is_distribute_volume + if is_distribute_volume(mnode, volname): + g.log.info("Volume %s is a distribute volume. " + "Hence not checking for self-heal daemons " + "to be online", volname) + return True + service = 'shd' failure_msg = ("Verifying all self-heal-daemons are online failed for " "volume %s" % volname) @@ -286,6 +293,13 @@ def wait_for_self_heal_daemons_to_be_online(mnode, volname, timeout=300): True if all self-heal-daemons are online within timeout, False otherwise """ + from glustolibs.gluster.volume_libs import is_distribute_volume + if is_distribute_volume(mnode, volname): + g.log.info("Volume %s is a distribute volume. " + "Hence not waiting for self-heal daemons " + "to be online", volname) + return True + counter = 0 flag = 0 while counter < timeout: |