oracle db setting auto-bringup

oracle 9i db setting auto-bringup
$ vi /etc/oratab
*:/uxdb/ora9i/product/9.2:N
ora9i:/uxdb/ora9i/product/9.2:Y--indicates database would be bought up at system boot time.
[oracle@rac1 lib]$ dbstart
Database "orcl" already started.
Database "orcl" possibly left running when system went down (system crash?).
Notify Database Administrator.
SQL*Plus: Release 9.2.0.4.0 - Production on Tue Jan 18 04:09:37 2011
Copyright (c) 1982, 2002, Oracle Corporation.  All rights reserved.
SQL> Connected.
SQL> ORACLE instance shut down.
SQL> Disconnected from Oracle9i Enterprise Edition Release 9.2.0.4.0 - Productio                                                                      n
With the Partitioning, OLAP and Oracle Data Mining options
JServer Release 9.2.0.4.0 - Production
Can't find init file for Database "orcl".
Database "orcl" NOT started.
solution:
[oracle@rac1 lib]$ sqlplus '/as sysdba'
SQL*Plus: Release 9.2.0.4.0 - Production on Tue Jan 18 04:14:45 2011
Copyright (c) 1982, 2002, Oracle Corporation.  All rights reserved.

Connected to:
Oracle9i Enterprise Edition Release 9.2.0.4.0 - Production
With the Partitioning, OLAP and Oracle Data Mining options
JServer Release 9.2.0.4.0 - Production
SQL> shutdown immediate
Database closed.
Database dismounted.
ORACLE instance shut down.
SQL> exit
Disconnected from Oracle9i Enterprise Edition Release 9.2.0.4.0 - Production
With the Partitioning, OLAP and Oracle Data Mining options
JServer Release 9.2.0.4.0 - Production
[oracle@rac1 lib]$ cd /u01/app/oracle/db9i/dbs/
[oracle@rac1 dbs]$ ls
initdw.ora  init.ora  initorcl.ora  lkORCL  orapworcl  spfileorcl.ora
or
create init file by manual
[oracle@rac1 dbs]$ dbstart
SQL*Plus: Release 9.2.0.4.0 - Production on Tue Jan 18 04:15:09 2011
Copyright (c) 1982, 2002, Oracle Corporation.  All rights reserved.
SQL> Connected to an idle instance.
SQL> ORACLE instance started.
Total System Global Area  236000356 bytes
Fixed Size                   451684 bytes
Variable Size             201326592 bytes
Database Buffers           33554432 bytes
Redo Buffers                 667648 bytes
Database mounted.
Database opened.
SQL> Disconnected from Oracle9i Enterprise Edition Release 9.2.0.4.0 - Productio                                                                      n
With the Partitioning, OLAP and Oracle Data Mining options
JServer Release 9.2.0.4.0 - Production
Database "orcl" warm started.
[oracle@rac1 bin]$ dbshut
SQL*Plus: Release 9.2.0.4.0 - Production on Tue Jan 18 04:24:31 2011
Copyright (c) 1982, 2002, Oracle Corporation.  All rights reserved.
SQL> Connected.
SQL> Database closed.
Database dismounted.
ORACLE instance shut down.
SQL> Disconnected from Oracle9i Enterprise Edition Release 9.2.0.4.0 - Production
With the Partitioning, OLAP and Oracle Data Mining options
JServer Release 9.2.0.4.0 - Production
Database "orcl" shut down.

question2:
[oracle@rac1 bin]$ lsnrctl start
LSNRCTL for Linux: Version 9.2.0.4.0 - Production on 18-JAN-2011 04:27:21
Copyright (c) 1991, 2002, Oracle Corporation.  All rights reserved.
Starting /u01/app/oracle/db9i/bin/tnslsnr: please wait...
TNSLSNR for Linux: Version 9.2.0.4.0 - Production
System parameter file is /u01/app/oracle/db9i/network/admin/listener.ora
Log messages written to /u01/app/oracle/db9i/network/log/listener.log
Listening on: (DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(KEY=EXTPROC)))
Error listening on: (DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=rac1)(PORT=1521)))
TNS-12545: Connect failed because target host or object does not exist
 TNS-12560: TNS:protocol adapter error
  TNS-00515: Connect failed because target host or object does not exist
   Linux Error: 99: Cannot assign requested address
Listener failed to start. See the error message(s) above...
solution:
vi /etc/hosts--add host   ip   hostname
[oracle@rac1 bin]$ lsnrctl start
LSNRCTL for Linux: Version 9.2.0.4.0 - Production on 18-JAN-2011 04:27:53
Copyright (c) 1991, 2002, Oracle Corporation.  All rights reserved.
Starting /u01/app/oracle/db9i/bin/tnslsnr: please wait...
TNSLSNR for Linux: Version 9.2.0.4.0 - Production
System parameter file is /u01/app/oracle/db9i/network/admin/listener.ora
Log messages written to /u01/app/oracle/db9i/network/log/listener.log
Listening on: (DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(KEY=EXTPROC)))
Listening on: (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=rac1)(PORT=1521)))
Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=IPC)(KEY=EXTPROC)))
STATUS of the LISTENER
------------------------
Alias                     LISTENER
Version                   TNSLSNR for Linux: Version 9.2.0.4.0 - Production
Start Date                18-JAN-2011 04:27:53
Uptime                    0 days 0 hr. 0 min. 0 sec
Trace Level               off
Security                  OFF
SNMP                      OFF
Listener Parameter File   /u01/app/oracle/db9i/network/admin/listener.ora
Listener Log File         /u01/app/oracle/db9i/network/log/listener.log
Listening Endpoints Summary...
  (DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(KEY=EXTPROC)))
  (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=rac1)(PORT=1521)))
Services Summary...
Service "PLSExtProc" has 1 instance(s).
  Instance "PLSExtProc", status UNKNOWN, has 1 handler(s) for this service...
The command completed successfully

finally add follow command to /etc/rc.d/rc.local:
su - oracle -c "lsnrctl start"
su - oracle -c "dbstart"
su - oracle -c "agentctl start"
 
other method
设置service

来自 “ ITPUB博客 ” ,链接:http://blog.itpub.net/21993926/viewspace-684127/,如需转载,请注明出处,否则将追究法律责任。

转载于:http://blog.itpub.net/21993926/viewspace-684127/

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值