posts - 0,  comments - 1,  trackbacks - 0


1.bash-2.05# su - oracle

2.$ sqlplus /nolog 启动SQLPlus无记录状态

SQL*Plus: Release 9.2.0.1.0 - Production on Wed Apr 18 11:24:22 2007

Copyright (c) 1982, 2002, Oracle Corporation.  All rights reserved.

SQL> connect /as sysdba 使用DBA身份登录
Connected.

3.sqlplus /nolog 和 connect /as sysdba 结合起来使用,可以使用sqlplus "/as sysdba"

SQL> shutdown immediate
Database closed.
Database dismounted.
ORACLE instance shut down.
SQL> startup 启动
\ORACLE instance started.

Total System Global Area  320308312 bytes
Fixed Size                   730200 bytes
Variable Size             285212672 bytes
Database Buffers           33554432 bytes
Redo Buffers                 811008 bytes

Database mounted.
Database opened.
  启动监听:exit-->lsnrctl-->start (没有启动则会提示监听没启动)
     
重启数据库时可能遇到的问题:

SQL> startup
ORACLE instance started.

Total System Global Area   43164544 bytes
Fixed Size                   729984 bytes
Variable Size              41943040 bytes
Database Buffers             204800 bytes
Redo Buffers                 286720 bytes
ORA-00205: error in identifying controlfile, check alert log for more info

1.数据库已经启动
SQL> startup
ORA-01081: cannot start already-running ORACLE - shut it down first

2.数据库启动时,需要使用startup mount
SQL> shutdown immediate
ORA-01507: database not mounted


ORACLE instance shut down.

3.数据库找不到初始文件,可以从spfileemipkf00.ora,拷贝相应的内容进行上传
SQL> startup
ORA-01078: failure in processing system parameters
LRM-00109: could not open parameter file '/export/home/oracle/product/9.2/dbs/initemipkf00.ora'

4.startup mount:把数据库启动到MOUNT重新建控制文件。

5.启动监听程序
LSNRCTL for Solaris: Version 9.2.0.1.0 - Production on 26-SEP-2007 09:41:10

Copyright (c) 1991, 2002, Oracle Corporation.  All rights reserved.

Starting /export/home/oracle/home/bin/tnslsnr: please wait...

TNSLSNR for Solaris: Version 9.2.0.1.0 - Production
System parameter file is /export/home/oracle/home/network/admin/listener.ora
Log messages written to /export/home/oracle/home/network/log/listener.log
Listening on: (DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(KEY=EXTPROC)))
Listening on: (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=emipkf00)(PORT=1521)))

Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=IPC)(KEY=EXTPROC)))
STATUS of the LISTENER
------------------------
Alias                     LISTENER
Version                   TNSLSNR for Solaris: Version 9.2.0.1.0 - Production
Start Date                26-SEP-2007 09:41:11
Uptime                    0 days 0 hr. 0 min. 0 sec
Trace Level               off
Security                  OFF
SNMP                      OFF
Listener Parameter File   /export/home/oracle/home/network/admin/listener.ora
Listener Log File         /export/home/oracle/home/network/log/listener.log
Listening Endpoints Summary...
  (DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(KEY=EXTPROC)))
  (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=emipkf00)(PORT=1521)))
Services Summary...
Service "ORCL" has 1 instance(s).
  Instance "emipkf00", status UNKNOWN, has 1 handler(s) for this service...
Service "PLSExtProc" has 1 instance(s).
  Instance "PLSExtProc", status UNKNOWN, has 1 handler(s) for this service...
The command completed successfully

6.启动时出现环境变量问题
SQL> startup
ORA-07217: sltln: environment variable cannot be evaluated.

解决方法:这个是由于oracle的环境变量没有配置好而导致的.
    可以到oracle的根目录下的.profile文件,增加相关参数。
    例如:ORACLE_SID=test
    ORCLE_BASE="/export/home/oracle"
    emipkf00是指本系统的名称,可以使用hostname命令查看

posted on 2007-10-16 17:30 狗狗他爹 阅读(894) 评论(0)  编辑  收藏 所属分类: oracle

只有注册用户登录后才能发表评论。


网站导航:
 

<2025年7月>
293012345
6789101112
13141516171819
20212223242526
272829303112
3456789

留言簿

文章分类

文章档案

收藏夹

manager

oracle

搜索

  •  

最新评论