From upstream. http://groups.yahoo.com/group/amanda-hackers/message/4510 --- amanda-2.5.0p2/server-src/amverify.sh.in.orig 2006-03-28 23:10:06.000000000 +0200 +++ amanda-2.5.0p2/server-src/amverify.sh.in 2006-06-25 02:23:46.000000000 +0200 @@ -432,14 +432,16 @@ fi RESULT=`$AMRESTORE -h -p $DEVICE 2> $TEMP/amrestore.out \ | doonefile 2> $TEMP/onefile.errors` + # save previous filename to detect looping + FILE_prev="$FILE" FILE=`grep restoring $TEMP/amrestore.out \ | sed 's/^.*restoring //'` EOF=`grep "reached end of tape" $TEMP/amrestore.out` EOI=`grep "reached end of information" $TEMP/amrestore.out` # amrestore: 0: restoring sundae._mnt_sol1_usr.19961127.1 - if [ X"$FILE" != X"" -a X"$RESULT" = X"0" ]; then + if [ X"$FILE" != X"" -a X"$FILE" != X"$FILE_prev" -a X"$RESULT" = X"0" ]; then report "Checked $FILE" - elif [ X"$FILE" != X"" -a X"$RESULT" = X"500" ]; then + elif [ X"$FILE" != X"" -a X"$FILE" != X"$FILE_prev" -a X"$RESULT" = X"999" ]; then report "Skipped `cat $TEMP/onefile.cmd` check on partial dump $FILE" dump="`echo $FILE | cut -d'.' -f'1,2,3,4'`" cat $TEMP/onefile.partnum >> $TEMP/$dump.parts