Problem
NLINK cannot connect to SAP system.
Solution - Common Errors
Missing User Id / Password
If you see the following error:CALL_FUNCTION_SIGNON_INCOMPLCoNNector:: SAP XXX CoNNector: Unable to log on to destination YYYY. Error message: KEY=CALL_FUNCTION_SIGNON_INCOMPL Message= Incomplete logon data..
Solution: Check your user id / password valuesWrong Client
If you see the following error:RFC_LOGON_FAILUREKey 'RFC_LOGON_FAILURE': Message 'Name or password is incorrect (repeat logon)'
Solution:
double-check your user id and password (passwords are case-sensitive)
verify that your user id exists in the client you are trying to connect to
- Problem connecting to load balanced SAP, Service Unknown
For outbound SAP connection such as SAP RFC/BAPI, SAP Query, SAP Transaction or SAP IDOC (IDOC sent from NLINK to SAP) External Systems, if following error occurs
RFC_LOGON_FAILUREKey=RFC_COMMUNICATION_FAILURE Message= LOCATION CPIC (TCP/IP) on local host SomeHostName with Unicode ERROR service '?' unknown TIME Wed Jul 1 10:22:59 2015 RELEASE 721 COMPONENT NI (network interface) VERSION 40 RC -3 DETAIL NiErrSet COUNTER 3
Solution: Specify the actual port value for MSSERV parameter, e.g., MSSERV=3601 instead of MSSERV=sapms01.
Service Unknown / GWSERV not found
In some cases the IDOC or RFC Listener connections fail to register properly, even if the proper GWSERV parameter is specified:
RFC_COMMUNICATION_FAILUREExternal System: CoNNector:: SAP IDOC CoNNector: Could not connect to SAP system. Will retry. SAP47U_IDOC: KEY=RFC_COMMUNICATION_FAILURE Message= ERROR service ’?’ unknown TIME Fri Sep 10 14:32:59 201 RELEASE 711 COMPONENT NI (network interface) VERSION 39 RC -3 DETAIL NiErrSet COUNTER 2 or External System: CoNNector:: SAP IDOC CoNNector: Could not connect to SAP system. Will retry. SAP47U_IDOC: KEY=RFC_COMMUNICATION_FAILURE Message= ERROR service ‘sapgw01’ unknown TIME Fri Sep 10 14:32:59 201 RELEASE 711 COMPONENT NI (network interface) VERSION 39 RC -3 MODULE nixxhsl.cpp LINE 665 DETAIL NiHsLGetServNo: service name cached as unknown COUNTER 1
Solution: Specify the actual port in the GWSERV parameter, e.g., GWSERV=3301 instead of GWSERV=sapgw01.WSAENOBUFS: No buffer space available
When trying to register RFC Listener or IDOC, the connection gets disconnected almost immediately. Get entries in log file similar to the following:"SAP RFC Listener CoNNector: Successfully connected to SAP system." "CoNNector:: SAP RFC Listener CoNNector: Unable to connect to SAP. Will retry." KEY=RFC_COMMUNICATION_FAILURE Message= ERROR internal error TIME WWW MMM DD HH:MM:SS 201 RELEASE NNN COMPONENT NI(network interface) VERSION NN RC -1 MODULE nixxi.cpp LINE 2781 DETAIL NiIConnectSocket SYSTEM CALL connect ERRNO 10055 ERRNO TEXT WSAENOBUFS: No buffer space available COUNTER 66722
Solution: This can be caused by SAP Gateway security rule that blocks requests from an external RFC Server.Invalid Parameter
If you see the following message,RFC_INVALID_PARAMETERKey 'RFC_INVALID_PARAMETER': Message 'Parameter ASHOST, GWHOST or MSHOST is missing.'
Solution: Check the format, spelling and completeness of the parameters in your SAPNWRFC.INI file. Refer to the sample file for correct entries.NLINK cannot process received IDOC
NLINK cannot process received IDOC. IT cannot resolve IDOC Type or Message Type properly, Event log shows IDOC Type ' ?????????????'Solution: In SAP transaction SM59, make sure corresponding RFC Destination is setup to use Unicode
RFC Listener or IDOC (receiving) disconnecting immediately after reconnect
When using IDOC or RFC Listener, the NLINK connection to SAP is broken (with RFC_COMMUNICATION_FAILURE error) as soon as reconnected message. Or on NLINK 6.0.0.140 (or earlier) NLINK crashes when using RFC Listener or IDOC connector (to receive IDOC). If you look at dev_rfc.trc or NLINK logs you can find message "registration of tp * from host * not allowed".
Solution: Check and make sure SAP Gateway allows connections to NLINK connections. If the SAP Gateway is setup to block incoming RFC function registration then SAP Gateway will allow connection to be established but breaks connection as soon as RFC function registration is attempted. NLINK 6.0.0.140 (or earlier) crash at start up with this issue. NLINK 6.0.0.142 (or later) reconnection attempts stop after 3 or more errors fast disconnects from SAP GatewayCannot Launch SAPGUI for Debugging
When trying to step into ABAP code for debugging, get an error ”SYSTEM_PREPARE_ATTACH_GUI not found”.
Solution: To use RFC with SAPGUI, the new library needs at least the following support packs to be installed:SAP_BASIS 46C SAPKB46C58
SAP_BASIS 620 SAPKB62066
SAP_BASIS 640 SAPKB64025
SAP_BASIS 700 SAPKB70020
SAP_BASIS 701 SAPKB70103
SAP_BASIS 710 SAPKB71008
SAP_BASIS 711 SAPKB71102
Can Connect via SAPGUI but not via NLINK
If you can connect from the NLINK machine via SAPGUI but not via NLINK, and you see the following error, check that ports 33xx are open.Key 'RFC_COMMUNICATION_FAILURE': Message ' LOCATION CPIC (TCP/IP) on local host with Unicode ERROR partner '111.22.333.44:33xx' not reached
Solution: The following ports must be open (where ## is the SAP system number):GUI (dispatcher, sapdp##): 32##
RFC (gateway, sapgw##): 33##
Load Balancing (message server, sapms##): 36##
Solution - Basic Checks
- Can the NLINK Server machine ping the SAP Server on the network?
Open a Windows command window and try to “ping” the network IP address of the SAP Server. For example, “ping 10.1.1.127”.
If there is no network connectivity then it will be impossible to connect. Contact your systems administrator if this test fails. - Does the sapnwrfc.ini exist?
Double-check that a sapnwrfc.ini file is located in the proper location and it is saved with UTF-8 encoding. - Are the sapnwrfc.ini parameters for the selected SAP destination correct?
Double-check that the information entered into the sapnwrfc.ini file is correct, properly spelled, and properly formatted.
Make sure the correct parameters are configured depending on the connection type. For example, a direct connection to an SAP “Application Server” requires different parameters than a connection to a “Load Balancing Server”.
Refer to the sample documentation included in the default file. - Is the SAP R/3 Server actually running?
Sometimes, SAP servers are taken down for maintenance or otherwise temporarily unavailable. Check with the SAP administrator that the SAP server is currently available for connection.
Solution - Advanced Checks
- When you run the connection test in NLINK are you seeing the message “Invalid UserId/Password” or is it something like “Password logon no longer possible – too many failed attempts”?
If it is the latter, then this is indicating that the UserId is locked by SAP. The local SAP administrator will need to reset the UserId. As a last step, it is possible to generate some detailed SAP trace logs to help diagnose the problem.
Edit the sapnwrfc.ini file (for whichever SAP system you are trying to connect to) and set “RFC_TRACE=1” (the default is RFC_TRACE=0).
SAP runtime library trace files may be in Windows Systems folder. If you run the test with SAP trace you will see 2 (or more) in that logs folder. The local SAP administrator can take a look at these log files to see if there is any issue. The SAP trace logs will be named "rfc*.trc" and dev_rfc.trc.Notes Regarding SAP Trace SettingsRemember to set RFC_TRACE=0 once connection testing is completed because SAP trace logs can very quickly become very large and should not be enabled during normal runtime operations.The DEFAULT section of the sapnwrfc.ini file includes a directive for settings the trace file directory, RFC_TRACE_DIR. However, this value is not always honored by the SAP library. Look for trace files in the C:\windows\system32 directory also.
Related articles