NetBSD Problem Report #31060
From www@netbsd.org Wed Aug 24 17:11:22 2005
Return-Path: <www@netbsd.org>
Received: by narn.netbsd.org (Postfix, from userid 31301)
id 4F97F63B104; Wed, 24 Aug 2005 17:11:22 +0000 (UTC)
Message-Id: <20050824171122.4F97F63B104@narn.netbsd.org>
Date: Wed, 24 Aug 2005 17:11:22 +0000 (UTC)
From: eravin@panix.com
Reply-To: eravin@panix.com
To: gnats-bugs@netbsd.org
Subject: /etc/rc.d/ntpdate and virecover have "status" commands when they shouldn't
X-Send-Pr-Version: www-1.0
>Number: 31060
>Category: bin
>Synopsis: /etc/rc.d/ntpdate and virecover have "status" commands when they shouldn't
>Confidential: no
>Severity: non-critical
>Priority: medium
>Responsible: bin-bug-people
>State: feedback
>Class: sw-bug
>Submitter-Id: net
>Arrival-Date: Wed Aug 24 17:12:00 +0000 2005
>Closed-Date:
>Last-Modified: Fri May 02 18:54:15 +0000 2025
>Originator: Ed Ravin
>Release: 2.0
>Organization:
Public Access Networks
>Environment:
NetBSD panix5.panix.com 2.0 NetBSD 2.0 (PANIX-USER) #3: Thu Jan 13 20:20:38 EST
2005 root@trinity.nyc.access.net:/devel/netbsd/2.0/src/sys/arch/i386/compile/PANIX-USER i386
>Description:
The rc.d scrpts ntpdate and virecover, have "status" commands even though there is no running daemon associated with the startup script (the two scripts, like /etc/rc.d/network or /etc/rc.d/ldconfig, perform boot-time tasks and do not start any daemons). For example:
root@localhost ~: # /etc/rc.d/virecover status
virecover is not running.
It looks like this is happening because the variable "command"
is set in these scripts, and rc.subr, when it sees "command", assumes
there will be a running daemon.
>How-To-Repeat:
>Fix:
Don't use $command in those scripts - rename it to $onetimecommand
or the like.
>Release-Note:
>Audit-Trail:
From: "Jeremy C. Reed" <reed@netbsd.org>
To: gnats-bugs@gnats.NetBSD.org
Cc:
Subject: PR/31060 CVS commit: src/etc/rc.d
Date: Fri, 2 May 2025 18:49:03 +0000
Module Name: src
Committed By: reed
Date: Fri May 2 18:49:03 UTC 2025
Modified Files:
src/etc/rc.d: virecover
Log Message:
set command_interpreter in /etc/rc.d/virecover so status works
This was prompted by PR bin/31060
To generate a diff of this commit:
cvs rdiff -u -r1.8 -r1.9 src/etc/rc.d/virecover
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
State-Changed-From-To: open->feedback
State-Changed-By: reed@NetBSD.org
State-Changed-When: Fri, 02 May 2025 18:54:15 +0000
State-Changed-Why:
I believe the status is fine. For example, /etc/rc.d/ntpdate status can show:
ntpdate is running as pid 12310.
And I also made it so /etc/rc.d/virecover status now works.
I understand these are not long running daemons, but they potentially
could be long running and a status of the script can be shown.
As another idea, /etc/rc.d/virecover status could show if has any vi data
in recover state (X-vi-recover-path). But that would be a different task.
>Unformatted:
(Contact us)
$NetBSD: query-full-pr,v 1.49 2026/05/14 01:52:41 riastradh Exp $
$NetBSD: gnats_config.sh,v 1.10 2026/05/13 22:00:09 riastradh Exp $
Copyright © 1994-2026
The NetBSD Foundation, Inc. ALL RIGHTS RESERVED.