diff options
author | Sahina Bose <sabose@redhat.com> | 2014-05-29 12:45:57 +0530 |
---|---|---|
committer | Sahina Bose <sabose@redhat.com> | 2014-05-29 01:03:44 -0700 |
commit | 13948635feb101ea64d1e19e9af89e96badb34e6 (patch) | |
tree | e7619400ed0351b020ba90ccd386021314d82d0e | |
parent | 12171f154d5c6d2ee5fd23b7439770f0b51d39fb (diff) |
nagios-common: geo-rep-corrected the comparison check for faulty
Geo rep faulty status would be if any 1 node is faulty in
distributed type
Also corrected the doc text
Change-Id: Ie926e8c44ddff986d616369f1fcab7d0f3956f01
Bug-Url: https://bugzilla.redhat.com/1101218
Signed-off-by: Sahina Bose <sabose@redhat.com>
Reviewed-on: http://review.gluster.org/7922
Reviewed-by: Kanagaraj M <kmayilsa@redhat.com>
-rwxr-xr-x | glusternagios/glustercli.py | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/glusternagios/glustercli.py b/glusternagios/glustercli.py index 4029905..7aa0bd4 100755 --- a/glusternagios/glustercli.py +++ b/glusternagios/glustercli.py @@ -548,7 +548,7 @@ def _parseVolumeGeoRepStatus(volumeName, out): # subvolume. So if fault+passive > than num of primary bricks, # moving to faulty if (count_dict['faulty'] + count_dict['passive'] - > count_dict['nodecount']/replicaCount): + >= count_dict['nodecount']/replicaCount): slaves[slave]['status'] = GeoRepStatus.FAULTY else: slaves[slave]['status'] = GeoRepStatus.PARTIAL_FAULTY @@ -569,9 +569,9 @@ def volumeGeoRepStatus(volumeName, remoteServer=None): {VOLUMENAME: {'slaves': [{SLAVENAME:{ 'nodecount': COUNT, 'faulty': COUNT, - 'notstarted': 0, - 'stopped': 0, - 'passive':0, + 'notstarted': COUNT, + 'stopped': COUNT, + 'passive':COUNT, 'detail': detailed message, 'status': GEOREPSTATUS}} ]} |