:: [devuan-dev] bug#749: initscripts: …
Pàgina inicial
Delete this message
Reply to this message
Autor: Lorenzo
Data:  
A: Mark Hindley
CC: Olaf Meeuwissen, 749
Assumpte: [devuan-dev] bug#749: initscripts: /etc/init.d/halt calls halt with unsupported options
Hello,

On Wed, 8 Mar 2023 12:43:30 +0000
Mark Hindley <mark@???> wrote:

> > where the symlink target is from the runit package. According to
> > the manual page, my halt command only supports -f, -w and -n short
> > options.
>
> My gut reaction is that runit's halt should either support the
> sysvinit options even if noop.


The current behavior of runit's halt is that options -d -h -p -i
are ignored except that a warning is printed (the exit status is zero).
They are not really noop, since in the original sysvinit implementation
each of -d -h -p -i imply halting/poweroff the system, so that's what
runit's halt does after "ignoring" such options.
I've tested in the past that if I turn -d -h -p -i into noop
the switch sysvinit --> runit-init is broken, so I don't want to do
that.
What is left on runit's side is that I can silence the warning (but I
don't think is a good behavior for a program to silently ignore some
options - it can be documented in the man page though) or add a special
case in 'run_sysv_script' so that 'reboot' and 'halt' scripts are
skipped during runit shutdown sequence.

>
> Lorenzo,
>
> I have no real experience of runit yet. What is the relationship
> between it an initscripts? When are the initscripts used?


Runit is currently borrowing from sysvinit (initscripts package)
scripts to initialize and shutdown the system; it runs sequentially
scripts from /etc/rcS.d/ to boot the system and scripts from /etc/rc0.d/
or /etc/rc6.d/ for shutdown/reboot.

> Is there
> something you can do within src:runit to avoid this?

I think reassigning this to runit as Debian bug with severity minor is
appropriate.

Lorenzo

>
> Thanks
>
> Mark