Monitoring SAP with the ABAP sensor

To monitor SAP with the ABAP sensor, you need to install the Instana host agent. After you install the host agent, the ABAP sensor is automatically installed. You can view metrics that are related to SAP in the Instana UI after you configure the ABAP sensor.

For more information, see install the Instana host agent.

Supported information

Supported OS

Instana supports the following operating systems that are supported by SAP Java Connector for local and remote monitoring:

  • For local monitoring (the Instana agent is installed on the same host as the ABAP server):

    • AIX
    • Linux (x86 and IBM PowerPC 64-bit LE)
    • Windows
  • For remote monitoring (the Instana agent is installed on a different host and connects remotely to the ABAP server):

    • AIX
    • Linux (x86 and IBM PowerPC 64-bit LE)
    • Windows
    • IBM i (OS/400 PASE)
    • Apple macOS (64 bit - Intel and Apple silicon)
    Note: For remote monitoring, the SAP can run on any platform, including IBM i, and be remotely monitored by installing the Instana agent on these platforms.

For more information about the operating systems supported by SAP Java Connector, see Supported OS.

Supported versions

The ABAP sensor supports the following SAP versions:

  • SAP R/3 3.1
  • S/4 HANA and later
  • SAP Java Connector 3.1.8 or later

Prerequisites

The ABAP sensor uses the SAP Java Connector (JCo) library to fetch metrics from the ABAP instances. With your SAP license, you can download the JCo library from Download SAP Java Connector 3.1 SDK without charge. For more information, see Add the SAP JCo library.

Note: SAP IDoc library is not required for the ABAP sensor. You only need to download the SAP Java Connector 3.1 SDK file for the platform where the Instana agent is deployed. For example, an Instana agent that runs on Linux x86 monitors the SAP ABAP application server runs on Windows x86. You must download the SAP Java Connector 3.1 SDK file for Linux x86.

The ABAP sensor supports only SAP JCo 3.1.8 or later.

Configuring the ABAP sensor

To collect metrics from ABAP instances, you need to configure the ABAP sensor as follows:

Note: The following information is applicable for both static and dynamic agents. For illustration purposes, a Linux-based deployment is used. You need to follow the same procedure for other operating systems like Windows, Mac, and other supported Unix systems.

Add the SAP JCo library

To add the SAP JCo library to a Linux-based system, complete the following steps:

  1. Locate the installed Instana agent in the /opt/instana/agent directory.

  2. In the Instana agent installation directory, create the system/com/sap/sapjco3/<Major>.<Minor>.<patch> directory

where in system/com/sap/sapjco3/3.1.13 the Major is 3, Minor is 1, and patch is 13.

Update these values based on the JAR version that you use.

The following steps consider SAP JCo 3.1.13 as an example; modify the version based on the JAR version file that you use:

  1. Verify that you set up a directory structure, such as /opt/instana/agent/system/com/sap/sapjco3/3.1.13.

  2. Download and extract the SAP JCo package, and follow the instructions that are mentioned in the Readme.txt file.

    The installation of JCo is platform-specific, and you must download the JCo version for the platform on which the Instana agent is run. The ABAP sensor gets deployed on the same computer as the Instana agent and communicates with the SAP system to fetch metrics.

  3. After you download and extract the .zip file, copy the sapjco3.jar file from the extracted folder to the /opt/instana/agent/system/com/sap/sapjco3/3.1.13/ directory.

    Note: Avoid extracting the .zip file directly in the /opt/instana/agent/system/com/sap/sapjco3/3.1.13/ directory since it contains many extra files that are not required for setting up the sensor. You need only two files, the sapjco3.jar and a single OS-specific library file in this directory.
  4. In the /opt/instana/agent/system/com/sap/sapjco3/3.1.13/ directory, rename the sapjco3.jar file to sapjco3-3.1.13.jar.

    Note: You must have only one .jar file in the specified directory. In this example, the .jar file is sapjco3-3.1.13.jar.
  5. Place the OS-specific library file in the /opt/instana/agent/system/com/sap/sapjco3/3.1.13/ directory. The file extension is .dll or .so.

    After you place the files in the directory, your directory must appear as follows. The following example shows a Linux-based installation directory after you place the file in it:

    ls /opt/instana/agent/system/com/sap/sapjco3/3.1.13/
    libsapjco3.so  sapjco3-3.1.13.jar
     

    You must not rename files with the extension .dll or .so.

  6. Update the libpath parameter in your configuration.yaml file to /opt/instana/agent/system/com/sap/sapjco3/3.1.13/. For more information, see Configuration parameters.

Connect ABAP sensor to ABAP instances

Instana can connect to your SAP ABAP instances either directly or through SAP Message Server.

