OCF_HEARTBEAT_SAPDAT(7)
π OCF_HEARTBEAT_SAPDAT(7) β SAPDatabase, but make it cute β¨
This is the manual page for OCF_HEARTBEAT_SAPDAT(7), bestie, and the manual-family vibe is OCF resource agents. The main-character resource agent here is ocf_heartbeat_SAPDatabase.
π NAME π
ocf_heartbeat_SAPDatabaseβ manages a SAP database instance as an HA resource.
π¦ SYNOPSIS π¦
SAPDatabase [start | stop | status | monitor | meta-data | validate-all]
πΈ DESCRIPTION πΈ
Okay so this is a resource script for SAP databases, and it manages a SAP database of any type as an HA resource. Its whole job? Start, stop, and monitor the database instance of a SAP system. Together with the RDBMS system it will also control the related network service for the database β like the Oracle Listener and the xserver of MaxDB. The resource agent expects a standard SAP installation of the database and therefore needs less parameters to configure.
The resource agent supports these databases:
- Oracle
10.2,11.2and12 - DB/2 UDB for Windows and Unix
9.x - SAP-DB / MaxDB
7.x - Sybase ASE
15.7 - SAP HANA Database since
1.00β with SAP note1625203(http://sdn.sap.com)
Plot twist: this resource agent does not run any database commands directly. It uses the SAP standard process SAPHostAgent to control the database. The SAPHostAgent must be installed on each cluster node locally. It will not work if you try to run the SAPHostAgent also as a HA resource. Please follow SAP note 1031096 for the installation of SAPHostAgent. The required minimum version of SAPHostAgent is: Release: 7.20 Patch Number: 90 or compile time after: Dec 17 2011.
To exemplify the usage, for a HANA database with SID TST and instance number 10, the resource configuration using crmsh syntax looks like:
primitive rsc_SAPDatabase_TST_HDB10 ocf:heartbeat:SAPDatabase \ params
DBTYPE="HDB" SID="TST" \ op start interval="0" timeout="3600" \ op
monitor interval="120" timeout="700" \ op stop interval="0"
timeout="600"
Make sure to tune the operations timeout values accordingly with your chosen Database and available infrastructure.
Note that the same configuration can be achieved using any other CLI tool for cluster configuration available, like pcs or cibadmin.
β¨ SUPPORTED PARAMETERS β¨
Hereβs the full parameter menu, bestie β every single one, no skips:
SIDβ the unique database system identifier, e.g.P01. Metadata:(unique, required, string, no default).DIR_EXECUTABLEβ the full qualified path where to findsaphostexecandsaphostctrl. Usually you can leave this empty. Then the default:/usr/sap/hostctrl/exeis used. Metadata:(optional, string, default "/usr/sap/hostctrl/exe").DBTYPEβ the name of the database vendor you use. Set either:ADA,DB6,ORA,SYB,HDB. Metadata:(required, string, no default).DBINSTANCEβ must be used for special database implementations, when database instance name is not equal to the SID (e.g. Oracle DataGuard). Metadata:(unique, optional, string, no default).DBOSUSERβ the parameter can be set if the database processes on operating system level are not executed with the default user of the used database type. Defaults:ADA=taken from /etc/opt/sdb,DB6=db2SID,ORA=oraSID and oracle,SYB=sybSID,HDB=SIDadm. Metadata:(unique, optional, string, no default).NETSERVICENAMEβ deprecated β do not use anymore. This parameter will be deleted in one of the next releases. Metadata:(optional, string, no default).DBJ2EE_ONLYβ deprecated β do not use anymore. This parameter will be deleted in one of the next releases. Metadata:(optional, boolean, default false).JAVA_HOMEβ deprecated β do not use anymore. This parameter will be deleted in one of the next releases. Metadata:(optional, string, no default).STRICT_MONITORINGβ this controls how the resource agent monitors the database. If set totrue, it will usesaphostctrl -function GetDatabaseStatusto test the database state. If set tofalse, only operating system processes are monitored. Metadata:(optional, boolean, default false).AUTOMATIC_RECOVERβ if you set this totrue,saphostctrl -function StartDatabasewill always be called with the-forceoption. Metadata:(optional, boolean, default false).MONITOR_SERVICESβ defines which services are monitored by the SAPDatabase resource agent. Service names must correspond with the output of thesaphostctrl -function GetDatabaseStatuscommand. The defaultMONITOR_SERVICESvalue is derived from the database typeDBTYPE. For reference:DBTYPE "ORA"setsMONITOR_SERVICES="Instance|Database|Listener";DBTYPE "HDB"setsMONITOR_SERVICES="hdbindexserver|hdbnameserver";DBTYPE "ADA"setsMONITOR_SERVICES="Database";DBTYPE "DB6"setsMONITOR_SERVICES="{SID}|{db2sid}";DBTYPE "SYB"setsMONITOR_SERVICES="Server".
This parameter should be set ONLY if is needed to monitor different services than the ones listed above. Metadata: (optional, string, no default).
DIR_BOOTSTRAPβ deprecated β do not use anymore. This parameter will be deleted in one of the next releases. Metadata:(optional, string, no default).DIR_SECSTOREβ deprecated β do not use anymore. This parameter will be deleted in one of the next releases. Metadata:(optional, string, no default).DB_JARSβ deprecated β do not use anymore. This parameter will be deleted in one of the next releases. Metadata:(optional, string, no default).PRE_START_USEREXITβ the full qualified path where to find a script or program which should be executed before this resource gets started. Metadata:(optional, string, no default).POST_START_USEREXITβ the full qualified path where to find a script or program which should be executed after this resource got started. Metadata:(optional, string, no default).PRE_STOP_USEREXITβ the full qualified path where to find a script or program which should be executed before this resource gets stopped. Metadata:(optional, string, no default).POST_STOP_USEREXITβ the full qualified path where to find a script or program which should be executed after this resource got stopped. Metadata:(optional, string, no default).
π SUPPORTED ACTIONS π
This resource agent supports the following actions (operations):
startβ starts the resource. Suggested minimum timeout:1800s.stopβ stops the resource. Suggested minimum timeout:1800s.statusβ performs a status check. Suggested minimum timeout:60s.monitorβ performs a detailed status check. Suggested minimum timeout:60s. Suggested interval:120s.validate-allβ performs a validation of the resource configuration. Suggested minimum timeout:5s.meta-dataβ retrieves resource agent metadata (internal use only). Suggested minimum timeout:5s.methodsβ suggested minimum timeout:5s.
π§Έ EXAMPLE CRM SHELL π§Έ
The following is an example configuration for a SAPDatabase resource using the crm(8) shell:
primitive p_SAPDatabase ocf:heartbeat:SAPDatabase \
params \
SID=string \
DBTYPE=string \
op monitor depth="0" timeout="60s" interval="120s"
π EXAMPLE PCS π
The following is an example configuration for a SAPDatabase resource using pcs(8):
pcs resource create p_SAPDatabase ocf:heartbeat:SAPDatabase \
SID=string \
DBTYPE=string \
op monitor OCF_CHECK_LEVEL="0" timeout="60s" interval="120s"
π SEE ALSO π
π AUTHOR π
ClusterLabs contributors (see the resource agent source for information about individual authors)
And thatβs the page, bestie π«Ά β source/version: resource-agents UNKNOWN, dated 10/01/2026, and yup, itβs still OCF_HEARTBEAT_SAPDAT(7) π
π¦ where this page comes from
- opensuse-leap 16.0: resource-agents 4.18.0+git105.9ea1183-160000.1.1 Β· GPL-2.0-only AND LGPL-2.1-or-later AND GPL-3.0-or-later
- opensuse-leap 16.0: resource-agents 4.18.0+git105.9ea1183-160000.1.1 Β· GPL-2.0-only AND LGPL-2.1-or-later AND GPL-3.0-or-later
- opensuse-leap 16.0: resource-agents 4.18.0+git105.9ea1183-160000.1.1 Β· GPL-2.0-only AND LGPL-2.1-or-later AND GPL-3.0-or-later
- opensuse-leap 16.0: resource-agents 4.18.0+git105.9ea1183-160000.1.1 Β· GPL-2.0-only AND LGPL-2.1-or-later AND GPL-3.0-or-later
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms