Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #!/bin/bash
- export ORACLE_SID=orcl
- export ORAENV_ASK=NO
- check_stat=`ps -ef|grep ${ORACLE_SID}|grep pmon|wc -l`;
- oracle_num=`expr $check_stat`
- if [ $oracle_num -lt 1 ]
- then
- . oraenv
- rlwrap sqlplus sys/oracle as sysdba <<-EOF
- startup
- EOF
- else
- . oraenv
- rlwrap sqlplus sys/oracle as sysdba
- fi
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement