summaryrefslogtreecommitdiffstats
path: root/scripts
diff options
context:
space:
mode:
authorDhaval Giani <dhaval@linux.vnet.ibm.com>2008-12-16 17:20:11 +0000
committerDhaval Giani <dhaval@linux.vnet.ibm.com>2008-12-16 17:20:11 +0000
commit802c4cab60c6d067d49b1422694a2a6858e98940 (patch)
treedf1107b20fdcf59a1b2274e21d2e1cf07bb01365 /scripts
parentdcb708a93e68ef4395fe9af88275bafc91aa3fa1 (diff)
downloadlibcg-802c4cab60c6d067d49b1422694a2a6858e98940.zip
libcg-802c4cab60c6d067d49b1422694a2a6858e98940.tar.gz
libcg-802c4cab60c6d067d49b1422694a2a6858e98940.tar.xz
libcgroup: Fix broken cgred
From: Balbir Singh <balbir@linux.vnet.ibm.com> cgred is broken, in that there are some checks that fail and we use --config to start the daemon and that is not supported. We also use -12 as the signal to killproc. This patch fixes all of those issues Signed-off-by: Balbir Singh <balbir@linux.vnet.ibm.com> Signed-off-by: Dhaval Giani <dhaval@linux.vnet.ibm.com> git-svn-id: https://libcg.svn.sourceforge.net/svnroot/libcg/trunk@237 4f4bb910-9a46-0410-90c8-c897d4f1cd53
Diffstat (limited to 'scripts')
-rw-r--r--scripts/init.d/cgred7
1 files changed, 3 insertions, 4 deletions
diff --git a/scripts/init.d/cgred b/scripts/init.d/cgred
index 3d9fe2a..ee9fc40 100644
--- a/scripts/init.d/cgred
+++ b/scripts/init.d/cgred
@@ -38,11 +38,10 @@ prefix=/usr
exec_prefix=/usr
bindir=/bin
-CGRED_BIN=${bindir}/cgrulesengd
+CGRED_BIN=${exec_prefix}/${bindir}/cgrulesengd
# Sanity checks
[ -x $CGRED_BIN ] || exit 1
-[ -x /lib/libcgroup.so ] || exit 1
# Source function library & LSB routines
. /etc/rc.d/init.d/functions
@@ -51,7 +50,7 @@ CGRED_BIN=${bindir}/cgrulesengd
# Read in configuration options.
if [ -f "/etc/cgred.d/cgred.conf" ] ; then
. /etc/cgred.d/cgred.conf
- OPTIONS="--config $CONFIG_FILE --log $LOG_FILE $NODAEMON $NOLOG"
+ OPTIONS="--log $LOG_FILE $NODAEMON $NOLOG"
else
OPTIONS=""
fi
@@ -80,7 +79,7 @@ start()
stop()
{
echo -n $"Stopping CGroup Rules Engine Daemon..."
- killproc -p $pidfile $processname -12
+ killproc -p $pidfile $processname -TERM
RETVAL=$?
echo
if [ $RETVAL -eq 0 ] ; then