ORACLE telnet 1521 不通及ORA-12514: TNS: 监听程序当前无法识别连接描述符中请求的服务的解决

时间:2021-08-21 20:36:00

服务器上安装了oracle11g , 防火墙上已经增加1521 入站规则。但是内网客户端配置好了TNS无法连接。telnet 1521 不通。

需要在服务器上\product\10.2.0\db_1\NETWORK\ADMIN\listener.ora 修改

原来是:

LISTENER =  

  (DESCRIPTION =  

    (ADDRESS = (PROTOCOL = TCP)(HOST = localhost)(PORT = 1521))  

  )

修改为:

LISTENER =  

  (DESCRIPTION =  

    (ADDRESS = (PROTOCOL = TCP)(HOST =IP地址或机器名称)(PORT = ))  

  )  

PLSQL Developer 连接时:ORA-12514: TNS: 监听程序当前无法识别连接描述符中请求的服务

新增一个:SID_DESC  ORCL是服务名。注意区分大小写

SID_LIST_LISTENER =
(SID_LIST =
(SID_DESC =
(GLOBAL_DBNAME = ORCL)
(ORACLE_HOME =D:\app\Administrator\product\11.2.\dbhome_1)
(SID_NAME = ORCL)
) (SID_DESC =
(SID_NAME = CLRExtProc)
(ORACLE_HOME = D:\app\Administrator\product\11.2.\dbhome_1)
(PROGRAM = extproc)
(ENVS = "EXTPROC_DLLS=ONLY:D:\app\Administrator\product\11.2.0\dbhome_1\bin\oraclr11.dll")
)
)