Skip to content

Supported Keys and Macros

This section provides a comprehensive list of the item keys and discovery rules supported by the SAP Agent plugin.

Item Keys

sap.agent.ping

Tests if a connection to the SAP Host Agent is alive and responding to SOAP requests.

Parameters:

Name Description Default
common_params Connection string (URI or Session), username and password. http://localhost:1128, sapadm

Returns:

  • 1 — Connection is alive.
  • 0 — Connection is broken or service is unreachable.

sap.agent.version

Retrieves the version information of the SAP Host Agent.

Parameters:

Name Description
common_params Connection details.

Returns:

  • A string containing the version and patch level (e.g., 7.20 patch 112).

sap.agent.cpu.num

Returns the total number of logical CPUs available on the host system as reported by the SAP Host Agent.

Parameters:

Name Description
common_params Connection details.

Returns:

  • Integer value (e.g., 4).

sap.agent.cpu.util

Returns the CPU utilization percentage for a specific CPU or an average of all CPUs.

Parameters:

Name Description Accepted Values Default
common_params Connection details.
cpu The CPU number to monitor. all, 0, 1, ... all
type The type of utilization to report. user, system, idle, iowait, steal

Returns:

  • Float value representing the percentage (0-100).

Info

steal time is only available when the cpu parameter is set to all.


sap.agent.cpu.load

Returns the CPU load average for the specified time period.

Parameters:

Name Description Accepted Values Default
common_params Connection details.
mode The time window for the load average. avg1, avg5, avg15 avg1

Returns:

  • Float value.

sap.agent.cpu.intr

Returns the interrupt rate per second on the host.

Parameters:

Name Description
common_params Connection details.

Returns:

  • Float value (Interrupts per second).

sap.agent.cpu.switches

Returns the context switch rate per second on the host.

Parameters:

Name Description
common_params Connection details.

Returns:

  • Float value (Switches per second).

sap.agent.mem

Returns information about the host's physical or virtual memory usage.

Parameters:

Name Description Accepted Values
common_params Connection details.
type Memory category. phy (Physical), virt (Virtual)
mode Data to retrieve. available, free, size

Returns:

  • Integer value in bytes.
  • Note: Virtual memory category only supports the size mode.

sap.agent.swap.size

Returns the swap space information in bytes.

Parameters:

Name Description Accepted Values Default
common_params Connection details.
mode Swap usage category. free, used, total

Returns:

  • Integer value in bytes.

sap.agent.swap.in

Returns the swap-in rate information.

Parameters:

Name Description Accepted Values
common_params Connection details.
mode Rate unit. bytes, pages

Returns:

  • Float/Integer value representing the rate.

sap.agent.swap.out

Returns the swap-out rate information.

Parameters:

Name Description Accepted Values
common_params Connection details.
mode Rate unit. bytes, pages

Returns:

  • Float/Integer value representing the rate.

sap.agent.net.in

Retrieves incoming network traffic statistics for a specific interface.

Parameters:

Name Description Accepted Values
common_params Connection details.
iface Interface name (e.g., eth0).
mode Type of traffic metric. bytes, packets, errors

Returns:

  • Integer/Float value depending on the requested mode.

sap.agent.net.out

Retrieves outgoing network traffic statistics for a specific interface.

Parameters:

Name Description Accepted Values
common_params Connection details.
iface Interface name (e.g., eth0).
mode Type of traffic metric. bytes, packets, errors

Returns:

  • Integer/Float value depending on the requested mode.

sap.agent.fs.size

Returns size information for a specific mounted filesystem.

Parameters:

Name Description Accepted Values
common_params Connection details.
fs Filesystem mount point (e.g., /).
mode Size category. total, free

Returns:

  • Integer value in bytes.

sap.agent.dev

Returns information about a specific host block device.

Parameters:

Name Description Accepted Values
common_params Connection details.
dev Block device name (e.g., sda).
mode Metric to retrieve. util, queue, svc, write, io, tput

Returns:

  • Float value (Percentage for util, operations for io, bytes for tput).

sap.agent.os.name

Returns the host name as reported by the operating system.

Parameters:

Name Description
common_params Connection details.

Returns:

  • String value.

sap.agent.os.version

Returns the operating system version information.

Parameters:

Name Description
common_params Connection details.

Returns:

  • String value.

Discovery Rules

sap.agent.cpu.discovery

Discovers all logical CPUs on the host. Used for Low-level discovery of individual core metrics.

Returns:

  • JSON array containing {#CPU.ID} macros.

sap.agent.net.discovery

Discovers all available network interfaces on the host.

Returns:

  • JSON array containing {#IFNAME} macros.

sap.agent.fs.discovery

Discovers all mounted filesystems on the host.

Returns:

  • JSON array containing {#FSNAME} macros.

sap.agent.dev.discovery

Discovers all block devices (disks) available on the host.

Returns:

  • JSON array containing {#DEVNAME} macros.

sap.agent.db.discovery

Discovers all SAP databases running on the host.

Returns:

  • JSON array containing database discovery macros ({#DB.NAME}, {#DB.PROTOCOL}, {#DB.HOST} and {#DB.PORT}).

Macros

Macro Default Value Description
{$SAP.AGENT.URI} http://localhost:1128 SAP Host Agent SOAP URI.
{$SAP.AGENT.USER} sapadm Authentication username.
{$SAP.AGENT.PASSWORD} Authentication password.