#!/bin/bash . /home/oracle/.bash_profile export ORACLE_SID=$1 echo 'Start DB '$1 sqlplus / as sysdba <<EOF startup force exit EOF
#!/bin/bash . /home/oracle/.bash_profile export ORACLE_SID=$1 echo 'Stop DB '$1 sqlplus / as sysdba <<EOF shutdown immediate exit EOF
* * * * * /home/oracle/checkdb.sh &>/dev/null
#!/bin/bash ping -c 1 192.168.99.151 &>/dev/null || /home/oracle/dbstop.sh DBNAME
ping -c 1 192.168.99.151 &>/dev/null && java -jar optimizer.jar -c=o -b=DBNAME