Script to check Oracle instance status

A small shell script to check instance status of oracle database.
$vi instanceup.sh
#!/bin/sh
SERVICE=’ora_pmon_orcl’
#replace ‘orcl’ with your sid
if ps -ef | grep -v grep | grep $SERVICE > /dev/null
then
echo “$SERVICE service running, everything is fine”
else
echo “$SERVICE is not running”
fi
$./instanceup.sh

Category: Shell Scripts

Tags:

Leave a Reply

Article by: Shadab Mohammad