You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cloudstack.apache.org by wi...@apache.org on 2012/07/26 23:05:06 UTC
[11/50] git commit: init: log_process_msg doesn't work,
so use log_daemon_msg for that.
init: log_process_msg doesn't work, so use log_daemon_msg for that.
We also exit earlier, we don't display that we are even trying to start.
When we detect the agent is already running we exit right away with a message.
Project: http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/commit/ae60cd7b
Tree: http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/tree/ae60cd7b
Diff: http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/diff/ae60cd7b
Branch: refs/heads/rbd
Commit: ae60cd7b87c38058d6bbfafc4ffe1d41a89fb63a
Parents: 61f38ba
Author: Wido den Hollander <wi...@widodh.nl>
Authored: Wed Jul 25 14:56:30 2012 +0200
Committer: Wido den Hollander <wi...@widodh.nl>
Committed: Wed Jul 25 14:56:30 2012 +0200
----------------------------------------------------------------------
.../distro/ubuntu/SYSCONFDIR/init.d/cloud-agent.in | 10 +++++-----
1 files changed, 5 insertions(+), 5 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/blob/ae60cd7b/agent/distro/ubuntu/SYSCONFDIR/init.d/cloud-agent.in
----------------------------------------------------------------------
diff --git a/agent/distro/ubuntu/SYSCONFDIR/init.d/cloud-agent.in b/agent/distro/ubuntu/SYSCONFDIR/init.d/cloud-agent.in
index b98efca..c657ed2 100755
--- a/agent/distro/ubuntu/SYSCONFDIR/init.d/cloud-agent.in
+++ b/agent/distro/ubuntu/SYSCONFDIR/init.d/cloud-agent.in
@@ -37,7 +37,7 @@ SHORTNAME="cloud-agent"
PIDFILE=@PIDDIR@/"$SHORTNAME".pid
LOCKFILE=@LOCKDIR@/"$SHORTNAME"
LOGFILE=@AGENTLOG@
-PROGNAME="Cloud Agent"
+PROGNAME="CloudStack Agent"
CLASS="com.cloud.agent.AgentShell"
PROG="jsvc"
DAEMON="/usr/bin/jsvc"
@@ -82,13 +82,13 @@ wait_for_network() {
}
start() {
- log_daemon_msg "Starting $PROGNAME" "$SHORTNAME"
if [ -s "$PIDFILE" ] && kill -0 $(cat "$PIDFILE") >/dev/null 2>&1; then
- log_progress_msg "apparently already running"
- log_end_msg 0
- exit 0
+ log_daemon_msg "$PROGNAME apparently already running"
+ log_end_msg 0
+ exit 0
fi
+ log_daemon_msg "Starting $PROGNAME" "$SHORTNAME"
if hostname --fqdn >/dev/null 2>&1 ; then
true
else