Connection String for SAP ECC + S/4HANA


This page describes the connection string settings for the following SAP systems.

Overcast uses the SAP .NET Connector 3.1 (NCO3.1) for connectivity with SAP systems and passes the connection string to the connector (after ACLs are checked) to open the connection. This connector requires SAP connection strings in the standard SAP connection string format. SAP connection strings are key/value pairs separated by whitepace. 

Entries into the Sensitive Part field will be stored encrypted in Salesforce. If you want to secure the username also, include it in the field separated by a semi-colon.

The <hostname> can be either an IP address or system name.


Format

Enter the following text into the Connection String field

ASHOST=<hostname> SAPROUTER=/H/<router1>/S/<port>/H/<router2>/S/<port> SYSNR=<system number> CLIENT=<client number> USER=<username>

Enter the following text into the Sensitive Part field

PASSWD=<password>

 

Sample

Enter the following text into the Connection String field

ASHOST=dev.mysap.com SYSNR=05 CLIENT=100 USER=user100

Enter the following text into the Sensitive Part field

PASSWD=mypassword

 

Sample using SAP Router

Enter the following text into the Connection String field

ASHOST=dev.mysap.com SAPROUTER=/H/10.100.15.1/S/3299 SYSNR=05 CLIENT=100 USER=user100

Enter the following text into the Sensitive Part field

PASSWD=mypassword

 

Each time you create or modify a connection string in Overcast, validate your connection by clicking the Check button to ensure the connection can be established successfully. 

 

Common Settings

These settings are the most commonly used for typical SAP system connection configurations.

 

Parameter Keys

Key Description
ASHOST Application Server Host
MSHOST Message Server Host (*see advanced settings)
SYSNR System Number
CLIENT Client Number
USER Username
PASSWD Password
SAPROUTER SAP Router

 

1. Go to the Connection Strings tab and select the New button.

 

2. Enter a Connection String Name and select "SAP" for Connection Type. Enter your Connection String and its Sensitive Part as described above, and select Save. Description and Named Credential are optional.

 

3. Select Check to validate your connection. A green checked circle will appear once a successful connection is established.


 

Advanced Settings

These settings are used for adjusting your connection to SAP. Many simultaneous connections to SAP through Overcast may require adjustments of the default values. After adjusting any setting, thorough testing is recommended.

 

Connection Idle Timeout

Parameter Key: IDLE_TIMEOUT

The parameter key for the idle timeout (idle time in seconds), after which a connection is removed from the connection pool.
This parameter is used for configuring destinations only. Note that the timeout specified this way is by default applied to both repository connections (used for metadata lookup only) and application connections (used for all other remote function calls). Use RepositoryConnectionIdleTimeout to assign a different timeout to repository connections. The default is 10 minutes.

 

Max Pool Wait Time

Parameter Key: MAX_POOL_WAIT_TIME

The parameter key for the maximum time (in milliseconds) to wait for a connection to be released in the case where the connection limit has been reached. A value of "0" or a negative value signifies that there will be no waiting period (which is the default behavior). Trying to connect to a backend through a destination normally incurs an RfcResourceException, if at that time, the maximal number of connections (see PeakConnectionsLimit) is in use. This default behavior can be modified, in that the thread trying to connect is allowed to wait for a certain period of time (specified by this parameter). If a connection becomes available during that period, the request is successful after all. If the period expires before a connection becomes available, an RfcResourceException is thrown. The default is no waiting time (corresponding to 0 seconds or undefined).

 

Peak Connections Limit

Parameter Key: MAX_POOL_SIZE

The parameter key for the maximal number of concurrently open connections.
This parameter controls the maximal number of (client) connections that can be open simultaneously at any given time. If the maximal number of concurrently open connections is reached, any further client activity requiring a further connection will trigger a RfcResourceException. This default behavior can be altered by introducing a waiting period through MaxPoolWaitTime. Note that the maximal number of client connections is 10 by default, and can never be less than 1. That is, it is set to 1 if any attempt is made to set it to a value less than 1. For details on the interplay between peak limit and pool size, consult PoolSize.

 

