On Tue, Nov 18, 2014 at 09:25:44AM +0000, Simon McVittie wrote:
> There are (at least) three things that start services (i.e. init
> scripts, systemd units or Upstart jobs):
> 
> * invoke-rc.d, intended to be called from maintainer scripts
> * service, intended to be called by the sysadmin
> * the normal boot process

There is a fourth one that restarts/reloads services: logrotate

Please excuse a little excursion into the inhomogeneity of signalling
services from logrotate. I did a little bit of research and came up
with the following numbers (sid i386+all main):

 -> 360 packages shipping logrotate files
    -> 192 with scripts (e.g. reloading a daemon)
       -> 64 using invoke-rc.d
       -> 34 invoking /etc/init.d/something directly
       -> 24 killing via pidifle
       -> 13 using killall (I couldn't believe it at first)
       -> 7 using start-stop-daemon (the policy has an example)
       -> 6 using the service wrapper mentioned above
       (some overlaps:
        e.g. "[ -x /etc/init.d/foo ] && service foo reload")

>From this little exercise, it seems that it is not well understood in
what way services should be signalled after log rotation. In particular,
it seems to me that service and invoke-rc.d should not be both valid. So
I ask:

Should logrotate snippets honour policy-rc.d (and use invoke-rc.d) or
should they ignore policy-rc.d (and likely use service)? Why?

It also seems that quite a few services use custom reload actions in
their init.d script (e.g. "reopen-logs", "rotate", "reconfig",
"reopenlog"). Is there a separate action for reopening logs for any init
system?

It also seems that using /etc/init.d/service with actions start or
restart is a bad idea when using the default init system. The following
packages do that however:

argonaut-fuse
battery-stats
dansguardian
freeipmi-bmc-watchdog
nagzilla
privoxy
qpsmtpd
quickml
snort
xorp
xtide

I am pondering to MBF those packages (at normal severity). Any opinions
on that?

So many questions...

Helmut


-- 
To UNSUBSCRIBE, email to debian-devel-requ...@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org
Archive: https://lists.debian.org/20141118224108.ga9...@alf.mars

Reply via email to