[icinga-checkins] icinga.org: icinga-core/master: Revert "modifications to init scripts"

git at icinga.org git at icinga.org
Wed Nov 9 16:44:45 CET 2011


Module: icinga-core
Branch: master
Commit: 559a99cda978d85edbb4ea6a57c4fa2be66cd877
URL:    https://git.icinga.org/?p=icinga-core.git;a=commit;h=559a99cda978d85edbb4ea6a57c4fa2be66cd877

Author: Michael Friedrich <michael.friedrich at univie.ac.at>
Date:   Mon Nov  7 10:25:06 2011 +0100

Revert "modifications to init scripts"

This reverts commit 5bbc81f7315c66cdae5ce9cecc97ed76123c475b.

Conflicts:

	daemon-init.in

---

 daemon-init-redhat.in |   14 --------------
 daemon-init.in        |   10 +---------
 2 files changed, 1 insertions(+), 23 deletions(-)

diff --git a/daemon-init-redhat.in b/daemon-init-redhat.in
index 55f196c..6e456f4 100644
--- a/daemon-init-redhat.in
+++ b/daemon-init-redhat.in
@@ -28,19 +28,6 @@ user="@icinga_user@"
 
 lockfile=/var/lock/subsys/$prog
 
-pid_lock() {
-    if [ -e $pidfile ] ; then 
-	pproc=`ps auxww |grep (cat "$pidfile") `
-	echo "Icinga Process PID file present"
-	 if [ -z $pproc ] ; then 
-	    rm -f $pidfile
-	    echo "PID file removed and $pidfile process is not active on system"
-	fi 
-    fi 
-    exit 
-}
-
-
 start() {
     [ -x $exec ] || exit 5
     [ -f $config ] || exit 6
@@ -91,7 +78,6 @@ check_config() {
 
 case "$1" in
     start)
-	pid_lock
         status $prog && exit 0
 	check_config
         $1
diff --git a/daemon-init.in b/daemon-init.in
index 9a5fb5a..d846174 100644
--- a/daemon-init.in
+++ b/daemon-init.in
@@ -99,15 +99,7 @@ pid_icinga ()
 	if test ! -f $IcingaRunFile; then
 		echo "Icinga not running. No lock file found in $IcingaRunFile"
 		exit 1
-	elif [ -e $IcingaRunFile ] ; then
-    	    pproc=`ps auxww |grep $IcingaPID `
-    	    echo "Icinga Process PID file present"
-    	     if [ -z "$pproc" ] ; then
-        	rm -f $IcingaRunFile
-    		echo "PID file removed and $IcingaPID process is not active on system"
-	     fi
-        fi
-        exit 1
+	fi
 
 	IcingaPID=`head -n 1 $IcingaRunFile`
 }





More information about the icinga-checkins mailing list