Bug#533079: asterisk: start-stop-daemon should have --make-pid

Faidon Liambotis paravoid at debian.org
Sun Jun 14 15:39:49 UTC 2009


Darsha, hi,

Darshaka Pathirana wrote:
 > --- /etc/init.d/asterisk.orig   2009-06-14 17:01:23.000000000 +0200
> +++ /etc/init.d/asterisk        2009-06-14 16:31:44.000000000 +0200
> @@ -170,7 +170,7 @@
>                         echo "$DESC is already running. Use restart."
>                         exit 0
>                 fi
> -               start-stop-daemon --start --group $GROUP --pidfile "$PIDFILE" \
> +               start-stop-daemon --start --group $GROUP --make-pidfile --pidfile "$PIDFILE" \
>                         $CHDIR_PARM \
>                         --exec $REALDAEMON -- $PARAMS
> 
> After adding the option my postinst-script run fine.
That's incorrect. --make-pidfile is for programs that don't create their
own pidfile. This is usually the wrong way to do things because of
processes forking into the background and changing pids.

Asterisk creates its own pidfile, and there's no reason that we should
switch from it to start-stop-daemon.

> Please note that running "/etc/init.d/asterisk restart" on the command line
> caused no problems. So there must be something wrong in combination with debconf.
> (But I have no idea what why.)
Right, we'd have a much bigger issue if "restart" didn't work :-)
I'm not sure what's the problem with your setup.

I'll try to have a look with your example postinst at some point.

Thanks,
Faidon





More information about the Pkg-voip-maintainers mailing list