summaryrefslogtreecommitdiffstats
path: root/source/a/libcgroup/libcgroup.init.diff
diff options
context:
space:
mode:
Diffstat (limited to 'source/a/libcgroup/libcgroup.init.diff')
-rw-r--r--source/a/libcgroup/libcgroup.init.diff36
1 files changed, 19 insertions, 17 deletions
diff --git a/source/a/libcgroup/libcgroup.init.diff b/source/a/libcgroup/libcgroup.init.diff
index 72dcaa31d..c3f110ed6 100644
--- a/source/a/libcgroup/libcgroup.init.diff
+++ b/source/a/libcgroup/libcgroup.init.diff
@@ -1,6 +1,6 @@
---- ./scripts/init.d/cgred.in.orig 2011-03-08 05:29:42.000000000 -0600
-+++ ./scripts/init.d/cgred.in 2013-02-23 16:15:54.054745738 -0600
-@@ -39,9 +39,8 @@
+--- ./scripts/init.d/cgred.in.orig 2014-01-13 08:05:56.000000000 -0600
++++ ./scripts/init.d/cgred.in 2014-08-25 14:38:35.588193215 -0500
+@@ -39,13 +39,12 @@
# Sanity checks
[ -x $CGRED_BIN ] || exit 1
@@ -10,8 +10,14 @@
-. /lib/lsb/init-functions
# Read in configuration options.
- if [ -f "/etc/sysconfig/cgred.conf" ] ; then
-@@ -70,16 +69,16 @@
+-if [ -f "/etc/sysconfig/cgred.conf" ] ; then
+- . /etc/sysconfig/cgred.conf
++if [ -f $CGRED_CONF ] ; then
++ . $CGRED_CONF
+ OPTIONS="$NODAEMON $LOG"
+ if [ -n "$LOG_FILE" ]; then
+ OPTIONS="$OPTIONS --logfile=$LOG_FILE"
+@@ -70,13 +69,13 @@
{
echo -n $"Starting CGroup Rules Engine Daemon: "
if [ -f "$lockfile" ]; then
@@ -19,19 +25,15 @@
+ echo "$servicename is already running with PID `cat ${pidfile}`"
return 0
fi
- if [ ! -s $CGRED_CONF ]; then
-- log_failure_msg "not configured"
-+ echo "not configured"
- return 6
- fi
- if ! grep "^cgroup" /proc/mounts &>/dev/null; then
+ num=`grep "cgroup" /proc/mounts | awk '$3=="cgroup"' | wc -l`
+ if [ $num -eq 0 ]; then
echo
- log_failure_msg $"Cannot find cgroups, is cgconfig service running?"
+ echo $"Cannot find cgroups, is cgconfig service running?"
return 1
fi
daemon --check $servicename --pidfile $pidfile $CGRED_BIN $OPTIONS
-@@ -100,7 +99,7 @@
+@@ -97,7 +96,7 @@
{
echo -n $"Stopping CGroup Rules Engine Daemon..."
if [ ! -f $pidfile ]; then
@@ -40,7 +42,7 @@
return 0
fi
killproc -p $pidfile -TERM "$processname"
-@@ -146,13 +145,13 @@
+@@ -143,13 +142,13 @@
echo $"Reloading rules configuration..."
kill -s 12 `cat ${pidfile}`
RETVAL=$?
@@ -60,8 +62,8 @@
fi
;;
*)
---- ./scripts/init.d/cgconfig.in.orig 2011-12-06 03:42:15.000000000 -0600
-+++ ./scripts/init.d/cgconfig.in 2013-02-23 16:23:51.530775095 -0600
+--- ./scripts/init.d/cgconfig.in.orig 2014-01-13 08:05:56.000000000 -0600
++++ ./scripts/init.d/cgconfig.in 2014-08-25 14:38:38.291193382 -0500
@@ -36,11 +36,6 @@
servicename=cgconfig
lockfile=/var/lock/subsys/$servicename
@@ -75,8 +77,8 @@
CREATE_DEFAULT=yes
if [ -e /etc/sysconfig/cgconfig ]; then
@@ -54,8 +49,8 @@
- grep -m1 '^\*[[:space:]]\+' /etc/cgrules.conf | \
- read user ctrl defaultcgroup
+ read user ctrl defaultcgroup <<< \
+ $(grep -m1 '^\*[[:space:]]\+' /etc/cgrules.conf)
if [ -n "$defaultcgroup" -a "$defaultcgroup" = "*" ]; then
- log_warning_msg "/etc/cgrules.conf incorrect"
- log_warning_msg "Overriding it"