1 Index: new/debian/clvm.init
2 ===================================================================
3 --- new.orig/debian/clvm.init 2011-11-25 08:39:04.000000000 +0100
4 +++ new/debian/clvm.init 2011-11-25 08:42:54.000000000 +0100
7 # Required-Start: $remote_fs lvm2 cman
8 # Required-Stop: $remote_fs lvm2 cman
11 +# Default-Start: 2 3 4 5
12 +# Default-Stop: 0 1 6
13 # Short-Description: start and stop the lvm cluster locking daemon
17 . /lib/lsb/init-functions
19 if [ ! -f /etc/cluster/cluster.conf ]; then
20 - log_failure_msg "clvmd: cluster not configured. Aborting."
21 + log_action_msg "clvmd: cluster not configured"
25 -if ! cman_tool status >/dev/null 2>&1; then
26 - log_failure_msg "clvmd: cluster is not running. Aborting."
34 # Read configuration variable file if it is present
35 [ -r /etc/default/$NAME ] && . /etc/default/$NAME
37 +[ "$START_CLVM" = "yes" ] || exit 0
39 DAEMON_OPTS="-T$CLVMDTIMEOUT"
41 +if ! cman_tool status >/dev/null 2>&1; then
42 + log_failure_msg "clvmd: cluster is not running. Aborting."
48 - start-stop-daemon --start --quiet --exec $DAEMON -- $DAEMON_OPTS || status="$?"
49 + start-stop-daemon --start --quiet --exec $DAEMON -- $DAEMON_OPTS || return $?
51 vgscan > /dev/null 2>&1
58 if [ -n "$LVM_VGS" ] ; then
59 log_action_msg "Activating VGs $LVM_VGS"
60 vgchange -ayl $LVM_VGS || return $?
62 - log_action_msg "Activating all VGs"
63 - vgchange -ayl || return $?
70 1) log_action_msg " already running" ; log_end_msg 0 ;;
72 + *) log_end_msg 1 ; exit $status ;;
74 # and activate clustered volume groups
80 + pid=$( pidof $DAEMON )
81 + if [ -z "$pid" ] ; then
84 # deactivate volumes...
85 log_daemon_msg "Deactivating VG $vg:"
87 Index: new/debian/rules
88 ===================================================================
89 --- new.orig/debian/rules 2011-11-25 08:39:04.000000000 +0100
90 +++ new/debian/rules 2011-11-25 08:39:39.000000000 +0100
92 install_clvm: DIR = $(BUILD_DIR)/install_deb
93 install_clvm: $(STAMPS_DIR)/install_deb
94 +$(MAKE_SELF) install-base-prep INSTALL_DIR='$(DIR)'
95 - dh_installinit --no-start -- start 63 S . start 51 0 6 .
96 + dh_installinit --no-start -- start 63 2 3 4 5 . start 51 0 1 6 .
97 +$(MAKE_SELF) install-base
99 install_dmsetup: export DH_OPTIONS = -pdmsetup
100 Index: new/debian/clvm.default
101 ===================================================================
102 --- new.orig/debian/clvm.default 2011-11-25 08:39:04.000000000 +0100
103 +++ new/debian/clvm.default 2011-11-25 08:42:26.000000000 +0100
105 # Bourne shell compatible script, sourced by /etc/init.d/clvm to set
106 # additional arguments for clvmd.
115 # Volume groups to activate on startup:
116 # LVM_VGS="cluster_vg1 cluster_vg2"