2012-6-13 09:22:16 |只看该作者 |倒序浏览
本帖最后由 onlyarumor 于 2012-6-13 09:25 编辑
我的OS是XP,在本地装了ORACLE,当时忘了怎么装上去的,一个是本地的叫LJB,另一个叫QJMOTOR(这个就跟装在别的机器上一样),shutdown后,想把日志改到archivelog方式,没办法启动到mount状态
操作如下:
C:\Documents and Settings\Administrator>sqlplus /nolog
SQL*Plus: Release 10.2.0.1.0 - Production on 星期三 6月 13 09:13:34 2012
Copyright (c) 1982, 2005, Oracle. All rights reserved.
SQL> conn sys/qjmotor@qjmotor as sysdba;
已连接。
SQL> shutdown immediate;
数据库已经关闭。
已经卸载数据库。
ORACLE 例程已经关闭。
SQL> startup mount;
ORA-12514: TNS: 监听程序当前无法识别连接描述符中请求的服务
接着查阅了一些解决办法,修改了listener.ora,如下红色文字部分,重启llistener服务,还是和上面的结果一样
贴出listener.ora 修改部分如下:
SID_LIST_LISTENER =
(SID_LIST =
(SID_DESC =
(SID_NAME = PLSExtProc)
(ORACLE_HOME = D:\oracle\product\10.2.0\db_1)
(PROGRAM = extproc)
)
(SID_DESC =
(GLOBAL_DBNAME = QJMOTOR)
(ORACLE_HOME = D:\oracle\product\10.2.0\db_1)
(SID_NAME = QJMOTOR)
)
)
LISTENER =
(DESCRIPTION_LIST =
(DESCRIPTION =
(ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC1))
(ADDRESS = (PROTOCOL = TCP)(HOST = PC-201006251613)(PORT = 1521))
)
)
接着查看服务状态
C:\Documents and Settings\Administrator>lsnrctl service
LSNRCTL for 32-bit Windows: Version 10.2.0.1.0 - Production on 13-6月 -2012 09:2
4:50
Copyright (c) 1991, 2005, Oracle. All rights reserved.
正在连接到 (DESCRIPTION=(ADDRESS=(PROTOCOL=IPC)(KEY=EXTPROC1)))
服务摘要..
服务 "PLSExtProc" 包含 1 个例程。
例程 "PLSExtProc", 状态 UNKNOWN, 包含此服务的 1 个处理程序...
处理程序:
"DEDICATED" 已建立:0 已被拒绝:0
LOCAL SERVER
服务 "QJMOTOR" 包含 1 个例程。
例程 "QJMOTOR", 状态 UNKNOWN, 包含此服务的 1 个处理程序...
处理程序:
"DEDICATED" 已建立:208 已被拒绝:1
LOCAL SERVER
命令执行成功
我再贴出tnsnames.ora的内容
QJMOTOR =
(DESCRIPTION =
(ADDRESS = (PROTOCOL = TCP)(HOST = PC-201006251613)(PORT = 1521))
(CONNECT_DATA =
(SERVER = DEDICATED)
(SERVICE_NAME = qjmotor.com)
)
)
LJB =
(DESCRIPTION =
(ADDRESS = (PROTOCOL = TCP)(HOST = PC-201006251613)(PORT = 1521))
(CONNECT_DATA =
(SERVER = DEDICATED)
(SERVICE_NAME = ljb.com)
)
)
EXTPROC_CONNECTION_DATA =
(DESCRIPTION =
(ADDRESS_LIST =
(ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC1))
)
(CONNECT_DATA =
(SID = PLSExtProc)
(PRESENTATION = RO)
)
)
能帮我把QJMOTOR这个数据库启动到mount状态吗?
==========================================================
QJMOTOR =
(DESCRIPTION =
(ADDRESS = (PROTOCOL = TCP)(HOST = PC-201006251613)(PORT = 1521))
(CONNECT_DATA =
(SERVER = DEDICATED)
(SERVICE_NAME = QJMOTOR )
)
)
提问的智慧 for Oracle[展开版]
提问的智慧Oracle版
0。尝试在google,论坛,metalink,online document里搜索。
1。写清楚你的执行log,报错信息,写清楚DB version , OS
2。Instance 方面的问题,请贴出alertlog
3。network的问题,贴出server的listener.ora , sqlnet.ora 并运行lsnrctl service, 贴出client的tnsnames.ora , sqlnet.ora ,并运行tnsping
4。DB总体性能问题,请上传peak time的AWR report和ASSH report。同时附上CPU/MEM配置,以及CPU IDLE/free menory的情况
5。SQL性能问题,列出当前SQL,以及PLAN。同时应提供表结构,index情况,Table的record数。CBO/RBO,table是否analyze等信息。
6。确保你的问题是Oracle相关。
--------------------------------
rollingpig 发表于 2012-6-13 11:07
QJMOTOR =
(DESCRIPTION =
(ADDRESS = (PROTOCOL = TCP)(HOST = PC-201006251613)(PORT = 1521))
SERVICE_NAME = QJMOTOR
改了这个就好了,非常感激,请问为什么安装的时候会给我变成SERVICE_NAME = QJMOTOR.COM呢?
还是我安装的时候啥地方配置错误的原因?
---------------------------------
本地连接用啥tns,直接sqlplus "/ as sysdba"