From unknown Fri Mar 29 04:45:49 2024 X-Loop: owner@bugs.devuan.org Subject: bug#749: initscripts: /etc/init.d/halt calls halt with unsupported options Reply-To: Lorenzo , 749@bugs.devuan.org Resent-From: Lorenzo Resent-To: devuan-bugs@lists.dyne.org Resent-CC: Devuan Developers X-Loop: owner@bugs.devuan.org Resent-Date: Sat, 11 Mar 2023 01:16:02 +0000 Resent-Message-ID: Resent-Sender: owner@bugs.devuan.org X-Devuan-PR-Message: followup 749 X-Devuan-PR-Package: initscripts X-Devuan-PR-Keywords: References: <874jqv5t46.fsf@basecamp> <874jqv5t46.fsf@basecamp> X-Devuan-PR-Source: sysvinit Received: via spool by 749-submit@bugs.devuan.org id=B749.167849730520079 (code B ref 749); Sat, 11 Mar 2023 01:16:02 +0000 Received: (at 749) by bugs.devuan.org; 11 Mar 2023 01:15:05 +0000 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 (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 ) for ; 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= 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 To: Mark Hindley Cc: Olaf Meeuwissen , 749@bugs.devuan.org Message-ID: <20230311021424.3bdc23ed@lorenz.fritz.box> In-Reply-To: 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 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