当前位置: 代码迷 >> Oracle管理 >> ora-12154,该怎么处理
  详细解决方案

ora-12154,该怎么处理

热度:303   发布时间:2016-04-24 05:05:41.0
ora-12154
# listener.ora Network Configuration File: C:\oracle\product\10.2.0\db_1\NETWORK\ADMIN\listener.ora
# Generated by Oracle configuration tools.

LISTENER1 =
  (DESCRIPTION =
  (ADDRESS = (PROTOCOL = TCP)(HOST = db767e10f7fd441)(PORT = 1522))
  )

SID_LIST_LISTENER =
  (SID_LIST =
  (SID_DESC =
  (SID_NAME = PLSExtProc)
  (ORACLE_HOME = C:\oracle\product\10.2.0\db_1)
  (PROGRAM = extproc)
  )
  )

SID_LIST_LISTENER1 =
  (SID_LIST =
  (SID_DESC =
  (GLOBAL_DBNAME = Oracle8)
  (SID_NAME = ORCL)
  )
  )

LISTENER =
  (DESCRIPTION_LIST =
  (DESCRIPTION =
  (ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC1))
  )
  (DESCRIPTION =
  (ADDRESS = (PROTOCOL = TCP)(HOST = db767e10f7fd441)(PORT = 1521))
  )
  )






# tnsnames.ora Network Configuration File: C:\oracle\product\10.2.0\db_1\network\admin\tnsnames.ora
# Generated by Oracle configuration tools.

OKC =
  (DESCRIPTION =
  (ADDRESS_LIST =
  (ADDRESS = (PROTOCOL = TCP)(HOST = db767e10f7fd441)(PORT = 1521))
  )
  (CONNECT_DATA =
  (SERVICE_NAME = orcl)
  )
  )

ORCL =
  (DESCRIPTION =
  (ADDRESS = (PROTOCOL = TCP)(HOST = db767e10f7fd441)(PORT = 1521))
  (CONNECT_DATA =
  (SERVER = DEDICATED)
  (SERVICE_NAME = orcl)
  )
  )

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


用Net Configuration Assistant添加了服务器名为OKC


进入sqlplus  
conn scott/tiger@OKC 报 ora:12154

------解决方案--------------------
LISTENER1 =
(DESCRIPTION =
(ADDRESS = (PROTOCOL = TCP)(HOST = db767e10f7fd441)(PORT = 1522))
)

OKC =
(DESCRIPTION =
(ADDRESS_LIST =
(ADDRESS = (PROTOCOL = TCP)(HOST = db767e10f7fd441)(PORT = 1521))

端口不一致阿
  相关解决方案