echo
echo "DETECTING ERRORS WHEN DOWNLOADING DATA FROM CDS"
echo
for f in ../archives/LOG*txt;do 
    if [ "$(cat $f | grep "Download rate")" ];then
        continue 
    else 
        echo 
        echo "CHECKING LOG FILE $f"
        echo
        if [ "$(cat $f | grep "Error")" ] || [ "$(cat $f | grep "Exception")" ]; then 
            echo "ERROR to download"
            echo
            cat $f | grep -v "INFO" | grep -v "WARNING"
            echo
        else 
            echo "Still downloading"
        fi
        echo
        echo "<><><><><><><><><><><><><><>"
        echo
    fi
done
