Don,
I revised script but when I ran it I did not receive any log. I am not sure what you mean to run it in code tags. I am using a putty session and ssh but I did not get a trace log?
Barb
---------- Post updated at 01:33 PM ---------- Previous update was at 01:27 PM ----------
This is what I revised and it still looped with no log
#!/usr/bin/ksh
set -xv
ERRORDIR=/home/p611568/d2e/error_directory
while read -r i
do RECIPIENTS="$RECIPIENTS $i@stryder.aessuccess.org"
done < /home/p611568/d2e/xenos_scripts/emailparm] CODE
RECIPIENTS=bcarosi
find /home/p611568/d2e/logs/*.rpt -mtime -10 ! -name '*ftplog*' | while read -r r1
# find /home/p611568/d2e/logs/*.rpt -mtime -8 ! -name '*ftplog*' | while read -r r1
do if grep -q CompletionCode "$r1"
then
if ! grep CompletionCode "$r1" | grep -q "CompletionCode: Value=0"
then
( echo " There were errors in the following report file for Xenos:"
echo
echo "This files have been moved to $ERRORDIR"
echo "$r1"
) | mail -s "$r1" $RECIPIENTS
mv "$r1" "$ERRORDIR"
fi
fi
done