On Wed, 15 Nov 2023 at 23:03, Guillem Jover <guil...@debian.org> wrote:

> I'm all in for shrinking the essential-set. If there is consensus to
> switch pidof implementations that also seems fine to me in the abstract.
> But this shuffling around of essential-ness and new tiny packages and
> stuff seems a bit unnecessary to me, more so when this increases the
> bootstrapping-set. I'd also rather see instead a _proper_ transition to
> get sysvinit-utils out of the essential-set, and then at some later
> point procps can take over pidof.
>
There really is two options then:

1) Switch pidof to new Essential package procps-base THEN update/fix the
dependent packages
2) Update/fix the dependent packages THEN move pidof to standard procps.
Independent? of either: re-work init scripts to use start-stop-daemon

For people that want the standard pidof #1 is preferred, for people
concerned about Essential's size #2 is preferred.

Most of the pidof usage can be broken down into a few sets:
* Used in comments/documentation - can be ignored for "pidof is Essential"
purposes
* Used in init or pre/post scripts - should probably be using pidofproc
* Within their programs use something like system("pidof myprog")
and then there are a few other odd ones that don't fit into those three.

Then there's the following, which I guess complicates things:
>
>   $ dpkg -S bin/pidof | cut -d: -f2
>    /bin/pidof
>
 I'm not sure what the complication is here.

Also why is killall5 not a candidate too?

There's no other implementation of killall5 though it is probably something
that could be done with one of the other /.*kill.*/ programs.
Significantly, I don't think there is any real dependency of this program
in other programs, codesearch seems to be only for documentation.



> I think the status_of_proc function could be switched to use
> start-stop-daemon (s-s-d) --status instead of pidofproc. To replace
> pidof inside pidofproc I guess s-s-d could grow some option to print
> the pid, I'd be happy to implement that. After doing a quick scan over
> codesearch.debian.org, I notice that it looks like many current uses
> of pidofproc should instead probably be using status_of_proc, and others
> seem to just be fetching the pid to then perform some action that could
> instead all be done directly with s-s-d.
>
I agree that this is a good idea. It will be more about removing the
Essential flag on any package.

 - Craig

Reply via email to