This commit is contained in:
Páll Guðjón Sigurðsson 2010-09-04 01:39:24 +00:00
parent 016431579a
commit ea1dee8429
1 changed files with 7 additions and 7 deletions

View File

@ -30,9 +30,9 @@
# First some defaults # First some defaults
hostname="evahost" hostname="localhost"
username="eva" username="eva"
password="eval1234" password="eva1234"
mode="check_systems" mode="check_systems"
debugging = False debugging = False
path='' path=''
@ -194,14 +194,14 @@ def run_sssu(system=None, command="ls system full"):
if output.pop(0).strip().find('Version:') != 0: error=1 if output.pop(0).strip().find('Version:') != 0: error=1
if output.pop(0).strip().find('Build:') != 0: error=1 if output.pop(0).strip().find('Build:') != 0: error=1
if output.pop(0).strip().find('NoSystemSelected> ') != 0: error=1 if output.pop(0).strip().find('NoSystemSelected> ') != 0: error=1
if output.pop(0).strip() != '': error = 1 #if output.pop(0).strip() != '': error = 1
if output.pop(0).strip().find('NoSystemSelected> ') != 0: error=1 #if output.pop(0).strip().find('NoSystemSelected> ') != 0: error=1
if output.pop(0).strip() != '': error = 1 #if output.pop(0).strip() != '': error = 1
buffer = "" buffer = ""
for i in output: for i in output:
buffer = buffer + i + "\n" buffer = buffer + i + "\n"
if i.find('error') > -1: if i.find('Error') > -1:
print "Error running sssu command: %s" % i print "This is the command i was trying to execute: %s" % i
error = 1 error = 1
if i.find('information:') > 0: break if i.find('information:') > 0: break
if error > 0: if error > 0: