首页 > 代码库 > ORA-12505, TNS:listener does not currently know of SID given in connect desc
ORA-12505, TNS:listener does not currently know of SID given in connect desc
出现以上的问题是无法识别SID,解决方法如下:
1.找到以下目录,/opt/oracle/product/10.2.0/db_1/network/admin,修改listener.ora,(find -name listener.ora即可找到该文件)为:
# listener.ora Network Configuration File: /opt/oracle/product/10.2.0/db_1/network/admin/listener.ora # Generated by Oracle configuration tools. SID_LIST_LISTENER = (SID_LIST = (SID_DESC = (SID_NAME = PLSExtProc) (ORACLE_HOME = /opt/oracle/product/10.2.0/db_1) (PROGRAM = extproc) ) (SID_DESC = (GLOBAL_DBNAME = NIE) (ORACLE_HOME = /opt/oracle/product/10.2.0/db_1) (SID_NAME = NIE) ) ) LISTENER = (DESCRIPTION_LIST = (DESCRIPTION = (ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC3)) (ADDRESS = (PROTOCOL = TCP)(HOST = localhost.localdomain)(PORT = 1523)) ) )
添加红色字体部分,注意GLOBAL_DBNAME 和SID_NAME 改成你自己的。
2.启动TNS监听:lsnrctl start
3.查看监听状态:lsnrctl status
ORA-12505, TNS:listener does not currently know of SID given in connect desc
声明:以上内容来自用户投稿及互联网公开渠道收集整理发布,本网站不拥有所有权,未作人工编辑处理,也不承担相关法律责任,若内容有误或涉及侵权可进行投诉: 投诉/举报 工作人员会在5个工作日内联系你,一经查实,本站将立刻删除涉嫌侵权内容。