3

好的,直到昨天一切正常,现在我突然收到此错误
ORA-12514:TNS:listener 目前不知道连接描述符中请求的服务
没有任何修改

XE =
  (DESCRIPTION =
(ADDRESS = (PROTOCOL = TCP)(HOST = jainam-2b1c493d)(PORT = 1521))
(CONNECT_DATA =
  (SERVER = DEDICATED)
  (SERVICE_NAME = XE)
)
)

EXTPROC_CONNECTION_DATA =
  (DESCRIPTION =
    (ADDRESS_LIST =
     (ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC1))
    )
    (CONNECT_DATA =
        (SID = PLSExtProc)
      (PRESENTATION = RO)
    )
  )

  ORACLR_CONNECTION_DATA = 
      (DESCRIPTION = 
     (ADDRESS_LIST = 
     (ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC1)) 
    ) 
     (CONNECT_DATA = 
   (SID = CLRExtProc) 
   (PRESENTATION = RO) 
 ) 
) 


我完全被卡住了,不知道该怎么办。我从这里尝试了帮助
http://dba-oracle.com/t_ora_12514_tns_listener_does_not_currently_know_service_requested.htm 但没有用。谢谢


编辑:
这是输出到lsnrctl service

Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=IPC)(KEY=EXTPROC1)))
Services Summary...
Service "CLRExtProc" has 1 instance(s).
  Instance "CLRExtProc", status UNKNOWN, has 3 handler(s) for this service...
    Handler(s):
      "DEDICATED" established:0 refused:0
         LOCAL SERVER
      "ORACLE SERVER" established:0 refused:0 current:0 max:25 state:ready
        CLRExtProc
     (ADDRESS=(PROTOCOL=ipc)(PIPENAME=\\.\pipe\NTN_6B4_641B624E_B22.ORA))
  "ORACLE SERVER" established:0 refused:0 current:0 max:25 state:ready
     CLRExtProc
     (ADDRESS=(PROTOCOL=ipc)(PIPENAME=\\.\pipe\NTN_6B4_641B624E_282.ORA))
Service "PLSExtProc" has 1 instance(s).
Instance "PLSExtProc", status UNKNOWN, has 1 handler(s) for this service...
Handler(s):
  "DEDICATED" established:0 refused:0
     LOCAL SERVER
Service "XEXDB" has 1 instance(s).
 Instance "xe", status READY, has 1 handler(s) for this service...
 Handler(s):
  "D000" established:0 refused:0 current:0 max:1022 state:ready
     DISPATCHER <machine: JAINAM-2B1C493D, pid: 3708>
     (ADDRESS=(PROTOCOL=tcp)(HOST=jainam-2b1c493d)(PORT=2763))
Service "xe" has 1 instance(s).
Instance "xe", status READY, has 1 handler(s) for this service...
Handler(s):
  "DEDICATED" established:0 refused:0 state:ready
     LOCAL SERVER
The command completed successfully
4

3 回答 3

5

对我来说,它有助于将以下 SID_DESC 添加到 C:\oraclexe\app\oracle\product\11.2.0\server\network\ADMIN\listener.ora

SID_LIST_LISTENER =
  (SID_LIST =
    ...
    (SID_DESC =
      (SID_NAME = XE)
      (ORACLE_HOME = C:\oraclexe\app\oracle\product\11.2.0\server)
    )
  )

重新启动侦听器和数据库后,访问再次起作用。

感谢http://grow-n-shine.blogspot.de/2011/11/oracle-11g-xe-issue-ora-12514.html

于 2014-06-23T13:22:50.293 回答
3

您收到此类错误的原因之一是因为数据库实例在侦听器之前启动。侦听器必须始终首先启动。

  1. 检查数据库实例是否已启动并正在运行
  2. 检查lsnrctl service命令的输出并查看注册了哪些服务。
  3. 检查SERVICE_NAME连接实例时是否正确指定。
  4. 如果发生数据库实例在侦听器之前启动的情况,有时您只需稍等片刻,或者您可以执行alter system register以注册实例。
于 2012-09-21T15:45:28.987 回答
3

打开 SQL Plus 并连接到系统用户:

system/p@ssword

并运行两个命令:

SQL> alter system set LOCAL_LISTENER='(ADDRESS=(PROTOCOL=TCP)(HOST=localhost)(PORT=1521))' scope=both;
SQL> alter system register;
于 2015-02-08T06:40:18.793 回答