Subject: init: should-start/stop $remote_fs to init script
From: Simon Horman <horms@verge.net.au>
To: Petter Reinholdtsen <pere@hungry.com>, 459497@bugs.debian.org
Cc: linux-ha-dev@lists.linux-ha.org
Subject: [patch] init: add should-start/stop $remote_fs to init script
In-Reply-To: <2fly7b261cx.fsf@saruman.uio.no>

On Sun, Jan 06, 2008 at 11:22:22PM +0100, Petter Reinholdtsen wrote:

[snip]

> I notice the package depend on openhpid.  If heartbeat need openhpid
> to start before it in the boot, it should list it in required-start or
> should-start, depending on how hard the dependency should be.  And the
> same in required-stop or should-stop, if heartbeat need to stop before
> openhpid during shutdown.  I do not know the package enough to say.

Hi Petter,

I've looked into this breifly and I believe that the short answer is yes.

It seems that in Debian openhpid is a recomemdation of libopenhpi2 which
is a dependancy of heartbeat, and thus using should-start/should-stop in
the init script would be the most appropriate option. This should also
nicely cover other distributions with a loose package dependancy on
openhpid (the script in question is generic IIRC).

Acked-by: Petter Reinholdtsen <pere@hungry.com>
Signed-off-by: Simon Horman <horms@verge.net.au>

Index: heartbeat/heartbeat/init.d/heartbeat.in
===================================================================
--- heartbeat.orig/heartbeat/init.d/heartbeat.in	2008-01-07 11:53:23.000000000 +0900
+++ heartbeat/heartbeat/init.d/heartbeat.in	2008-01-07 11:54:17.000000000 +0900
@@ -37,8 +37,9 @@
 # Short-Description: High-availability services.
 # Provides: heartbeat HA
 # Required-Start: $remote_fs $network $time $syslog
-# Should-Start: ntp
+# Should-Start: ntp openhpid
 # Required-Stop: $remote_fs $network $time $syslog
+# Should-stop: openhpid
 # Default-Start: 2 3 4 5
 # Default-Stop: 0 1 6
 ### END INIT INFO
