# HG changeset patch # User heiko # Date 1163812701 0 # Node ID da03db987aae154871ab4371c4878faabce56575 # Parent b36b9eee9c41547bec98cf49b24ce6a9ba800535 Now we obey the files maintained by drbdlinks diff -r b36b9eee9c41 -r da03db987aae debian/changelog --- a/debian/changelog Fri Nov 17 21:32:29 2006 +0000 +++ b/debian/changelog Sat Nov 18 01:18:21 2006 +0000 @@ -1,3 +1,9 @@ +ha-sync (0.2-2) testing; urgency=low + + * depency on drbdlinks (1.07-1.ius) + + -- Heiko Schlittermann Sat, 18 Nov 2006 02:01:37 +0100 + ha-sync (0.2-1) testing; urgency=low * exclude list improved diff -r b36b9eee9c41 -r da03db987aae debian/control --- a/debian/control Fri Nov 17 21:32:29 2006 +0000 +++ b/debian/control Sat Nov 18 01:18:21 2006 +0000 @@ -7,6 +7,6 @@ Package: ha-sync Architecture: all -Depends: ${shlibs:Depends}, ${misc:Depends}, ucf, ssh, rsync, stow +Depends: ${shlibs:Depends}, ${misc:Depends}, ucf, ssh, rsync, stow, drbdlinks (= 1.07-1.ius) Description: sync script for ha cluster script helping to keep clusters in sync diff -r b36b9eee9c41 -r da03db987aae ha-sync --- a/ha-sync Fri Nov 17 21:32:29 2006 +0000 +++ b/ha-sync Sat Nov 18 01:18:21 2006 +0000 @@ -41,9 +41,15 @@ echo $NODES | tr ' ' '\n' | grep -v `hostname`; } +# extra exclude list +extra=`tempfile` +trap "rm -f $extra" EXIT +echo $extra >$extra # and exclude it! +drbdlinks list | sed 's/[[:space:]].*//' >>$extra + cd / || exit 1 for FS in ${FILESYSTEMS%/}/; do - ${opt_debug+echo} rsync ${opt_dry+-n} --exclude-from /etc/ha-sync/exclude --delete -Ravx .$FS `other`:/ + ${opt_debug+echo} rsync ${opt_dry+-n} --exclude-from $extra --exclude-from /etc/ha-sync/exclude --delete -Ravx .$FS `other`:/ done test "$opt_dry" || ${opt_debug+echo} ssh -i $SSHID `other` update-grub