Pool Size

Parameter Key: POOL_SIZE

This parameter determines the preferred or desired number of connections that are kept open for later requests even though they are currently not used. There will never be more open and unused connections at any time, but there could be fewer (even zero). That is, connections are not opened proactively, and if there are more idle connections than the pool size prescribes, they will be closed.

Note that the default pool size is 10. If the pool size is set to zero (or a value less than zero), pooling is effectively disabled. Furthermore, note that PeakConnectionsLimit should not be less than the pool size. If, however, that is the case, the pool will not grow beyond the peak limit or be gradually reduced to the peak limit. That means, the effective pool size is the minimum of the given pool size and the peak limit.

Idle connections will not remain in the pool forever, but will be removed depending on the settings of ConnectionIdleTimeout and IdleCheckTime.

 

Message Server Host

Parameter Key: MSHOST

When using MSHOST and a VPN with Overcast, the SAP profile parameter ms/lg_with_hostname must be set to 0 (zero), to disable the option. This configures SAP to return the IP address in the connection sequence instead of the system's host name. If this profile parameter cannot be set because it is required for other external connections, then the IP address and host name of all application servers (ASHOSTs) must be provided to Vigience for registration in the Overcast's DNS. Note 2576243


This configuration is not needed for connections through the public internet, SAProuter or Overcast Secure Agent.   

 

Tracing

Parameter Key: TRACE

 

The trace level can be specified as a string (similar to a bit vector) composed of elements of the following table by using their names separated by commas. If, for instance, trace level 2 is required plus sent and received bytes, use "LEVEL2,RfcData" (Spaces before or after the bitwise OR operator or comma are ignored; comma may be used liberally.) 

The names in the table below are case-insensitive.

 

Name Description
RemoteFunctionCall

Traces remote function calls.

PublicAPI

Traces most methods of the public API (except getters and setters or related methods).

InternalAPI

Traces most methods of the internal API (except getters and setters or related methods).

RfcData

Traces the bytes sent and received during each remote function call.

ParameterData

Traces the container data sent and received during each remote function call.

Metadata

Traces the metadata involved in a remote function call for each call.

Performance

Writes data to the trace files that can assist in analyzing performance issues.

Locking

Writes data to the trace files that shows when threads request, acquire, and release locks on objects.

SetValue

Writes information to the trace files regarding values set for parameters of functions, or fields of structures or tables.

CbRfc

Writes information to the trace file specific to column-based (de)serialization.

Network

Writes information to the trace file specific to network communication such as pings/pongs.

SessionProvider

Traces all methods of the currently used implementation of ISessionProvider.

None

The convenience element for suppressing all trace output.

Level1

The convenience element for tracing remote function calls.

Level2

The convenience element for tracing remote function calls and public API method calls.

Level3

The convenience element for tracing remote function calls as well as public and internal API method calls.

Level4

The convenience element for tracing remote function calls, public and internal API method calls, and the hex dumps for the RFC protocol, as well as network-related information.

 

Troubleshooting

The messages returned from SAP are corrupted.

e.g. OC-SAP-213 SAP returned an error. (j5U7m9n7) ---> “ú•t‚Í ____/__/__ ‚̏‘Ž®‚Å“ü—Í‚µ‚Ä‚­‚¾‚³‚¢ RETURN CODE: 18

 

Solution

When connecting to a non-Unicode backend using a non-ISO-Latin-1 username or password, it is necessary to set the "LANG" and "CODEPAGE" parameters in the connection string.

LANG= The human language to use for messages for the connection (i.e., DE, EN, JA).
CODEPAGE= The character encoding for messages for the connection (i.e., 1610, 1100, 8000).

For the full code page number list, see Supported Languages and Code Pages (Non-Unicode) (sap.com).

 

The host name of the application server returned from the message server (MSHOST) is not found in the DNS when using a VPN to Overcast.


Solution

See Message Server Host in Advanced Settings.