toned down the error message for unconfigured master/slave

reviewable/pr18780/r1
Dylan Martin 11 years ago
parent 3c7f8d6272
commit 280ecaa453

@ -305,15 +305,15 @@ def main():
masterstatus = get_master_status(cursor) masterstatus = get_master_status(cursor)
try: try:
module.exit_json( **masterstatus ) module.exit_json( **masterstatus )
except TypeError, e: except TypeError:
module.fail_json(msg="Server is not configured as mysql master: %s" % e) module.fail_json(msg="Server is not configured as mysql master")
elif mode in "getslave": elif mode in "getslave":
slavestatus = get_slave_status(cursor) slavestatus = get_slave_status(cursor)
try: try:
module.exit_json( **slavestatus ) module.exit_json( **slavestatus )
except TypeError, e: except TypeError:
module.fail_json(msg="Server is not configured as mysql slave: %s" % e) module.fail_json(msg="Server is not configured as mysql slave")
elif mode in "changemaster": elif mode in "changemaster":
print "Change master" print "Change master"

Loading…
Cancel
Save