oracle

Oracle12C基本操作记录

控制Oracle数据库启停的脚本
脚本必须放在主节点和从节点 /etc/sdata/scripts/


#Name stop.sh
#!/bin/sh
su - oracle <<EON
sqlplus /nolog <<EOF
conn / as sysdba
shutdown immediate
quit
EOF
lsnrctl stop
exit
EON


#Name start.sh
#!/bin/bash
su - oracle <<EON
lsnrctl start
sqlplus /nolog <<EOF
conn / as sysdba
startup
quit
EOF
exit
EON

*******************************

[oracle@oracle12c ~]$ sqlplus / as sysdba

标签
订阅 oracle