Devuan bug report logs - #749
initscripts: /etc/init.d/halt calls halt with unsupported options

version graph

Package: runit-init; Maintainer for runit-init is (unknown); Source for runit-init is src:runit.

Reported by: Olaf Meeuwissen <paddy-hack@member.fsf.org>

Date: Wed, 8 Mar 2023 12:26:01 UTC

Severity: normal

Tags: debian

Fixed in version 2.1.2-55

Done: Mark Hindley <mark@hindley.org.uk>

Forwarded to https://bugs.debian.org/1032943

Full log


Message #13 received at 749@bugs.devuan.org (full text, mbox, reply):

Received: (at 749) by bugs.devuan.org; 11 Mar 2023 01:15:05 +0000
Return-Path: <plorenzo@disroot.org>
Delivered-To: bugs@devuan.org
Received: from email.devuan.org [2001:41d0:2:d06e::5c4:2612]
	by doc.devuan.org with IMAP (fetchmail-6.4.16)
	for <debbugs@localhost> (single-drop); Sat, 11 Mar 2023 01:15:05 +0000 (UTC)
Received: from email.devuan.org
	by email.devuan.org with LMTP
	id fXmOKw/WC2QxGwAAmSBk0A
	(envelope-from <plorenzo@disroot.org>)
	for <bugs@devuan.org>; Sat, 11 Mar 2023 01:14:55 +0000
Received: by email.devuan.org (Postfix, from userid 109)
	id 81959979; Sat, 11 Mar 2023 01:14:55 +0000 (UTC)
X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on email.devuan.org
X-Spam-Level: 
X-Spam-Status: No, score=0.2 required=5.0 tests=DKIM_INVALID,DKIM_SIGNED,
	SPF_PASS autolearn=no autolearn_force=no version=3.4.6
Received-SPF: Pass (mailfrom) identity=mailfrom; client-ip=178.21.23.139; helo=knopi.disroot.org; envelope-from=plorenzo@disroot.org; receiver=<UNKNOWN> 
Received: from knopi.disroot.org (knopi.disroot.org [178.21.23.139])
	by email.devuan.org (Postfix) with ESMTPS id 197CB63C
	for <749@bugs.devuan.org>; Sat, 11 Mar 2023 01:14:39 +0000 (UTC)
Received: from localhost (localhost [127.0.0.1])
	by disroot.org (Postfix) with ESMTP id AC6734206B;
	Sat, 11 Mar 2023 02:14:32 +0100 (CET)
X-Virus-Scanned: SPAM Filter at disroot.org
Received: from knopi.disroot.org ([127.0.0.1])
	by localhost (disroot.org [127.0.0.1]) (amavisd-new, port 10024)
	with ESMTP id uaOlfW9OfZXb; Sat, 11 Mar 2023 02:14:31 +0100 (CET)
Date: Sat, 11 Mar 2023 02:14:24 +0100
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=disroot.org; s=mail;
	t=1678497271; bh=gOY6WF6X8n454qdK6CEaeDyRq6uZzNP+OcdxTDjDxfA=;
	h=Date:From:To:Cc:Subject:In-Reply-To:References;
	b=iG22Skn5jVtvd+3zciiIeaAfa5G8TeFevdGA/yHidhzm0OdW98+Ry2D/Pohgp43FZ
	 sSn5L0KRQtGVO034Y4zbb+2JL2QAUKdHURbG0dCT/l5irGGRo5j3ISEOQCQmpHxKJO
	 9+YF9roOqv+ESxWWmfgbHh0D7yvg2+SHprLHUJNSvTx05rwsCMnKhQIxullfwImO9D
	 whJSzjCT+s3kqz2NMyFk7Zz8gRoc2TDzWx38IhMjXnCAYeKCenFwqPeX1/3EWnDlmq
	 axjo+eNsddP3ZBUbkkyBSHK9a6pbJd/Gh4SkKlOpc5B644DcztDPb1Cne/6oqfV9LS
	 ACEEcBs62b5lg==
From: Lorenzo <plorenzo@disroot.org>
To: Mark Hindley <mark@hindley.org.uk>
Cc: Olaf Meeuwissen <paddy-hack@member.fsf.org>, 749@bugs.devuan.org
Subject: Re: bug#749: initscripts: /etc/init.d/halt calls halt with
 unsupported options
Message-ID: <20230311021424.3bdc23ed@lorenz.fritz.box>
In-Reply-To: <ZAiC8qoTfxxQnmYM@hindley.org.uk>
References: <874jqv5t46.fsf@basecamp>
	<ZAiC8qoTfxxQnmYM@hindley.org.uk>
MIME-Version: 1.0
Content-Type: text/plain; charset=US-ASCII
Content-Transfer-Encoding: 7bit
Hello,

On Wed, 8 Mar 2023 12:43:30 +0000
Mark Hindley <mark@hindley.org.uk> 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


Send a report that this bug log contains spam.


Devuan BTS -- Powered by Debian bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson,
2005-2017 Don Armstrong, and many other contributors.

Devuan Bugs Owner <owner@bugs.devuan.org>.
Last modified: Sun Nov 24 13:56:10 2024;