If your SAP ABAP Instance or message server does not allow direct connections from external clients and instead requires a connection through SAProuter, see Connecting through SAProuter.

You must configure ABAP sensor to connect to one or more ABAP instances either directly or through SAP Message Server. Do not mix both configurations.

Connecting to ABAP instances directly

Instana supports both local and remote monitoring for the SAP ABAP sensor.

Note: Add all the local monitoring configurations under the local tag.

To connect ABAP sensor to ABAP instances directly, add the local or remote configurations as shown in the following examples. Enter the appropriate values for the parameters. The default polling interval for metric is set to 60 seconds.

Local configuration

The configuration parameters for local monitoring are shown in the following example:

# SAP ABAP
com.instana.plugin.sap.abap:
  # local monitoring configuration
  local : #multiple configurations supported
    - sysnr: '72'
      client: '100'
      user: 'User1'
      password: 'password'
      lang: 'en'
      pool_capacity: '10'
      libpath: <INSERT_SAP_JCO_LIBRARY_LOCATION>
      # path to JCo drivers. For static agent configuration details, follow documentation.
      poll_rate: 60 # seconds
 

Remote configuration

The configuration parameters for remote monitoring are shown in the following example:

# SAP ABAP
com.instana.plugin.sap.abap:
  # remote monitoring configuration
  remote : #multiple configurations supported
    - host: 'remote.host-1.com'
      sysnr: '72'
      client: '100'
      user: 'User1'
      password: 'password'
      lang: 'en'
      pool_capacity: '10'
      libpath: <INSERT_SAP_JCO_LIBRARY_LOCATION>
      # path to JCo drivers. For static agent configuration details, follow documentation.
      poll_rate: 60 # seconds
    - host: 'remote.host-2.com'
      sysnr: '01'
      client: '900'
      user: 'User2'
      password: 'password'
      lang: 'en'
      pool_capacity: '10'
      libpath: <INSERT_SAP_JCO_LIBRARY_LOCATION>
      # path to JCo drivers. For static agent configuration details, follow documentation.
      poll_rate: 60 # seconds
 

Make sure that the space formatting before each line is preserved as shown in the previous examples because it follows the YAML formatting syntax.

Configuration parameters

The following table lists the configuration parameters for SAP ABAP sensor when connecting to ABAP instances directly:

Parameters Description
host The IP address or qualified hostname of the SAP instance from which the ABAP sensor fetches the metrics.
sysnr The instance ID of the SAP ABAP instance, for example, 01.
client The client ID of the SAP ABAP instance, for example, 200.
user The username configured in the SAP instance. The SAP user must have the authorization to obtain metrics. For more information, see Verify user authorization to pull metrics.
password The password that is required to log in to the SAP system for the user.
libpath The folder where JCo is set up on your computer and has the OS-specific library files. For example, '/opt/instana/agent/system/com/sap/sapjco3/3.1.13/'. For Linux-based systems, the directory must have a libsapjco3.so file. For Windows-based systems, the directory must have a sapjco3.dll file.
lang The SAP logon language. The default value is "en".
pool_capacity The maximum number of connections that ABAP sensors can make to the SAP instance.

Connecting to ABAP instances through SAP Message Server

You can configure ABAP sensor to connect to your ABAP instances through Message Server.

To connect to ABAP instances through SAP Message Server, use the configuration as shown in the following example:

# SAP ABAP
com.instana.plugin.sap.abap:
  remote : # Connecting via Message Server
    - host: 'remote.messageserver-host.com'
      port: '3600' # Default port for Message Server
      type: 'message_server'
      client: '100'
      user: 'User1'
      password: 'password'
      group : 'PUBLIC' # Optional, Default is PUBLIC
      lang: 'en'
      pool_capacity: '10'
      libpath: <INSERT_SAP_JCO_LIBRARY_LOCATION>
      # path to JCo drivers. For static agent configuration details, follow documentation.
      poll_rate: 60 # seconds
 

Configuration parameters

The following table lists the configuration parameters for SAP ABAP sensor when connecting to ABAP instances through SAP Message Server:

Parameters Description
host The IP address or qualified hostname of the Message Server.
port The Message Server port, typically it is the sum of 3600 and the two digit Instance ID. For example, if the Instance ID is 01, the Message Server port is 3601. The default port is 3600.
type Set to message_server.
client The client ID of the SAP system, for example, 200.
user The username that is configured in the SAP instance. The SAP user must have the authorization to obtain metrics. For more information, see Verify user authorization to pull metrics.
password The password that is required to log in to the SAP system for the user.
group (optional) The logon group. The default is PUBLIC.
libpath The folder where JCo is set up on your computer and has the OS-specific library files. For example, '/opt/instana/agent/system/com/sap/sapjco3/3.1.13/'. For Linux-based systems, the directory must have a libsapjco3.so file. For Windows-based systems, the directory must have a sapjco3.dll file.
lang The SAP logon language. The default value is "en".
pool_capacity The maximum number of connections that ABAP sensors can make to the SAP instance.

