This guide describes how to install and configure version 3.9 (latest)of Google Cloud's Agent for SAP on a Compute Engine instance, including one based on the X4 or C3 series.
To install and configure the agent on a Bare Metal Solution server, see Install Google Cloud's Agent for SAP on a Bare Metal Solution server .
Google Cloud's Agent for SAP is required for SAP support of SAP systems running on Google Cloud, including SAP NetWeaver, SAP HANA, SAP ASE, SAP MaxDB, and others.
When you install Google Cloud's Agent for SAP on a Compute Engine instance, for SAP Host Agent metrics, the agent combines monitoring data from Cloud Monitoring and the Compute Engine APIs and provides that data to the SAP Host Agent.
If you use the following RHEL or SLES "for SAP" OS images that Google Cloud provides, then Google Cloud's Agent for SAP is packaged with the OS images:
- RHEL: all "for SAP" images
- SLES: SLES 15 SP4 for SAP and later versions
For information about the operating systems supported by Google Cloud's Agent for SAP, see Supported operating systems .
Installation overview
On Linux, you install Google Cloud's Agent for SAP by using standard operating
system package management commands: on RHEL, the yum
command; on SLES, the zypper
command. The package management command completes the following tasks:
- Downloads the latest version of Google Cloud's Agent for SAP.
- Creates the agent as a Linux
systemd
service, namedgoogle-cloud-sap-agent
. - Enables and starts the service,
google-cloud-sap-agent
.
On Windows, you install Google Cloud's Agent for SAP by using the GooGet package
management command, googet
. The package management command completes the
following tasks:
- Downloads the latest version of Google Cloud's Agent for SAP.
-
Creates a Windows service named
google-cloud-sap-agent
and a scheduled task that runs every minute to check if the service is still running and, if necessary, restart it.
Prerequisites for the agent
Before you install Google Cloud's Agent for SAP, you need to ensure that the following prerequisites are met.
Set the required IAM roles
At a minimum, the service account
that Google Cloud's Agent for SAP uses must include the Compute Viewer ( roles/compute.viewer
)
, Monitoring Viewer ( roles/monitoring.viewer
)
,
and Workload Manager Insights Writer ( roles/workloadmanager.insightWriter
)
roles.
To add a required role to your service account, follow these steps:
-
In the Google Cloud console, go to the IAMpage.
-
Select your Google Cloud project.
-
Identify the service account to which you want to add a role.
- If the service account isn't already on the principals list, then it doesn't have any roles assigned to it. Click Addand enter the email address of the service account.
- If the service account is already on the principals list, then it has existing roles. Click the Editbutton for the service account that you want to edit.
-
Select the required role from the list of available roles:
- Compute Engine > Compute Viewer
- Monitoring > Monitoring Viewer
- Workload Manager > Workload Manager Insights Writer
-
Click Addor Saveto apply the roles to the service account.
Enable access to Google Cloud APIs
Compute Engine recommends configuring your compute instances to allow all access scopes to all Cloud APIs and using only the IAM permissions of the instance service account to control access to Google Cloud resources. For more information, see Create a VM that uses a user-managed service account .
If you do limit access to the Cloud APIs, then Google Cloud's Agent for SAP requires the following minimum Cloud API access scopes on the host Compute Engine instance:
- Cloud Platform: Enabled
- Compute Engine: Read Only
- Stackdriver Monitoring API: Read Only
If you are running SAP applications on a compute instance that does not have an external IP address, then you need to enable Private Google Access on the subnet of the compute instance so that Google Cloud's Agent for SAP can access Google APIs and services. To enable Private Google Access on a subnet, see Configuring Private Google Access .
Install the agent
To install Google Cloud's Agent for SAP on your Compute Engine instance, select your operating system, and then complete the following steps.
Linux
To install the agent on a Compute Engine instance, follow these steps:
- Establish an SSH connection to your compute instance.
- In your terminal, install the agent by running the command that is specific
to your operating system:
- (Recommended) To install version 3.9 (latest) of the
agent:
RHEL
sudo tee /etc/yum.repos.d/google-cloud-sap-agent.repo << EOM [google-cloud-sap-agent] name=Google Cloud Agent for SAP baseurl=https://packages.cloud.google.com/yum/repos/google-cloud-sap-agent-el$(cat /etc/redhat-release | cut -d . -f 1 | tr -d -c 0-9)-x86_64 enabled=1 gpgcheck=1 repo_gpgcheck=0 gpgkey=https://packages.cloud.google.com/yum/doc/yum-key.gpg https://packages.cloud.google.com/yum/doc/rpm-package-key.gpg EOM sudo yum install google-cloud-sap-agent
SLES15
sudo zypper addrepo --refresh https://packages.cloud.google.com/yum/repos/google-cloud-sap-agent-sles15-x86_64 google-cloud-sap-agent sudo zypper install google-cloud-sap-agent
SLES 12
sudo zypper addrepo --refresh https://packages.cloud.google.com/yum/repos/google-cloud-sap-agent-sles12-x86_64 google-cloud-sap-agent sudo zypper install google-cloud-sap-agent
- To install a specific version of the agent:
RHEL
sudo tee /etc/yum.repos.d/google-cloud-sap-agent.repo << EOM [google-cloud-sap-agent] name=Google Cloud Agent for SAP baseurl=https://packages.cloud.google.com/yum/repos/google-cloud-sap-agent-el$(cat /etc/redhat-release | cut -d . -f 1 | tr -d -c 0-9)-x86_64 enabled=1 gpgcheck=1 repo_gpgcheck=0 gpgkey=https://packages.cloud.google.com/yum/doc/yum-key.gpg https://packages.cloud.google.com/yum/doc/rpm-package-key.gpg EOM sudo yum install google-cloud-sap-agent- VERSION_NUMBER .x86_64
SLES15
sudo zypper addrepo --refresh https://packages.cloud.google.com/yum/repos/google-cloud-sap-agent-sles15-x86_64 google-cloud-sap-agent sudo zypper install google-cloud-sap-agent- VERSION_NUMBER .x86_64
SLES 12
sudo zypper addrepo --refresh https://packages.cloud.google.com/yum/repos/google-cloud-sap-agent-sles12-x86_64 google-cloud-sap-agent sudo zypper install google-cloud-sap-agent- VERSION_NUMBER .x86_64
Replace
VERSION_NUMBER
with the agent's version number that you want to install, such as3.1-606637668
. For information about the agent versions that you can install, see List all available versions of the agent .For information about downgrading the agent to a specific version, see Downgrade Google Cloud's Agent for SAP .
- (Recommended) To install version 3.9 (latest) of the
agent:
Windows
To install the agent on a Compute Engine instance, follow these steps:
- Use RDP to connect to the compute instance.
- As an administrator, run the following command from PowerShell:
googet addrepo google-cloud-sap-agent https://packages.cloud.google.com/yuck/repos/google-cloud-sap-agent-windows googet install google-cloud-sap-agent
After you install Google Cloud's Agent for SAP and the SAP Host Agent, validate the installation of Google Cloud's Agent for SAP, as described in Validate your installation of the agent .
Validate your installation of the agent
To verify that the agent is running, select your operating system, and then follow the steps:
Linux
-
Establish an SSH connection with your Compute Engine instance.
-
Run the following command:
systemctl status google-cloud-sap-agent
If the agent is functioning properly, then the output contains
active (running)
. For example:google-cloud-sap-agent.service - Google Cloud Agent for SAP Loaded: loaded (/usr/lib/systemd/system/google-cloud-sap-agent.service; enabled; vendor preset: disabled) Active: active (running)since Fri 2022-12-02 07:21:42 UTC; 4 days ago Main PID: 1337673 (google-cloud-sa) Tasks: 9 (limit: 100427) Memory: 22.4 M (max: 1.0G limit: 1.0G) CGroup: /system.slice/google-cloud-sap-agent.service └─1337673 /usr/bin/google-cloud-sap-agent
-
On SLES images, to ensure you're using the latest version of Google Cloud's Agent for SAP, run the following commands.
sudo zypper remove google-cloud-sap-agent sudo zypper addrepo -p 98 --refresh https://packages.cloud.google.com/yum/repos/google-cloud-sap-agent-sles15-\$basearch google-cloud-sap-agent sudo zypper install google-cloud-sap-agent
Windows
-
Use RDP to connect to the Compute Engine instance.
-
As an administrator, run the following command from PowerShell:
$(Get-Service -Name 'google-cloud-sap-agent' -ErrorAction Ignore).Status
Running
.
If the agent isn't running, then restart the agent .
Verify that SAP Host Agent is receiving metrics
To verify that the infrastructure metrics are collected by Google Cloud's Agent for SAP and sent correctly to the SAP Host Agent, follow these steps:
- In your SAP system, enter transaction
ST06
. -
In the overview pane, check the availability and content of the following fields for the correct end-to-end setup of the SAP and Google monitoring infrastructure:
- Cloud Provider:
Google Cloud Platform
- Enhanced Monitoring Access:
TRUE
- Enhanced Monitoring Details:
ACTIVE
- Cloud Provider:
Configure Google Cloud's Agent for SAP on Linux
After you install Google Cloud's Agent for SAP, optionally, you can enable other features of the agent by performing the following configurations. By default, the collection of SAP Host Agent metrics and Workload Manager evaluation metrics is enabled.
The following features are supported only on Linux. They are not supported on Windows.
- Configure Process Monitoring metrics collection
- Configure Workload Manager evaluation metrics collection
- Configure SAP HANA monitoring metrics collection .
- Configure Backint based backup and recovery for SAP HANA .
- Back up and recover SAP HANA by using a disk snapshot .
Default configuration file
The following snippet is an example of the default configuration of version 3.9 (latest) of Google Cloud's Agent for SAP:
{ "provide_sap_host_agent_metrics" : true , "bare_metal" : false , "log_level" : "INFO" , "log_to_cloud" : true , "collection_configuration" : { "collect_workload_validation_metrics" : true , "collect_process_metrics" : false }, "discovery_configuration" : { "enable_discovery" : true , "enable_workload_discovery" : true }, "hana_monitoring_configuration" : { "enabled" : false } }
To view feature-specific example configuration files, see the configuration guide for that feature.
Configuration parameters
The following table describes the configuration parameters of Google Cloud's Agent for SAP that is running on a Compute Engine instance, including the parameters related to the collection of metrics. For information about the configuration parameters related to the Backint feature of the agent, see Configuration parameters .
provide_sap_host_agent_metrics
Boolean
To enable the collection of the metrics required by the
SAP Host Agent, specify true
.
Default is true
.
Don't set provide_sap_host_agent_metrics
to false
unless you are directed by Cloud Customer Care or SAP Support.
bare_metal
Boolean
When the agent is installed on a Bare Metal Solution server, specify true
. Default is false
.
log_level
String
To set the logging level of the agent, set the required value. The available log levels are as follows:
-
DEBUG
-
INFO
-
WARNING
-
ERROR
Default is INFO
. Don't change the logging level unless you
are directed by Cloud Customer Care.
log_to_cloud
Boolean
To redirect the agent's logs to Cloud Logging
, specify true
. The default is true
.
cloud_properties.project_id
String
If your SAP system is running on a Bare Metal Solution server, then
specify the project ID of the Google Cloud project that you are
using with Bare Metal Solution.
When the agent runs on a Compute Engine instance, by default,
the agent detects the project ID automatically.
cloud_properties.instance_name
String
Specify the name of your Compute Engine instance. The agent automatically detects this upon installation.
cloud_properties.region
String
If your SAP system is running on a Bare Metal Solution server,
then specify the region
of the Bare Metal Solution server.
When the agent runs on a compute instance, by default,
the agent uses the region where the compute instance is deployed.
cloud_properties.zone
String
When the agent runs on a compute instance, by default, the agent uses the zone where the compute instance is deployed.
cloud_properties.image
String
Specify the OS image name of the instance.
When the agent runs on a compute instance, by default, the agent
automatically detects the OS image used by the compute instance.
cloud_properties.numeric_project_id
String
Specify the numeric ID of the Google Cloud project where the SAP system
is running.
When the agent runs on a compute instance, by default, the agent
automatically detects project number.
discovery_configuration.enable_workload_discovery
Boolean
To let the agent collect the names and versions of the SAP products
running on the host, specify true
. The default value is true
.
For more information, see the agent's codebase in the google-cloud-sap-agent
GitHub repository under GoogleCloudPlatform/sapagent
.
discovery_configuration.enable_discovery
Boolean
To send to Cloud Logging the information that the agent collects about
the SAP products running on the host, specify true
. The
default value is true
.
If you specify the value false
, then the agent stores the
collected information on the host and doesn't send it to Cloud Logging.
collection_configuration.collect_process_metrics
Boolean
To enable Process Monitoring metrics collection, specify true
.
Default is false
.
This parameter is applicable only for Linux.
If you enable Process metrics collection for SAP HANA, then you need to
set up additional parameters listed under hana_metrics_config
.
collection_configuration.process_metrics_frequency
Int
From version 2.6, this parameter determines the collection frequency of the fast-changing Process Monitoring metrics
,
in seconds. Fast-changing Process Monitoring metrics are: sap/hana/availability
, sap/hana/ha/availability
, and sap/nw/availability
.
The default value for this parameter is 5
seconds. We recommend that you use this default value.
All other ( slow-changing
) Process Monitoring metrics are collected at a
default frequency of 120 seconds. To change the collection frequency of
the slow-changing Process Monitoring metrics, use the parameter slow_process_metrics_frequency
.
collection_configuration.slow_process_metrics_frequency
Int
Specify the collection frequency of the slow-changing Process Monitoring metrics , in seconds.
The default value for this parameter is 120
seconds.
collection_configuration.process_metrics_to_skip
Array
Specify the Process Monitoring metrics
that you don't want the agent to collect. This parameter accepts a
comma-separated value of Process Monitoring metric names. For example: "process_metrics_to_skip": ["/sap/nw/abap/sessions", "/sap/nw/abap/rfc"]
.
collection_configuration.hana_metrics_config.hana_db_user
String
Specify the database user account that the agent uses to query
SAP HANA. Default is SYSTEM
.
collection_configuration.hana_metrics_config.hana_db_password
String
Specify the plain text password for the database user account that the agent uses to query SAP HANA.
Instead of specifying a plain text password, we recommend that you use one of the following options:
-
hana_db_password_secret_name
, for which you specify a secret stored in Secret Manager . -
hdbuserstore_key
, for which you specify anhdbuserstore
key .
For SAP HANA authentication, the agent uses the following order of
preference: if specified, the hdbuserstore_key
configuration
parameter is preferred over the hana_db_password
parameter, which
is preferred over the hana_db_password_secret_name
parameter. We
recommend that you set only one authentication option in your configuration
file.
collection_configuration.hana_metrics_config.hana_db_password_secret_name
String
To securely provide the password for the database user account that the agent uses to query SAP HANA, specify the name of the secret that contains the security credentials for the database user account.
The agent collects the SAP HANA related metrics only when you specify
either hana_db_password_secret_name
, hdbuserstore_key
,
or hana_db_password
.
For SAP HANA authentication, the agent uses the following order of
preference: if specified, the hdbuserstore_key
configuration
parameter is preferred over the hana_db_password
parameter, which
is preferred over the hana_db_password_secret_name
parameter. We
recommend that you set only one authentication option in your configuration
file.
collection_configuration.hana_metrics_config.hdbuserstore_key
String
To securely connect to an SAP HANA system, specify a Secure user store ( hdbuserstore
)
key that you've created for that
system.
To use an hdbuserstore
key for authentication, ensure the following:
- The SAP tools
hdbsql
andhdbuserstore
are installed on the compute instance hosting the agent. - The
hdbuserstore
key corresponds to one specific SAP HANA instance. You can't use keys that contain hostnames of multiple SAP HANA instances. - The
SID adm
user can query the SAP HANA database using this key. HereSID
refers to the value that you've specified for thesid
parameter. You can verify this by running the following command as theSID adm
user:hdbsql -U HDB_USERSTORE_KEY "SELECT * FROM DUMMY"
This configuration parameter is supported from version 3.3 of the agent.
For SAP HANA authentication, the agent uses the following order of
preference: if specified, the hdbuserstore_key
configuration
parameter is preferred over the hana_db_password
parameter, which
is preferred over the hana_db_password_secret_name
parameter. We
recommend that you set only one authentication option in your configuration
file.
collection_configuration.hana_metrics_config.sid
String
Specify the SID of your SAP HANA instance.
If you're using an hdbuserstore
key to authenticate to SAP
HANA, then refer to the hdbuserstore_key
section.
collection_configuration.collect_workload_validation_metrics
Boolean
To enable Workload Manager evaluation metrics collection,
specify true
. From version 3.2, the default value is true
.
This parameter is applicable only for Linux.
collection_configuration.workload_validation_metrics_frequency
Int
The collection frequency of the Workload Manager
evaluation metrics in seconds. The default value is 300
seconds.
If you need to modify the collection frequency of the
Workload Manager metrics, then add the workload_validation_metrics_frequency
parameter under the collection_configuration
section and
provide the required value.
collection_configuration.workload_validation_collection_definition.fetch_latest_config
Boolean
Optional. The default value is true
, which enables the agent
to collect the latest set of Workload Manager evaluation
metrics without requiring you to update the agent. If you want to turn off
this behavior, then specify this parameter in your configuration file and
set its value to false
.
collection_configuration.workload_validation_db_metrics_config.hana_db_user
String
Specify the user account that is used to query the SAP HANA instance. The user account must have the read permission to the SAP HANA database.
collection_configuration.workload_validation_db_metrics_config.hana_db_password
String
Specify the password for the user account that is used to query the SAP HANA instance.
For SAP HANA authentication, the agent uses the following order of
preference: if specified, the hdbuserstore_key
configuration
parameter is preferred over the hana_db_password
parameter, which
is preferred over the hana_db_password_secret_name
parameter. We
recommend that you set only one authentication option in your configuration
file.
collection_configuration.workload_validation_db_metrics_config.hana_db_password_secret_name
String
Specify the name of the secret in Secret Manager that stores the user account's password.
Alternatively, you can specify the hdbuserstore_key
configuration parameter to authenticate the specified SAP HANA user.
For SAP HANA authentication, the agent uses the following order of
preference: if specified, the hdbuserstore_key
configuration
parameter is preferred over the hana_db_password
parameter, which
is preferred over the hana_db_password_secret_name
parameter. We
recommend that you set only one authentication option in your configuration
file.
collection_configuration.workload_validation_db_metrics_config.hdbuserstore_key
String
To securely connect to an SAP HANA system, specify a Secure user store ( hdbuserstore
)
key that you've created for that
system.
To use an hdbuserstore
key for authentication, ensure the following:
- The SAP tools
hdbsql
andhdbuserstore
are installed on the compute instance hosting the agent. - The
hdbuserstore
key corresponds to one specific SAP HANA instance. You can't use keys that contain hostnames of multiple SAP HANA instances. - The
SID adm
user can query the SAP HANA database using this key. HereSID
refers to the value that you've specified for thesid
parameter. You can verify this by running the following command as theSID adm
user:hdbsql -U HDB_USERSTORE_KEY "SELECT * FROM DUMMY"
This configuration parameter is supported from version 3.3 of the agent.
If you specify hdbuserstore_key
, then you can skip specifying
the hostname
and port
parameters.
For SAP HANA authentication, the agent uses the following order of
preference: if specified, the hdbuserstore_key
configuration
parameter is preferred over the hana_db_password
parameter, which
is preferred over the hana_db_password_secret_name
parameter. We
recommend that you set only one authentication option in your configuration
file.
collection_configuration.workload_validation_db_metrics_config.sid
String
Specify the SID of your SAP HANA instance.
collection_configuration.workload_validation_db_metrics_config.hostname
String
Specify the identifier for the machine, either local or remote, that hosts your SAP HANA instance. The following are the supported values:
- If the host is a local machine, then specify the string
localhost
or the localhost loopback IP address, like127.0.0.1
. - If the host is a remote machine, then specify its internal or external IP address.
collection_configuration.workload_validation_db_metrics_config.port
String
Specify the port on which your SAP HANA instance accepts queries. For
the first or only tenant database instance, the port is 3 NN
15
, where NN
is the
instance number of the SAP HANA instance.
collection_configuration.workload_validation_db_metrics_frequency
Int
The collection frequency of the SAP HANA database metrics, in seconds,
for Workload Manager evaluation.
Default is 3600
seconds.
Although you can update the collection frequency of the
SAP HANA database metrics, we recommend that you use
the default value. If you need to modify the default value, then add the workload_validation_db_metrics_frequency
parameter under
the collection_configuration
section and provide the required
value. Make sure that you don't set a collection frequency greater
than 3600
seconds.
hana_monitoring_configuration.enabled
Boolean
Optional. To enable Google Cloud's Agent for SAP to collect the SAP HANA
monitoring metrics, specify true
. The default value is false
.
hana_monitoring_configuration.enabled: true
.hana_monitoring_configuration.sample_interval_sec
Int
Optional. Specify the sample interval, in seconds, which determines the frequency at which Google Cloud's Agent for SAP queries your SAP HANA instances to collect the SAP HANA monitoring metrics. The default value is 300 seconds.
For each query defined in the configuration file of
Google Cloud's Agent for SAP, you can overwrite the global sample interval
by specifying the required interval to the parameter sample_interval_sec
. Sample intervals must be 5 seconds or
longer.
hana_monitoring_configuration.query_timeout_sec
Int
Optional. Specify the timeout for each query made to the SAP HANA instances. The default value is 300 seconds.
hana_monitoring_configuration.execution_threads
Int
Optional. Specify the number of threads used to send queries to the SAP HANA instances. Each query runs on its own thread. The default value is 10.
hana_monitoring_configuration.send_query_response_time
Boolean
Optional. Specify true
to have the agent capture the
response time for every SAP HANA monitoring query defined in the agent's
configuration file.
hana_monitoring_configuration.hana_instances.name
String
Specify the name identifier for your SAP HANA instance.
hana_monitoring_configuration.hana_instances.sid
String
Specify the SID of your SAP HANA instance. This string is added as a label to all the metrics resulting from querying your SAP HANA instances.
hana_monitoring_configuration.hana_instances.host
String
Specify the identifier for the machine, either local or remote, that hosts your SAP HANA instance. The following are the supported values:
- If the host is a local machine, then specify the string
localhost
or the localhost loopback IP address, like127.0.0.1
. - If the host is a remote machine, then specify its internal or external IP address.
hana_monitoring_configuration.hana_instances.port
String
Specify the port on which your SAP HANA instance accepts queries. For
the first or only tenant database instance, the port is 3 NN
15
, where NN
is the
instance number of the SAP HANA instance.
hana_monitoring_configuration.hana_instances.user
String
Specify the user account that is used to query the SAP HANA instance.
Make sure that this user has the privilege to read the monitoring views in your SAP HANA database. If this privilege is not granted, then the SAP HANA monitoring metrics related to the monitoring views contain no data.
hana_monitoring_configuration.hana_instances.password
String
Optional. Specify the password, as plain text, that authenticates the user account for querying the SAP HANA instance.
For authentication, you must specify one of the following:
- The plain text password to the parameter
password
. - (Recommended) If you use Secret Manager
to store the password as a secret, then you must specify the
corresponding secret name to the parameter
secret_name
. - (Recommended) An
hdbuserstore
key to the parameterhdbuserstore_key
.
For SAP HANA authentication, the agent uses the following order of
preference: if specified, the hdbuserstore_key
configuration
parameter is preferred over the password
parameter, which
is preferred over the secret_name
parameter. We
recommend that you set only one authentication option in your configuration
file.
hana_monitoring_configuration.hana_instances.secret_name
String
Optional. Specify the name of the secret in Secret Manager that stores the user account's password.
For SAP HANA authentication, the agent uses the following order of
preference: if specified, the hdbuserstore_key
configuration
parameter is preferred over the password
parameter, which
is preferred over the secret_name
parameter. We
recommend that you set only one authentication option in your configuration
file.
hana_monitoring_configuration.hana_instances.hdbuserstore_key
String
To securely connect to an SAP HANA system, specify a Secure user store ( hdbuserstore
)
key that you've created for that
system.
To use an hdbuserstore
key for authentication, ensure the following:
- The SAP tools
hdbsql
andhdbuserstore
are installed on the compute instance hosting the agent. - The
hdbuserstore
key corresponds to one specific SAP HANA instance. You can't use keys that contain hostnames of multiple SAP HANA instances. - The
SID adm
user can query the SAP HANA database using this key. HereSID
refers to the value that you've specified for thesid
parameter. You can verify this by running the following command as theSID adm
user:hdbsql -U HDB_USERSTORE_KEY "SELECT * FROM DUMMY"
This configuration parameter is supported from version 3.3 of the agent.
If you specify hdbuserstore_key
, then you can skip
specifying the host
and port
parameters.
hana_monitoring_configuration.hana_instances.is_local
Boolean
For monitoring HA systems, specify true
to tell the agent
that the defined SAP HANA instance is hosted on the same
Compute Engine instance as the agent. This then
makes the agent check at runtime if the defined SAP HANA instance is the
primary or the secondary node in that HA system. This awareness is required
by the agent to run the SAP HANA monitoring queries on the SAP HANA instance
type that you specify for the queries.run_on
parameter.
The default value for this parameter is false
, which makes
the agent run all the enabled SAP HANA monitoring queries on the
corresponding SAP HANA instance. For more information, see Monitoring
for multi-tenant and HA systems
.
This parameter is supported from version 3.7 of the agent.
hana_monitoring_configuration.hana_instances.instance_num
String
Specify the instance number that you've set for your SAP HANA instance. This information is required for the agent to discover your SAP HANA instance.
This parameter is supported from version 3.7 of the agent.
hana_monitoring_configuration.hana_instances.queries_to_run.run_all
Boolean
Optional. Specify true
to run all the SAP HANA monitoring
queries, default and custom, that are enabled in the agent's configuration
file on the specified SAP HANA instance. The default value is false
.
hana_monitoring_configuration.hana_instances.queries_to_run.query_name
String
Optional. Specify the queries that you want to run on the specified SAP HANA instance.
If you're running a multi-tenant SAP HANA database, then you can set up
tenant specific monitoring by using this configuration parameter. In the
following example configuration, two queries are run on HANA_TENANT_1
and all queries defined in the
configuration are run on HANA_TENANT_2
:
"hana_instances": [ { "name": " HANA_TENANT_1 , "queries_to_run": { "query_name": [" QUERY_NAME_1 ", " QUERY_NAME_2 "] } }, { "name": " HANA_TENANT_2 , "queries_to_run": { "run_all": true } } ... ]
hana_monitoring_configuration.hana_instances.enable_ssl
Boolean
Optional. Specifies whether or not SSL is enabled in your SAP HANA
instance. The default value is false
.
hana_monitoring_configuration.hana_instances.host_name_in_certificate
String
If you specify enable_ssl: true
for an SAP HANA
instance, then you must specify the hostname that is set in the SSL
certificate.
hana_monitoring_configuration.hana_instances.tls_root_ca_file
String
If you specify enable_ssl: true
for an SAP HANA
instance, then you must specify the path for your security
certificate.
hana_monitoring_configuration.queries.enabled
Boolean
Optional. To enable a SQL query for all your SAP HANA instances,
specify the value true
for the parameter enabled
for that SQL query.
hana_monitoring_configuration.queries.name
String
If you have defined custom queries in your configuration file, then you must specify a unique name for each custom query.
The query name must be unique because it is used to build the metric's default URL in Monitoring.
hana_monitoring_configuration.queries.run_on
String
Optional. Specify this parameter if you're monitoring an SAP HANA HA
system and want to run the SAP HANA monitoring queries on either the
primary or the secondary node. Supported values: PRIMARY
, SECONDARY
, ALL
. When you specify the value ALL
, the agent runs the SAP HANA monitoring queries on both
the primary and secondary nodes in your HA cluster.
This parameter is supported from version 3.7 of the agent. Also, to run the queries on the secondary node, make sure that your HA system is deployed with the Active/Active (Read Enabled) configuration.
hana_monitoring_configuration.queries.sql
String
Specify the SQL statement that the agent issues to your SAP HANA instances.
The SQL statement must conform to the SQL syntax defined by SAP in SAP HANA SQL and System Views Reference .hana_monitoring_configuration.queries.sample_interval_sec
Int
Optional. Specify the sample interval for the SQL query. This overrides the global sample interval. The value must be 5 seconds or longer.
hana_monitoring_configuration.queries.columns.name
String
Specify a name that uniquely identifies each column.
The column name must be unique because it is used to build the metric's default URL in Monitoring.
hana_monitoring_configuration.queries.columns.metric_type
String
For handling by Monitoring, specify one of the following
metric types: METRIC_LABEL
, METRIC_GAUGE
, or METRIC_CUMULATIVE
.
Metrics of type METRIC_LABEL
are appended as labels to
all the METRIC_GAUGE
and METRIC_CUMULATIVE
metrics that are sent to Monitoring.
hana_monitoring_configuration.queries.columns.value_type
String
For handling by Monitoring, specify a data type that is supported by the metric type.
The supported data types are as follows: VALUE_BOOL
, VALUE_INT64
, VALUE_STRING
, or VALUE_DOUBLE
. For more information, see Supported combination
.
hana_monitoring_configuration.queries.columns.name_override
String
Optional. For handling by Monitoring, specify the path that you want to show in the metric URL instead of the query and column names. For example:
- Metric's default URL:
workload.googleapis.com/sap/hanamonitoring/ QUERY_NAME / COLUMN_NAME
- Metric URL using custom path:
workload.googleapis.com/sap/hanamonitoring/ CUSTOM_PATH
Troubleshooting
For information about diagnosing and resolving issues that you might encounter when you install and configure Google Cloud's Agent for SAP, see Google Cloud's Agent for SAP troubleshooting guide .
Get support
If you need help resolving problems with Google Cloud's Agent for SAP, then collect all available diagnostic information and contact Cloud Customer Care. For information about contacting Customer Care, see Getting support for SAP on Google Cloud .