SYNOPSIS

SAPDatabase [start | stop | status | monitor | meta-data | validate-all]

DESCRIPTION

Resource script for SAP databases. It manages a SAP database of any type as an HA resource.

The purpose of the resource agent is to 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 the following databases:

- Oracle 10.2 and 11.2

- 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 node 1625203 (http://sdn.sap.com)

In fact 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

SUPPORTED PARAMETERS

SID

The unique database system identifier. e.g. P01

(unique, required, string, no default)

DIR_EXECUTABLE

The full qualified path where to find saphostexec and saphostctrl. Usually you can leave this empty. Then the default: /usr/sap/hostctrl/exe is used.

(optional, string, default "/usr/sap/hostctrl/exe")

DBTYPE

The name of the database vendor you use. Set either: ADA, DB6, ORA, SYB, HDB

(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)

(unique, optional, string, no default)

NETSERVICENAME

Deprecated - do not use anymore. This parameter will be deleted in one of the next releases.

(optional, string, no default)

DBJ2EE_ONLY

Deprecated - do not use anymore. This parameter will be deleted in one of the next releases.

(optional, boolean, default false)

JAVA_HOME

Deprecated - do not use anymore. This parameter will be deleted in one of the next releases.

(optional, string, no default)

STRICT_MONITORING

This controls how the resource agent monitors the database. If set to true, it will use 'saphostctrl -function GetDatabaseStatus' to test the database state. If set to false, only operating system processes are monitored.

(optional, boolean, default false)

AUTOMATIC_RECOVER

If you set this to true, 'saphostctrl -function StartDatabase' will always be called with the '-force' option.

(optional, boolean, default false)

MONITOR_SERVICES

Defines which services are monitored by the SAPDatabase resource agent, if STRICT_MONITORING is set to true. Service names must correspond with the output of the 'saphostctrl -function GetDatabaseStatus' command.

(optional, string, default "Instance|Database|Listener")

DIR_BOOTSTRAP

Deprecated - do not use anymore. This parameter will be deleted in one of the next releases.

(optional, string, no default)

DIR_SECSTORE

Deprecated - do not use anymore. This parameter will be deleted in one of the next releases.

(optional, string, no default)

DB_JARS

Deprecated - do not use anymore. This parameter will be deleted in one of the next releases.

(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.

(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.

(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.

(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.

(optional, string, no default)

SUPPORTED ACTIONS

This resource agent supports the following actions (operations):

start

Starts the resource. Suggested minimum timeout: 1800.

stop

Stops the resource. Suggested minimum timeout: 1800.

status

Performs a status check. Suggested minimum timeout: 60.

monitor

Performs a detailed status check. Suggested minimum timeout: 60. Suggested interval: 120.

validate-all

Performs a validation of the resource configuration. Suggested minimum timeout: 5.

meta-data

Retrieves resource agent metadata (internal use only). Suggested minimum timeout: 5.

methods

Suggested minimum timeout: 5.

EXAMPLE

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="60" interval="120"

RELATED TO ocf_heartbeat_SAPDatabase…

\m[blue]http://www.linux-ha.org/wiki/SAPDatabase_(resource_agent)\m[]

AUTHOR

Linux-HA contributors (see the resource agent source for information about individual authors)