[sr-dev] Patches to get proper status code in daemonize mode
Henning Westerholt
henning.westerholt at 1und1.de
Tue Apr 20 13:20:54 CEST 2010
On Monday 19 April 2010, Iñaki Baz Castillo wrote:
> > But if we could allow the init script to block for some time, what about
> > this (IMHO much simpler) approach:
> >
> > * kamailio gets started as usual
> > * init script sleeps for some time (e.g. 5-10 seconds, configurable)
> > * init script checks if the process is really running (process list,
> > FIFO, SIP OPTIONS..)
> > * init script returns the appropriate return code
> >
> > Not sure if you already considered this.
>
> I've done the same for some other services wrongly managing exit
> status codes. Sincerely I consider it a bad workaround, not reliable
> and ugly (why to force a timeout if the init script could exit
> quickly?). Also note that usually HeartBeat waits just a limited
> ammount of seconds when it starts a service.
Hi Iñaki,
i've not yet looked into your patch, if its not that invasive and fairly easy
to implement (as mentioned in later messages) its fine with me. Implementing
it in the init script would be indeed more like a workaround. It would not
help in the case when the daemon gets started directly.
Cheers,
Henning
More information about the sr-dev
mailing list