--- LVM2.2.02.85/scripts/lvm2_monitoring_init_red_hat.in 2011-10-05 21:36:47.152774996 +0200 +++ LVM2.2.02.95/scripts/lvm2_monitoring_init_red_hat.in 2012-04-18 18:11:44.000000000 +0300 @@ -1,3 +1,3 @@ -#!/bin/bash +#!/bin/sh # # Copyright (C) 2007-2009 Red Hat, Inc. All rights reserved. @@ -46,12 +46,19 @@ start() { - ret=0 + local ret=0 # TODO do we want to separate out already active groups only? VGSLIST=`$VGS --noheadings -o name --config 'log{command_names=0 prefix=" "}' 2> /dev/null` for vg in $VGSLIST do - action "Starting monitoring for VG $vg:" $VGCHANGE --monitor y --poll y --config 'log{command_names=0 prefix=" "}' $vg || ret=$? + msg_starting "Starting monitoring for VG $vg:"; busy + $VGCHANGE --monitor y --poll y --config 'log{command_names=0 prefix=" "}' $vg + ret=$? + if [ $ret -ne 0 ]; then + fail + return $ret + fi + ok done return $ret @@ -60,7 +67,7 @@ stop() { - ret=0 + local ret=0 # TODO do we want to separate out already active groups only? if test "$WARN" = "1"; then echo "Not stopping monitoring, this is a dangerous operation. Please use force-stop to override." @@ -69,7 +76,14 @@ VGSLIST=`$VGS --noheadings -o name --config 'log{command_names=0 prefix=" "}' 2> /dev/null` for vg in $VGSLIST do - action "Stopping monitoring for VG $vg:" $VGCHANGE --monitor n --config 'log{command_names=0 prefix=" "}' $vg || ret=$? + msg_stopping "Stopping monitoring for VG $vg:"; busy + $VGCHANGE --monitor n --config 'log{command_names=0 prefix=" "}' $vg + ret=$? + if [ $ret -ne 0 ]; then + fail + return $ret + fi + ok done return $ret } --- LVM2.2.02.94/scripts/lvm2_monitoring_systemd_red_hat.service.in~ 2012-02-01 15:08:39.000000000 +0200 +++ LVM2.2.02.94/scripts/lvm2_monitoring_systemd_red_hat.service.in 2012-03-29 00:12:31.886921407 +0300 @@ -1,7 +1,7 @@ [Unit] Description=Monitoring of LVM2 mirrors, snapshots etc. using dmeventd or progress polling Requires=dm-event.socket -After=dm-event.socket fedora-storage-init.service fedora-storage-init-late.service +After=dm-event.socket pld-storage-init.service pld-storage-init-late.service Before=local-fs.target DefaultDependencies=no Conflicts=shutdown.target