Search This Blog

Total Pageviews

Saturday 2 June 2012


Unix Monitor Oracle Process ..... 

unix shell script 



#!/bin/bash 
ps -ef | grep -i mrp|grep -v grep|wc -l> /u01/app/ora/admin/logs/Pstandby.log 
if [ `cat /u01/app/ora/admin/logs/Pstandby.log|grep -v grep|grep -i "1"|wc -l` -eq 1 ]; then 
exit 0 
else 
# echo "The process is not running" 
echo "Physical Standby process is not running on XXXXXXXX......." | /usr/bin/mailx -s "### server-name-instance Physical Standby `hostname` " "Oracle@gmail.com"
  
fi 


No comments:

Oracle DBA

anuj blog Archive