From: Eric Bollengier Date: Thu, 16 Feb 2023 14:45:48 +0000 (+0100) Subject: Fix #9882 About tapealert script issue on rhel8 X-Git-Tag: Release-13.0.2~2 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=b677c0739d72a08997623d76bcc386bf37efd12e;p=thirdparty%2Fbacula.git Fix #9882 About tapealert script issue on rhel8 Thanks Oliver Schonefeld --- diff --git a/bacula/scripts/tapealert b/bacula/scripts/tapealert index c8c68c0ad..42a3dd4e1 100755 --- a/bacula/scripts/tapealert +++ b/bacula/scripts/tapealert @@ -34,13 +34,17 @@ fi if [ x$DEBUG = x ] ; then -$tapeinfo -f $1 |grep "^TapeAlert" - |cut -b1-13 -exit $? +out=`mktemp` +$tapeinfo -f $1 >$out +ret=$? +awk '/^TapeAlert/ { $1=""; gsub(/^ */, "", $0); print $0 }' $out +rm -f $out +exit $ret else # For testing only -cat <