我们在Windows 2019上安装了Oracle 12c --安装在Windows Server 2016和MS SQL Server 2017上。
当我们尝试通过SMSOUT@ -> 中的选择计数(*)使用来自Oracle的数据库链接时,我们会得到以下错误:
ORA-28545: error diagnosed by Net8 when connecting to an agent
Unable to retrieve text of NETWORK/NCR message 65535
ORA-02063: preceding 2 lines from TOSIMSQLSERVER
28545. 0000 - "error diagnosed by Net8 when connecting to an agent"
*Cause: An attempt to call an external procedure or to issue SQL
to a non-Oracle system on a Heterogeneous Services database link
failed at connection initialization. The error diagnosed
by Net8 NCR software is reported separately.
*Action: Refer to the Net8 NCRO error message. If this isn't clear,
check connection administrative setup in tnsnames.ora
and listener.ora for the service associated with the
Heterogeneous Services database link being used, or with
'extproc_connection_data' for an external procedure call.
Error at Line: 1 Column: 29数据库链接由创建数据库链接TOSIMSQLSERVER连接到"…our_pwd…“标识的"oms”使用'simsqlserver';
\hs\admin\initsimsqlserver.ora:
# This is a sample agent init file that contains the HS parameters that are
# needed for the Database Gateway for ODBC
#
# HS init parameters
#
HS_FDS_CONNECT_INFO = simsqlserver
HS_FDS_TRACE_LEVEL = OFF\network\admin\listener.ora:
# listener.ora Network Configuration File: C:\app\oracle\product\12.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 = C:\app\oracle\product\12.2.0\dbhome_1)
(PROGRAM = extproc)
(ENVS = "EXTPROC_DLLS=ONLY:C:\app\oracle\product\12.2.0\dbhome_1\bin\oraclr12.dll")
)
(SID_DESC =
(SID_NAME = simsqlserver)
(ORACLE_HOME = C:\app\oracle\product\12.2.0\dbhome_1)
(PROGRAM = dg4odbc)
)
)
LISTENER =
(DESCRIPTION_LIST =
(DESCRIPTION =
(ADDRESS = (PROTOCOL = TCP)(HOST = oracle12.pds.opds.cz)(PORT = 1521))
(ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC1521))
)
)\network\admin\tnsnames.ora:
# tnsnames.ora Network Configuration File: C:\app\oracle\product\12.2.0\dbhome_1\network\admin\tnsnames.ora
# Generated by Oracle configuration tools.
ORACLR_CONNECTION_DATA =
(DESCRIPTION =
(ADDRESS_LIST =
(ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC1521))
)
(CONNECT_DATA =
(SID = CLRExtProc)
(PRESENTATION = RO)
)
)
ORACLE =
(DESCRIPTION =
(ADDRESS = (PROTOCOL = TCP)(HOST = oracle12.pds.opds.cz)(PORT = 1521))
(CONNECT_DATA =
(SERVER = DEDICATED)
(SERVICE_NAME = oracle.pds.opds.cz)
)
)
LISTENER_ORACLE =
(ADDRESS = (PROTOCOL = TCP)(HOST = oracle12.pds.opds.cz)(PORT = 1521))
simsqlserver =
(DESCRIPTION =
(ADDRESS=(PROTOCOL=TCP)(HOST=oracle12.pds.opds.cz)(PORT=1521))
(CONNECT_DATA=(SID=simsqlserver))
(HS=OK)
)\network\admin\sqlnet.ora:
# sqlnet.ora Network Configuration File: C:\app\oracle\product\12.2.0\dbhome_1\network\admin\sqlnet.ora
# Generated by Oracle configuration tools.
# This file is actually generated by netca. But if customers choose to
# install "Software Only", this file wont exist and without the native
# authentication, they will not be able to connect to the database on NT.
SQLNET.AUTHENTICATION_SERVICES= (NTS)
NAMES.DIRECTORY_PATH= (TNSNAMES, EZCONNECT)有人能帮我找出哪里的问题吗?SQL数据源测试正常。另外,TNSPING到simsqlserver也可以。
编辑11.03.2020:我们的是:
Oracle Database 12c Enterprise Edition Release 12.2.0.1.0 - 64bit Production
PL/SQL Release 12.2.0.1.0 - Production
"CORE 12.2.0.1.0 Production"
TNS for 64-bit Windows: Version 12.2.0.1.0 - Production
NLSRTL Version 12.2.0.1.0 - Production在设置HS_FDS_TRACE_LEVEL = 16和lsnrctl stop + lsnrctl start之后,我们有以下日志:
\oracle\diag\rdbms\oracle\oracle\trace\alert_oracle.log:
2020-03-11T13:27:40.813789+01:00
HS: Unable to establish RPC connection to HS Agent...
HS: ... Agent SID = (DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=oracle12.pds.opds.cz)(PORT=1521))(CONNECT_DATA=(SID=simsqlserver))), NCR error = 65535 Unable to retrieve text of NETWORK/NCR message 65535
HS: Unable to establish RPC connection to HS Agent...
HS: ... Agent SID = (DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=oracle12.pds.opds.cz)(PORT=1521))(CONNECT_DATA=(SID=simsqlserver))), NCR error = 65535 Unable to retrieve text of NETWORK/NCR message 65535\oracle\diag\rdbms\oracle\oracle\alert\log.xml:
<msg time='2020-03-11T13:27:40.938+01:00' org_id='oracle' comp_id='rdbms'
type='UNKNOWN' level='16' host_id='ORACLE12'
host_addr='::1' module='SQL Developer' pid='2952'>
<txt>HS: Unable to establish RPC connection to HS Agent...
</txt>
</msg>
<msg time='2020-03-11T13:27:40.938+01:00' org_id='oracle' comp_id='rdbms'
type='UNKNOWN' level='16' host_id='ORACLE12'
host_addr='::1' module='SQL Developer' pid='2952'>
<txt>HS: ... Agent SID = (DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=oracle12.pds.opds.cz)(PORT=1521))(CONNECT_DATA=(SID=simsqlserver))), NCR error = 65535 Unable to retrieve text of NETWORK/NCR message 65535
</txt>
</msg>发布于 2020-03-17 11:12:34
https://stackoverflow.com/questions/60620726
复制相似问题