Linux Oracle服务启动停止脚本与开机自启动(4)

b. service Oracle stop

SQL> Disconnected from Oracle Database 10g Enterprise Edition Release 10.2.0.1.0 - Production
With the Partitioning, OLAP and Data Mining options
[oracle@ORS ~]$ logout
[root@ORS ~]# service oracle stop
Stoping Oracle Listeners ...
Done.
Stoping Oracle Databases ...
Done.

[root@ORS ~]# su - oracle
[oracle@ORS ~]$ sqlplus "/as sysdba"

SQL*Plus: Release 10.2.0.1.0 - Production on Mon Nov 26 20:17:20 2012

Copyright (c) 1982, 2005, Oracle.  All rights reserved.

Connected to an idle instance.

SQL> set linesize 300;
SQL> set pagesize 30;
SQL> select * from scott.emp;
select * from scott.emp
*
ERROR at line 1:
ORA-01034: ORACLE not available


SQL>

Linux Oracle服务启动停止脚本与开机自启动

c. service oracle start

SQL> Disconnected
[oracle@ORS ~]$ logout
[root@ORS ~]# service oracle start
Starting Oracle Databases ...
Done
Starting Oracle Listeners ...
Done.
[root@ORS ~]#

Linux Oracle服务启动停止脚本与开机自启动

d. service oracle restart

[root@ORS ~]# service oracle restart
Stoping Oracle Listeners ...
Done.
Stoping Oracle Databases ...
Done.

Starting Oracle Databases ...
Done
Starting Oracle Listeners ...
Done.
[root@ORS ~]#

Linux Oracle服务启动停止脚本与开机自启动

至此,Oracle服务启动&停止脚本与开机自启动设置完毕。

CentOS 6.3(x32)下安装Oracle 10g R2

linux

内容版权声明:除非注明,否则皆为本站原创文章。

转载注明出处:http://www.heiqu.com/6177783b15b81051633fef9f1d6d7370.html