Topic: SQL*Plus and PL/SQL >> ORA-28576: lost RPC connection to external procedure agent during extproc
|
Disclaimer: The purpose of all dbapool forums including OCP and Other Oracle Certification forums is to help each other with specific issues but not to share dump and copyrighted exam content, materials or intellectual property.
You may review the entire Oracle Certification Program Candidate Agreement online Here.
|
|
|
|
| Title: ORA-28576: lost RPC connection to external procedure agent during extproc |
| Sachin |
Posted: Jun 04, 2007 02:32:02 PM |
Total Post: 1
Joined: Jun, 2007
|
Hi,
I am trying to implement an external procedure to call a bat file.
Hi,
I tried the example posted by you.
Here is what my code looks like
create or replace library libc_w as 'C:\WINDOWS\system32\kernel32.dll';
*************************
create or replace function WinExec( Cmdstr IN varchar2, Cmdwin binary_integer ) return
binary_integer as
external
library libc_w
name "WinExec"
language C
calling standard PASCAL
parameters ( Cmdstr string, Cmdwin int );
*************************
declare
rc binary_integer;
begin
rc := WinExec( 'D:\\AutoTest\\test.bat',0 );
DBMS_OUTPUT.put_line( 'return code='||rc );
end;
/
*************************
But this gives me the error
"ORA-28576: lost RPC connection to external procedure agent"
I have verified the listner.ora and tnsnames.ora files... they are correct
(I was able to run a 'DIR' command through C 'system()' function using msvcrt.dll)
Can you help me on this?
*************************
My final motive is to run a UNIX command on Oracle client machine through PL/SQL extproc.
I plan to use a flow like
PL/SQL --> WinExec (or CreateProcess) --> rsh --> Unix
I have configured and tried the following command form Windows cmd and succeeded.
'rsh 172.21.161.79 -l bld351 /home1/bld351/sachin/script
Any guidance on this would be great.
Thanks |
|
|
| Time Zone: EDT |
Send this thread to your friend |
|
|
|
|
Forum Rules & Description
Who Can Read The Forum? Any registered user or guest
Who Can Post New Topics? Any registered user
Who Can Post Replies? Any registered user
|
| |
Get FREE Magazines
|
Top 10 Forum User
|
| Murtuja Khokhar | 843 |
| Mohammed Taj | 746 |
| positive fanatic | 483 |
| Jayanta Sur | 479 |
| Vigyan Kaushik | 386 |
| Gitesh Trivedi | 322 |
| Gopu Gopi | 272 |
| neeraj sharma | 252 |
| Ramesh Jois | 245 |
| Bishal Khetan | 207 |
|
|