get info by week
This commit is contained in:
parent
0b614d02a8
commit
1239415279
@ -26,11 +26,13 @@ do
|
||||
cat $directory_host/output_*.txt |grep "${j}" |sort |uniq -c >> ${MAIL}
|
||||
echo "--------------" >> ${MAIL}
|
||||
done
|
||||
echo "nombre erreur 400 par IP : " >> ${MAIL}
|
||||
cat $log_access | awk -F "|" '{ if($2 == "400") print $1}' |sort |uniq -c >> ${MAIL}
|
||||
echo "--------" >> ${MAIL}
|
||||
echo "nombre erreur 404 par IP : " >> ${MAIL}
|
||||
cat $log_access | awk -F "|" '{ if($2 == "404") print $1}' |sort |uniq -c >> ${MAIL}
|
||||
ERROR=("400" "404")
|
||||
for j in ${ERROR[@]}
|
||||
do
|
||||
echo "nombre erreur ${j} par IP :" >> ${MAIL}
|
||||
cat $directory_host/${j}_* |sort |uniq -c >> ${MAIL}
|
||||
echo "----------------" >> ${MAIL}
|
||||
done
|
||||
cat ${MAIL} |mail -s "Rapport reverse proxy $DATE" valczebackup@gmail.com
|
||||
#rm $directory_host/*
|
||||
done
|
||||
|
Loading…
x
Reference in New Issue
Block a user