dcc-client init fails to create pid file

Bug #81619 reported by L. Jason Godsey
2
Affects Status Importance Assigned to Milestone
dcc (Ubuntu)
Fix Released
Undecided
Unassigned

Bug Description

Binary package hint: dcc-client

I used screen's SCREENDIR method with DCCDIR and updated the start and restart functions.
/etc/init.d/dcc-client follows:

#!/bin/sh
#
# dcc-client example file to build /etc/init.d/ scripts.
# This file should be used to construct scripts for /etc/init.d.

PATH=/sbin:/bin:/usr/sbin:/usr/bin
DAEMON=/usr/sbin/dccifd
NAME=dccifd
DESC="DCC program interface daemon"
DCCDIR=/var/run/dcc

test -f $DAEMON || exit 0

set -e

case "$1" in
  start)
        if [ ! -d $DCCDIR ]; then
                mkdir -p $DCCDIR
                chown dcc:dcc $DCCDIR
        fi
        echo -n "Starting $DESC: $NAME"
        start-stop-daemon --start --quiet --pidfile $DCCDIR/$NAME.pid \
                --chuid dcc:dcc --exec $DAEMON -- $OPTIONS
        echo "."
        ;;
  stop)
        echo -n "Stopping $DESC: $NAME"
        start-stop-daemon --oknodo --stop --quiet --exec $DAEMON
        echo "."
        ;;
  restart)
        echo -n "Restarting $DESC: $NAME"
        start-stop-daemon --stop --quiet --pidfile \
                $DCCDIR/$NAME.pid --exec $DAEMON
        sleep 1
        start-stop-daemon --start --quiet --pidfile \
                $DCCDIR/$NAME.pid --exec $DAEMON -- $OPTIONS
        echo "."
        echo "\n"
        ;;
  *)
        N=/etc/init.d/$NAME
        # echo "Usage: $N {start|stop|restart|reload|force-reload}" >&2
        echo "Usage: $N {start|stop|restart}" >&2
        exit 1
        ;;
esac

exit 0

Revision history for this message
Kai Kasurinen (kai-kasurinen) wrote :

Thanks for the bug report. I'm closing it because the bug has been fixed in Feisty.

dcc (1.3.42-2) unstable; urgency=low

  * dcc-client is gone, and merged into dcc-server. The space gained by the
    split was very small, and resulted in an overcomplicated packaging.

  * in that release, init scripts have been reworked a *lot* and now use
    upstreams scripts correctly. You may have needed to handcraft it
    previously, it's no more needed.

New /etc/init.d/dcc-server contains:
DCC_RUNDIR=/var/run/dcc
if [ ! -d $DCC_RUNDIR ]; then
    mkdir -p $DCC_RUNDIR
    chown dcc:dcc $DCC_RUNDIR
fi

Changed in dcc:
status: Unconfirmed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.