diff options
author | Mike Snitzer <snitzer@redhat.com> | 2009-05-29 18:34:10 +0000 |
---|---|---|
committer | Mike Snitzer <snitzer@redhat.com> | 2009-05-29 18:34:10 +0000 |
commit | 613a355c4b768a585634785316ef7cd992b02815 (patch) | |
tree | efe1242df8da6d4f3eed1973a7598970b56d4746 /scripts/clvmd_init_red_hat.in | |
parent | 5746e2e769aa8b8dd7f06ae4a73c2dfbaab537cc (diff) | |
download | lvm2-613a355c4b768a585634785316ef7cd992b02815.tar.gz lvm2-613a355c4b768a585634785316ef7cd992b02815.tar.xz lvm2-613a355c4b768a585634785316ef7cd992b02815.zip |
Fix rpmlint in clvmd initscript
Added missing LSB stanza lines.
Added reload capability.
Remaining warning (incoherent-init-script-name) is not relevant.
Diffstat (limited to 'scripts/clvmd_init_red_hat.in')
-rw-r--r-- | scripts/clvmd_init_red_hat.in | 29 |
1 files changed, 26 insertions, 3 deletions
diff --git a/scripts/clvmd_init_red_hat.in b/scripts/clvmd_init_red_hat.in index c77421b7..0ac4b35a 100644 --- a/scripts/clvmd_init_red_hat.in +++ b/scripts/clvmd_init_red_hat.in @@ -6,7 +6,12 @@ # For Red-Hat-based distributions such as Fedora, RHEL, CentOS. # ### BEGIN INIT INFO -# Provides: +# Provides: clvmd +# Required-Start: $local_fs +# Required-Stop: $local_fs +# Default-Start: 2 3 4 5 +# Default-Stop: 0 1 6 +# Short-Description: Clustered LVM Daemon ### END INIT INFO . /etc/init.d/functions @@ -109,6 +114,19 @@ wait_for_finish() fi } +reload() { + $DAEMON -R +} + +rh_status() { + status $DAEMON +} + +rh_status_q() { + rh_status >/dev/null 2>&1 +} + + rtrn=1 # See how we were called. @@ -134,15 +152,20 @@ case "$1" in rtrn=$? ;; + reload) + rh_status_q || exit 7 + reload + ;; + status) - status $DAEMON + rh_status rtrn=$? vols=$( $LVDISPLAY -C --nohead 2> /dev/null | awk '($3 ~ /....a./) {print $1}' ) echo active volumes: ${vols:-"(none)"} ;; *) - echo $"Usage: $0 {start|stop|restart|status}" + echo $"Usage: $0 {start|stop|restart|reload|status}" ;; esac |