欢迎您访问程序员文章站本站旨在为大家提供分享程序员计算机编程知识!
您现在的位置是: 首页  >  IT编程

数据库报ORA-12514

程序员文章站 2023-08-31 11:17:50
Listener refused the connection with the following error: ORA-12514, TNS:listener does not currently know of service requested in connect descriptor. ......

listener refused the connection with the following error: ora-12514, tns:listener does not currently know of service requested in connect descriptor.

原因:监听器配置问题,具体没搞懂,猜测是sid链接不匹配,监听器无法监听到orcl。

修改oracle安装目录下d:\app\xuannan\product\11.2.0\dbhome_1\network\admin\listener.ora文件

# listener.ora network configuration file: d:\app\xuannan\product\11.2.0\dbhome_1\network\admin\listener.ora
# generated by oracle configuration tools.

sid_list_listener =
(sid_list =
(sid_desc =
(sid_name = clrextproc)
(oracle_home = d:\app\xuannan\product\11.2.0\dbhome_1)
(program = extproc)
(envs = "extproc_dlls=only:d:\app\xuannan\product\11.2.0\dbhome_1\bin\oraclr11.dll")
)
(sid_desc =
(global_dbname = orcl)
(oracle_home = d:\app\xuannan\product\11.2.0\dbhome_1)
(sid_name = orcl)
)
)

listener =
(description_list =
(description =
(address = (protocol = ipc)(key = extproc1521))
(address = (protocol = tcp)(host = localhost)(port = 1521))
)
)

adr_base_listener = d:\app\xuannan

加上这一段就好了