cancel
Showing results for 
Search instead for 
Did you mean: 

how to register rfc server?

Former Member
0 Kudos

Hi,

perhaps the subject is a bit unclear, sorry..

I'm a newbie in the area of communication between r/3 application server and 3th party server. What I need is to invoke an execution of a program on the 3th party server context from an abap program on my r/3 appl. server, and vise versa.

We have no SAP gateway, XI, just a standard r/3 appl. system. There is no SAPGui installed on a 3th party server, just clean OS. I tried to deal a bit with rfcsdk kit, supplied with my SAPGui, but without success.

FYI: I have some experience with DCOM objects created from DCOM connector and registered and executed in a 3th party server context.

Could anyone please provide me a info (link, etc.) and, which is better, a working "ping-pong" example for such a communication?

Feel free to ask if something is unclear.

Many thanks in advance.

Regards,

Ivaylo Mutafchiev

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Thanks guys,

this doesn't help me for now. I think I should ask more specific question:

Using sm59 I have successfuly registered a program named "rfcexec" (just for a test purposes) as a rfc destination on <application server> and after pushing a button "Test connection" I have resulted success-log, but in case this program is registered as a destination on <explicit host> (in my case IP: 100.110.12.12, and the program is included in the path of the mentioned host), testing connection timed-out with the log attached below:

-


        • Trace file opened at 20050525 152649 FLE Daylight Ti, REL 46D,0,1805, VER 3

resize I/O buffer to 28000 bytes

>>>> [2] ISM_TST : TCP 10.110.12.12 >>> OPEN

>TS> Wed May 25 15:27:29 2005

======> CPIC-CALL: 'ThSAPECMINIT'

Timeout during connection setup (check that partner exists)

ABAP Programm: RSRFCPIN (Transaction: SM59)

User: IMUTAFCHIEV (Client: 100)

Destination: ISM_TST (handle: 2, convid , )

Error RFCIO_ERROR_SYSERROR in abrfcpic.c : 1355

CPIC-CALL: 'ThSAPECMINIT'

Timeout during connection setup (check that partner exists)

DEST =ISM_TST

HOST =10.110.12.12

PROG =rfcexec

>>>> [2] ISM_TST : TCP 10.110.12.12 >>> CLOSE abrfcio.c 643 (27577624)

-


My host is not firewalled (WinXP SP2 with firewall switched off - means at least ping from another pc is possible). So how to establish the rfc destination to the program 'rfcexec.exe' on explicit host IP 10.110.12.12?

FYI my test r/3 appl. server doesn't resolve my pc name, so only connect by ip is possible.

Perhaps I'm doing something wrong.

Any help would be highly appreciated.

Regards,

Ivaylo

P.S.

1. all provided links are usable, but doesn't help me with this particular problem. I asked more globaly at first (and was following the recomendations of html-help under 'RFC Programming in ABAP').

2. "Ping-pong" example means both Client and Server program in use. Idealy would be to have example for both client and server side, but I think I could manage client side, only server side makes me nuts...

Former Member
0 Kudos

hi,Mutafchiev

When programming with server side connection with R3, you'd make clear several things.

1) sap gateway: e.g. sapgwXX (XX is your system id)

2) you must have a program <b>running</b> on your 3nd party server .

3) server side is work as this way.

a. A program running as a server on 3nd party server as listener.

b. ABAP call a function>destination>non sap program

c. your server side program should handle the request, mapping function name, mapping data type.

There is excutable example programm is JCO ,.Net coonnector.

By the way, what specific language you use in your non-sap system.

And you'd better use some sap-connector instead of RFC, the connectors has good encapsulation of RFC.

Regards.

Former Member
0 Kudos

Hi,

it wasn't clear for me that I should have registered listener at 3th party server (even if it was so obvious!).

Well, the main problem was that I was trying to use the "name" of sap-gateway instead of its ip-address. And in our configuration my pc (used for a test 3th party server) and a sap-gateway is not visible by name, but only by ip.

Up to now I successfuly registered an rfc-server at a gateway, started a client demo test-program and stopped the server manualy from a client side (all these gotten as from the rfcsdk package).

>By the way, what specific language you use in your non-sap system.

It will probably be a c++. We didn't desided yet. We are at the begining of the project and I'm checking the bottlenecks and clues for now...

Further questions occure, but I'll try to investigate the problems by myself for now...

Thanks to all.

Regards,

Ivaylo

Answers (5)

Answers (5)

Former Member
0 Kudos

I am also trying to communicate my R/3 with a custom build java program residing in my laptop(where SAP GUI is installed).

Please let me know how do u register a program id through SM59?

I tried with a connection type 'T' and Registed server program option under TCP/IP Connection in SM59.

However it is showing time-out on test connection.

-Shibaji

Former Member
0 Kudos

Hi,

and sorry for a late answer - I was away for a while.

Well, if you still don't found solution, the right one is:

1. At 3th party side (in this case - yuor laptop) you should have started rfc server program as listener. It's purpose is to establish connection with your R/3 system and to wait for call.

2. There should be (list of) function(s) implemented in your rfc server, which might be called from R/3 side.

3. When registering rfc server, you use an ID of the connection (or name). That's the program ID, which should be used in SM59 in order to establish a connection from R/3 side to 3th party side (your laptop).

I found very usefull an RFCSDK, which is part of SapGUI 6.20. There are samples of RFC server, RFC client, and a lot more. There are also C code of all the samples.

What I did in my case was to get it working with a samples, supplied from SAP, and furthermore I wrote few own functions within my RFC server (C-program), which I call from R/3 environment to do the work I need.

Now I have my RFC server started on 3th party machine (no SapGUI, clean Win2k server) as service, implemented failover strategy and up and working pretty good.

Direct answer to your question is:

==================================

I use saprfc.ini at RFC server side to define destination ID, which is used as program ID in SM59.

Follow the steps:

(assuming yor destination ID is myDestinationID)

1. Create a new TCP/IP connection via SM59. Use connection type 'T'.

2. Use activation type 'Registration', but not 'Start'.

3. In the tab opened after you choose 'Activation' write the Program ID: 'myDestinationID'.

4. Save the connection.

5. Test the connection.

If the RFC server is correctly registered at R/3 (actually, at SAP gateway), you should get the timing results in SM59.

Hope this helps.

Ivaylo

jayanthi_jayaraman
Active Contributor
0 Kudos
Former Member
0 Kudos

hi,Mutafchiev

1) as Williams said, you should choose the <b>CONNECTOR</b> according to your 3nd party platform and launguage,for you do not have XI so you must make decision here.

2) As you said you wanna "ping-pong" example,I think you mean both <b>Client</b> side and <b>Server</b> side programming.

3) RFC server is register at tcode:sm59, simply you can use tcpip connection type to define your destination.

There are also many good weblogs about this topic in forum you can search in the forum.

Former Member
0 Kudos

Hi Ivaylo,

There are many ways to achieve what you want to achieve, some that come to mind include:

- classical RFC (using C or VB)

- COM/DCOM (using Dcom connector as you discussed

- Web services

- .NET

- Active X

- etc.

This is a difficult topic to discuss in a forum thread, but the following link takes you to RFC help:

http://help.sap.com/saphelp_erp2004/helpdata/en/b4/3f9e64bff38c4f9a19635f57eb4248/frameset.htm

(its under classical SAP technologies ABAP).

Brad

Former Member
0 Kudos

Hi Mutafchiev,

visit this link.. it may help..

http://help.sap.com/saphelp_erp2004/helpdata/en/22/043139488911d189490000e829fbbd/content.htm

Regards,

Narinder Hartala