When corosync is started by systemd, it would be considered as failed because it returns a non-zero value, even though it starts sucessfully. Also creating the lock directory before creating the lock file. Signed-off-by: Lidong Zhong <lzhong@xxxxxxxx> Signed-off-by: Xia Li <xli@xxxxxxxx> --- init/corosync.in | 3 +++ 1 file changed, 3 insertions(+) diff --git a/init/corosync.in b/init/corosync.in index 4bc6041..5ded5fc 100755 --- a/init/corosync.in +++ b/init/corosync.in @@ -29,6 +29,7 @@ PATH="/sbin:/bin:/usr/sbin:/usr/bin:@SBINDIR@" success() { echo -ne "[ OK ]\r" + rtrn=0 } failure() @@ -53,12 +54,14 @@ if [ -d @SYSCONFDIR@/sysconfig ]; then [ -f @INITDDIR@/functions ] && . @INITDDIR@/functions [ -f @SYSCONFDIR@/sysconfig/$prog ] && . @SYSCONFDIR@/sysconfig/$prog [ -z "$LOCK_FILE" ] && LOCK_FILE="@LOCALSTATEDIR@/lock/subsys/$prog" + mkdir -p @LOCALSTATEDIR@/lock/subsys fi # deb based distros if [ -d @SYSCONFDIR@/default ]; then [ -f @SYSCONFDIR@/default/$prog ] && . @SYSCONFDIR@/default/$prog [ -z "$LOCK_FILE" ] && LOCK_FILE="@LOCALSTATEDIR@/lock/$prog" + mkdir -p @LOCALSTATEDIR@/lock fi # The version of __pids_pidof in /etc/init.d/functions calls pidof with -x -- 1.8.1.4 _______________________________________________ discuss mailing list discuss@xxxxxxxxxxxx http://lists.corosync.org/mailman/listinfo/discuss