summaryrefslogtreecommitdiffstats
path: root/src/com.gluster.storage.management.gateway/WebContent/scripts/grun.py
diff options
context:
space:
mode:
authorTim <timothyasir@gluster.com>2011-08-09 18:11:30 +0530
committerTim <timothyasir@gluster.com>2011-08-09 18:11:30 +0530
commit99453fd4bd9975eeaa7616cbe2d4d47e01da3dde (patch)
treee2afd42c29c0029d6a9e3b2991117faa576995b2 /src/com.gluster.storage.management.gateway/WebContent/scripts/grun.py
parentd54f773ac96146a7f5299d276be4778b4c9bf4e2 (diff)
Revert "Enhanced error handling and written appropriate execution error into stderr."
This reverts commit 36d1fa53d62f4c3f458b0fac58968b6fab6a271f.
Diffstat (limited to 'src/com.gluster.storage.management.gateway/WebContent/scripts/grun.py')
-rwxr-xr-xsrc/com.gluster.storage.management.gateway/WebContent/scripts/grun.py8
1 files changed, 3 insertions, 5 deletions
diff --git a/src/com.gluster.storage.management.gateway/WebContent/scripts/grun.py b/src/com.gluster.storage.management.gateway/WebContent/scripts/grun.py
index cc00f466..e09ef5bc 100755
--- a/src/com.gluster.storage.management.gateway/WebContent/scripts/grun.py
+++ b/src/com.gluster.storage.management.gateway/WebContent/scripts/grun.py
@@ -33,15 +33,13 @@ def main():
fp.close()
except IOError, e:
Utils.log("Failed to read server file %s: %s\n" % (serverFile, str(e)))
- sys.stderr.write("Failed to read server file %s: %s\n" % (serverFile, str(e)))
sys.exit(1)
status = True
for serverName in serverNameList:
- rv = Utils.runCommand(sshCommandPrefix + [serverName.strip()] + command, output=True)
- if rv["Status"] != 0:
- sys.stderr.write("%s: %s\nStdout:\n%s\nStderr:%s\n---\n" \
- % (serverName, rv["Status"], rv["Stdout"], rv["Stderr"]))
+ rv = Utils.runCommand(sshCommandPrefix + [serverName.strip()] + command)
+ print "%s: %s" % (serverName, rv)
+ if rv != 0:
status = False
if status: