check_alertRCC1.sh
$ cat check_alertRCC1.sh
#!usr/bin/bash
tail -f /home/oracle/admin/RCC/bdump/alert_RCC1.log|
while read -r line
#echo "$line"
do
( [[ "$line" != *'Thread'* && "$line" != *'Current'* && "$line" != *'2013'* && "$line" != *'Global Enqueue Services Deadlock detected'* ]] )
if [ $? -ne 0 ]; then
echo -e "\033[32m $line \033[0m"
else
echo -e "\033[41m $line \033[0m"
echo -e "\07"
fi
done
Execute the shell script and check the output
$sh check_alertRCC1.sh
No comments:
Post a Comment