summaryrefslogtreecommitdiffstats
path: root/glustolibs-gluster
diff options
context:
space:
mode:
authorArthy Loganathan <aloganat@redhat.com>2020-12-18 19:25:45 +0530
committerArthy Loganathan <aloganat@redhat.com>2021-01-06 09:12:39 +0000
commiteeae38ef23c3c9a04510277f0b6f4c854cf73c4a (patch)
tree8fde59e46ac79470ad9a8da42e305afeed55019a /glustolibs-gluster
parentdca0f892136d9b069c2b44af02de381a1b1155ff (diff)
[LibFix] Check to ignore peer validation in case of single node server
Change-Id: I5ad55be92b3acaa605e66de246ce7d40bcec6d5b Signed-off-by: Arthy Loganathan <aloganat@redhat.com>
Diffstat (limited to 'glustolibs-gluster')
-rwxr-xr-xglustolibs-gluster/glustolibs/gluster/gluster_base_class.py5
1 files changed, 5 insertions, 0 deletions
diff --git a/glustolibs-gluster/glustolibs/gluster/gluster_base_class.py b/glustolibs-gluster/glustolibs/gluster/gluster_base_class.py
index 3ce38a304..b2fdc439d 100755
--- a/glustolibs-gluster/glustolibs/gluster/gluster_base_class.py
+++ b/glustolibs-gluster/glustolibs/gluster/gluster_base_class.py
@@ -196,6 +196,11 @@ class GlusterBaseClass(TestCase):
Returns (bool): True if all peers are in connected with other peers.
False otherwise.
"""
+
+ # If the setup has single node server, by pass this validation.
+ if len(cls.servers) == 1:
+ return True
+
# Validate if peer is connected from all the servers
g.log.info("Validating if servers %s are connected from other servers "
"in the cluster", cls.servers)