19 August, 2016

Monitoring a URL script

export PATH=$PATH:/usr/local/bin
rm /tmp/discourl_chk.out

curl -sSf http://oracle-1.google.com:8090/discoverer/viewer > /tmp/discourl_chk.out

if [ $? -ne 0 ]; then
            ERROR_SUBJECT="CRITICAL: DISCO URL NOT REACHABLE - http://oracle-1.google.com:8090/discoverer/viewer "
                /usr/bin/mailx -s "$ERROR_SUBJECT" remote_dba@gmail.com,dba@gmail.com < /tmp/discourl_chk.out
else
        echo "NO ERROR, URL is accessible! Relax"
fi

No comments:

Post a Comment

Finding OPP Manager log for a concurrent request

=> Use below query to find the OPP manager log for a concurrent request.  SELECT fcpp.concurrent_request_id req_id, fcp.node_name, fcp.lo...