Challenge of Day

Tuesday, December 23, 2008

ORA-28575: unable to open RPC connection to external procedure agent

Hello,
If you are in the middle of process of calling a COM+ object from within Oracle PL/SQL, you might receive this error message:

ORA-28575: unable to open RPC connection to external procedure agent

Most probably the reason for this error message is the misconfiguration of Oracle Listener. To configure Oracle Listener properly, you need to modify two fondamental files in your Oracle Home sub-folder, something like this:
c:\oracle\product\10.2.0\db_1\network\admin

First file is LISTENER.ORA. Here is the typical content you need to have for calling COM Object:
LISTENER =
(ADDRESS_LIST =
(ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC0))
(ADDRESS = (PROTOCOL = TCP)(HOST = localhost)(PORT = 1521))
)

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

Remember you should replace your SID (here qmos) and HOST (here localhost) with your specific DB information.

Second file is TNSNAMES.ORA:
Typically you will need to add this entry as first entry in this file:
EXTPROC_CONNECTION_DATA =
(DESCRIPTION =
(ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC0))
(CONNECT_DATA =
(SID = PLSExtProc)
(PRESENTATION = RO)
)
)


According to my experience, if you encountered this problem, use TNSPING command to make sure that EXTPROC_CONNECTION_DATA is accessible. Sometimes, changes in the setting of SQLNET.ORA file causes you need a qualified name (e.g .WORLD) at the end of EXTPROC_CONNECTION_DATA.


I have an extended document on calling COM objects within PL/SQL. You can reach it at http://www.khademi.com/document/docs.htm

Be a winner in your daily challenges
Ali Khademi
علي خادمي

0 Comments:

Post a Comment

Subscribe to Post Comments [Atom]

<< Home