Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 26 Dec 2022 15:20:56 -0700
From:      Nathan Huff <nhuff@acm.org>
To:        freebsd-hackers@freebsd.org
Subject:   Re: daemon(8) exit behavior
Message-ID:  <86o7rp7qnr.fsf@enyo.nrhuff.com>
In-Reply-To: <23fba5e2-0f7d-b609-9ec0-009d6f6bd085@souji-thenria.net>
References:  <86tu1i6q2s.fsf@enyo.nrhuff.com> <23fba5e2-0f7d-b609-9ec0-009d6f6bd085@souji-thenria.net>

next in thread | previous in thread | raw e-mail | index | archive | help
Souji Thenria <mail@souji-thenria.net> writes:

> On 12/26/22 18:18, Nathan Huff wrote:
>> 
>> 1. Is there any interest in upstreaming this?
>> 
>
> Because I run in to this problem as well in the past, I would be most 
> interested in this.
>

I have submitted
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=268580
with the patch.

>
> I think using the timeout limit which is used by FreeBSD when shutting 
> down the system, makes the most sens and would have some consistency 
> throughout the system, at leas in my opinion.

I don't want to tie daemon too closely to the init system since I use it
in other contexts at times so that is why I have the delay
configurable. 

> Moreover, I think you should clean up the pidfile, if the daemon process 
> created it. IIRC that's also the current behavior.
>

The pidfiles do get cleaned up in my version. They just don't get
cleaned up until the supervised process actually exits. With the current
behavior the pidfiles can get removed even if the supervised process has
not exited.

--
Nathan Huff



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?86o7rp7qnr.fsf>