demote
and promote
, which are responsible for changing the state of the resource. Like start
and stop
, they should return ${OCF_SUCCESS}
if they completed successfully or a relevant error code if they did not.
slave
. From there the cluster will decide which instances to promote to master
.
notify
action to be implemented. If supported, the notify action will be passed a number of extra variables which, when combined with additional context, can be used to calculate the current state of the cluster and what is about to happen to it.
Table 10.11. Environment variables supplied with multi-state notify actions [a]
Variable | Description |
---|---|
OCF_RESKEY_CRM_meta_notify_type
| |
OCF_RESKEY_CRM_meta_notify_operation
| |
OCF_RESKEY_CRM_meta_notify_active_resource
| |
OCF_RESKEY_CRM_meta_notify_inactive_resource
| |
OCF_RESKEY_CRM_meta_notify_master_resource
| |
OCF_RESKEY_CRM_meta_notify_slave_resource
| |
OCF_RESKEY_CRM_meta_notify_start_resource
| |
OCF_RESKEY_CRM_meta_notify_stop_resource
| |
OCF_RESKEY_CRM_meta_notify_promote_resource
| |
OCF_RESKEY_CRM_meta_notify_demote_resource
| |
OCF_RESKEY_CRM_meta_notify_start_uname
| |
OCF_RESKEY_CRM_meta_notify_stop_uname
| |
OCF_RESKEY_CRM_meta_notify_promote_uname
| |
OCF_RESKEY_CRM_meta_notify_demote_uname
| |
OCF_RESKEY_CRM_meta_notify_active_uname
| |
OCF_RESKEY_CRM_meta_notify_master_uname
| |
OCF_RESKEY_CRM_meta_notify_slave_uname
|