Connecting via SAProuter

If your SAP ABAP Instance or message server does not allow direct connections from external clients and instead requires a connection through SAProuter, you need to add the following additional parameter in the configuration.yaml file:

sap_router: '/H/saprouter-host'
 

If the SAProuter is running on a different port than the default port 3299, you can specify the port number as follows:

sap_router: '/H/saprouter-host/P/saprouter-port'
 

Verify user authorization to pull metrics

Make sure that the user specified in the ABAP sensor configuration in the YAML file is authorized to pull metrics from SAP JCo.

To pull metrics from SAP JCo, you need to provide the following Authorization Object parameters in the SAP user account:

Authorization Object: S_RFC
    RFC_TYPE: Function Module
    RFC_NAME: *
    Activity: Execute

Authorization Object: /SDF/E2E
    Activity: 03

Authorization Object: S_ADMI_FCD
    S_ADMI_FCD: ST0R

Authorization Object: S_RZL_ADM
    Activity: 03

Authorization Object: S_TABU_DIS
    DICBERCLS: &NC&,EDI0,SA,SC,SS,SPWD
    Activity: 03
 
Note: User authorization takes place on the SAP ABAP system. The user authorization must be provided for the same user, instance ID, and client ID that are specified in the configuration.yaml for this ABAP sensor.

Viewing metrics

After you install the host agent and configure the ABAP sensor, you can view SAP metrics and alerts in the Instana UI.

Infrastructure view

To view the metrics, complete the following steps:

  1. In the sidebar of the Instana UI, select Infrastructure.
  2. On the Map tab, click a tower specific to SAP.
  3. Click Open Dashboard.

You can see the SAP dashboard with all the collected metrics.

Platform view

To view the metrics on Platform, complete the following steps:

  1. From the navigation menu in the Instana UI, select Platform > SAP. You can view lists of the Systems, Instances, and Databases.
  2. To view the SAP instance that is connected to the ABAP sensor, click the Instances tab. The sensor name is listed as AbapInstance@HostName_SID_InstanceID.

SAP dashboards

Metrics

The ABAP sensor collects the following metrics:

  • CPU
  • Memory
  • Work Process
  • Background Jobs
  • Database Connections
  • Database Latency
  • User Logins
  • Workload Response Time
  • Uptime
  • Top Process
  • Request Queue
  • Disk Data
  • File System
  • Errors and Dumps
  • User Statistics
  • Spool
  • Database Hit List
  • Web clients
  • Web destinations
  • Transport Request
  • RFC calls
  • Transactional RFC
  • Queued RFC
  • Network
  • ICM
  • Fiori
  • Gateway Connections
  • Gateway Error Logs
  • Lock Entry
  • Gateway Statistics
  • IDocs
  • System Log Errors
  • Update Errors
  • System Log Statistics
  • ABAP Dump Statistics
  • Lock Entries
  • Spool Errors
  • System configuration changes
  • Client configuration changes

Frequency of metric collection

The following table outlines the frequency of metric collection by the ABAP sensor:

Metric collected Collection frequency
Background Jobs 30 seconds
Work Process List 60 seconds
Work Process Status 60 seconds
Job Status 60 seconds
HTTP Metrics 60 seconds
SPOOL 60 seconds
User List 60 seconds
DB Connection 60 seconds
Database Hit List 60 seconds
Fiori Metrics 60 seconds
RFC Calls 60 seconds
Memory Usage 60 seconds
Dialog Response Time 60 seconds
Server Status 90 seconds
ABAP Dumps 2 minutes
Lock Entry List 2 minutes
Update Error 2 minutes
Transport Request 2 minutes
Buffer Statistics 3 minutes
Short Dumps History 3 minutes
User Info 3 minutes
Top Process List 3 minutes
System Log 3 minutes
Paging In and Out 3 minutes
CPU Metrics 3 minutes
Lan Interface 4 minutes
Gateway Metrics 4 minutes
Gateway Errors 4 minutes
Request Queue 5 minutes
ICM 5 minutes
Inbound IDoc 5 minutes
Outbound IDoc 5 minutes
RFC Error Logs 5 minutes
Web clients 5 minutes
Web destinations 5 minutes
File System 7 minutes
Disk Data 10 minutes

SAP ABAP sensor generates build-in events for various scenarios. For more information, see Built-in Events Reference.