diff --git a/check_rhcs/check_rhcs.py b/check_rhcs/check_rhcs.py index 5a8db20..6f4142d 100644 --- a/check_rhcs/check_rhcs.py +++ b/check_rhcs/check_rhcs.py @@ -110,6 +110,7 @@ def main(): sys.exit(2) check_suspend = False + typeCheck = None for o, a in opts: if o in ('-c', '--cluster'): typeCheck = 'cluster' @@ -122,6 +123,10 @@ def main(): usage() sys.exit() + if typeCheck == None: + usage() + sys.exit() + try: clustatOutput = os.popen('/usr/sbin/clustat -fx') dom = xml.dom.minidom.parse(clustatOutput)