With this script you can check, for example – for every hour in alert log is there some new ORA errors, and in case new errors are generated, you will receive email notification about. Of course if AlertLog is too big (for example bigger than 2GB), you can archive it (rename je safe option alse) so the new one can be generated from zero after first iteration (to generate it manually you can run as sysdba: ALTER SYSTEM SWITCH LOGFILE). In this case Oracle is installed with this manual (Oracle 12c, CentOS 7, single instance).

#!/bin/bash
#########################################################################################
# Description: Script for hourly acheck of alert log for newly created ORA errors with 
# email reporting in case of new ORA errors (you need to have mailx installed)
# Author: Kompjuteras.com - you are free to change or use script however you like
#
# Crontab example:
# 00  *  *  *  *  /root/skripte/AlertLogCheck.sh > /tmp/CrontabAlertLogCheck.log 2>&1
#
#########################################################################################

shopt -s expand_aliases           # In case if mailx use some variables
source /home/oracle/.bash_profile # To use original oracle variables

########################### VARIABLES ##################################
FRIENDLY_SERVER_NAME="PROD_$( echo `hostname -s` | tr [:lower:] [:upper:] ) - `ip addr | grep 'state UP' -A2 | grep 'inet ' | tail -n1 | awk '{print $2}' | cut -f1  -d'/'`"
ALERT_LOG_LOCATION="${ORACLE_BASE}/diag/rdbms/${ORACLE_UNQNAME}/${ORACLE_SID}/trace/alert_${ORACLE_SID}.log"
ARHIVE_OF_ORA_ERRORS="/home/oracle/.AlertLogArhivaGresaka.log"
TEMPORARY_LOG_WITH_ORA_ERRORS="/tmp/AlertLogPrivremenaProvera.log"
MAIL_TO="myemail@myaddress.com"
#########################################################################

# Do you have all needed variables?
if [ -z "${ORACLE_SID}" ]     ; then echo "Variable missing: ORACLE_SID.     Exit" ; exit 100 ; fi
if [ -z "${ORACLE_BASE}" ]    ; then echo "Variable missing: ORACLE_BASE.    Exit" ; exit 101 ; fi
if [ -z "${ORACLE_UNQNAME}" ] ; then echo "Variable missing: ORACLE_UNQNAME. Exit" ; exit 102 ; fi

# Check all lines in alert log beggeing with ORA-
touch ${ARHIVE_OF_ORA_ERRORS}
grep -n "^ORA-" ${ALERT_LOG_LOCATION} > ${TEMPORARY_LOG_WITH_ORA_ERRORS}

# Find last lines from logs and put values to zero if there are no logs for some reason
LAST_LINE_FROM_ARCHIVE="`tail -n1 ${ARHIVE_OF_ORA_ERRORS} | cut -d: -f1 2>/dev/null`"
LAST_LINE_FROM_TEMP="   `tail -n1 ${TEMPORARY_LOG_WITH_ORA_ERRORS} | cut -d: -f1 2>/dev/null`"
if [ -z ${LAST_LINE_FROM_ARCHIVE} ] ; then LAST_LINE_FROM_ARCHIVE=0 ; fi
if [ -z ${LAST_LINE_FROM_TEMP} ] ; then LAST_LINE_FROM_TEMP=0 ; fi

# Visual check - will be used for crontab log
date ; echo LAST_LINE_FROM_ARCHIVE=$LAST_LINE_FROM_ARCHIVE ; echo LAST_LINE_FROM_TEMP=$LAST_LINE_FROM_TEMP

# Check processing - if last line are different
if [ "${LAST_LINE_FROM_ARCHIVE}" -ne "${LAST_LINE_FROM_TEMP}" ] ; then
        if [ ${LAST_LINE_FROM_ARCHIVE} -eq 0 ] ; then
        cat ${TEMPORARY_LOG_WITH_ORA_ERRORS} >> ${ARHIVE_OF_ORA_ERRORS}
        tac ${TEMPORARY_LOG_WITH_ORA_ERRORS} | mail -s "${FRIENDLY_SERVER_NAME}: Check of all ORA errors from start" ${MAIL_TO}
        exit 0
        fi
echo "Please check full log in ${ALERT_LOG_LOCATION}.
=====================================================
`grep -A900000 "${LAST_LINE_FROM_ARCHIVE}:" ${TEMPORARY_LOG_WITH_ORA_ERRORS} | grep -v "${LAST_LINE_FROM_ARCHIVE}:"`
=====================================================
" | mail -s "${FRIENDLY_SERVER_NAME}: New ORA errors in AlertLog" ${MAIL_TO}
# ------- Apend of new errors to archive -----------
grep -A900000 "${LAST_LINE_FROM_ARCHIVE}:" ${TEMPORARY_LOG_WITH_ORA_ERRORS} | grep -v "${LAST_LINE_FROM_ARCHIVE}:" >> ${ARHIVE_OF_ORA_ERRORS}
fi

exit 0