Repository: ambari Updated Branches: refs/heads/trunk 2cbbe3817 -> 9230e3306
AMBARI-18267. Confusing output of "ambari-server status" (aonishuk) Project: http://git-wip-us.apache.org/repos/asf/ambari/repo Commit: http://git-wip-us.apache.org/repos/asf/ambari/commit/9230e330 Tree: http://git-wip-us.apache.org/repos/asf/ambari/tree/9230e330 Diff: http://git-wip-us.apache.org/repos/asf/ambari/diff/9230e330 Branch: refs/heads/trunk Commit: 9230e3306680e57d814083a493d11011c8deccf6 Parents: 2cbbe38 Author: Andrew Onishuk <[email protected]> Authored: Fri Aug 26 13:56:55 2016 +0300 Committer: Andrew Onishuk <[email protected]> Committed: Fri Aug 26 13:56:55 2016 +0300 ---------------------------------------------------------------------- ambari-server/src/main/python/ambari-server.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/ambari/blob/9230e330/ambari-server/src/main/python/ambari-server.py ---------------------------------------------------------------------- diff --git a/ambari-server/src/main/python/ambari-server.py b/ambari-server/src/main/python/ambari-server.py index f929042..d0ddf6e 100755 --- a/ambari-server/src/main/python/ambari-server.py +++ b/ambari-server/src/main/python/ambari-server.py @@ -192,7 +192,10 @@ def status(args): print "Ambari Server running" print "Found Ambari Server PID: " + str(pid) + " at: " + pid_file_path else: - print "Ambari Server not running. Stale PID File at: " + pid_file_path + if os.path.exists(pid_file_path): + print "Ambari Server not running. Stale PID File at: " + pid_file_path + else: + print "Ambari Server not running." args.exit_code = 3
