Skip to content

Commit

Permalink
Merge pull request #9872 from odivlad/fix-init-el7-jewel
Browse files Browse the repository at this point in the history
jewel: remove SYSTEMD_RUN from initscript

Reviewed-by: Orit Wasserman <owasserm@redhat.com>
  • Loading branch information
Loic Dachary committed Oct 14, 2016
2 parents 65e8bbc + cca589f commit 52e596f
Showing 1 changed file with 2 additions and 8 deletions.
10 changes: 2 additions & 8 deletions src/init-radosgw
Expand Up @@ -17,10 +17,6 @@ if [ -x /sbin/start-stop-daemon ]; then
else
. /etc/rc.d/init.d/functions
DEBIAN=0

# detect systemd, also check whether the systemd-run binary exists
SYSTEMD_RUN=$(which systemd-run 2>/dev/null)
grep -qs systemd /proc/1/comm || SYSTEMD_RUN=""
fi

daemon_is_running() {
Expand Down Expand Up @@ -99,10 +95,8 @@ case "$1" in
fi

echo "Starting $name..."
if [ $DEBIAN -eq 1 ]; then
start-stop-daemon --start -u $user -x $RADOSGW -p /var/run/ceph/client-$name.pid -- -n $name
elif [ -n "$SYSTEMD_RUN" ]; then
$SYSTEMD_RUN -r su "$user" -c "ulimit -n 32768; $RADOSGW -n $name"
if [ $DEBIAN -eq 1 ]; then
start-stop-daemon --start -u $user -x $RADOSGW -p /var/run/ceph/client-$name.pid -- -n $name
else
ulimit -n 32768
core_limit=`ceph-conf -n $name 'core file limit'`
Expand Down

0 comments on commit 52e596f

Please sign in to comment.