1)启动脚本(dbstart.sh)

lsnrctl start
sqlplus /nolog <<EOF
connect / as sysdba
startup;
exit
EOF

$sh dbstart.sh 即可

----------

2)关闭脚本(dbstop.sh)
  
lsnrctl stop
sqlplus /nolog <<EOF
connect / as sysdba
shutdown immediate;
exit
EOF

$sh dbstop.sh 即可

posted on 2016-01-12 03:33  fengyexjtu  阅读(160)  评论(0编辑  收藏  举报