Hi!

On Fri, 2011-01-21 at 17:58:18 +0100, Peter Gyongyosi wrote:
> Package: dpkg
> Version: 1.15.5.6ubuntu4.3
> Severity: wishlist
> Tags: patch

> the attached patch adds the functionality to start-stop-daemon that makes
> it capable of tracking and detecting the PID of programs it starts and
> which fork themselves. The manpage entries for the new arguments
> summarize the feature quite well:

[...]

> This feature could be used in two scenarios:
> 
> 1) the program forks itself but it cannot output its PID into a file

Why? If it's because it does not have such option, then the correct
fix is to add it, it should not amount to more than 10-15 lines of C.

> 2) it is not feasible to call the program a way that makes it output its
>    pidfile (OK, I admit this does not sound so common, but it was actually
>    this case that made me write this addition -- see
>    http://gyp.blogs.balabit.com/2011/01/using-upstart-in-a-chroot/
>    for details, if you're interested, but it's 99% unrelated to
>    start-stop-daemon)

Why not fix upstart so that it can work on a chroot? or is that not
possible given its design (which would be odd).

> In both cases, start-stop-daemon can now be used to save the PID of the
> process, and so --stop can work reliably.
> 
> I've found a proposed patch in bug #35117 back from 1999 that seems to
> address the same problem, although in a different way, but it seems like
> it's been pretty much abandoned since then.

That patch become the current --background and --make-pidfile options,
which to be frank are already bad as they are, as people tend to use
them when they should be adding the code into the daemon properly. So
I'd rather not add more such options, if no really strong reasons are
put forward.

thanks,
guillem



-- 
To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org

Reply via email to