summaryrefslogtreecommitdiffstats
path: root/doc/sphinx/Pacemaker_Explained/collective.rst
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-06-03 13:39:28 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-06-03 13:39:28 +0000
commit7332b914bff2786ff70ccace103fc9ebdfb61a23 (patch)
tree3a8a60c4edba014c7e350be41839e3edbf2a315f /doc/sphinx/Pacemaker_Explained/collective.rst
parentAdding debian version 2.1.7-1. (diff)
downloadpacemaker-7332b914bff2786ff70ccace103fc9ebdfb61a23.tar.xz
pacemaker-7332b914bff2786ff70ccace103fc9ebdfb61a23.zip
Merging upstream version 2.1.8~rc1.
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'doc/sphinx/Pacemaker_Explained/collective.rst')
-rw-r--r--doc/sphinx/Pacemaker_Explained/collective.rst411
1 files changed, 0 insertions, 411 deletions
diff --git a/doc/sphinx/Pacemaker_Explained/collective.rst b/doc/sphinx/Pacemaker_Explained/collective.rst
index a4fa9dc..dc6832c 100644
--- a/doc/sphinx/Pacemaker_Explained/collective.rst
+++ b/doc/sphinx/Pacemaker_Explained/collective.rst
@@ -569,418 +569,7 @@ instances around the cluster.
apply to clone instances as well. This means an explicit ``resource-stickiness``
of 0 in ``rsc_defaults`` works differently from the implicit default used when
``resource-stickiness`` is not specified.
-
-Clone Resource Agent Requirements
-_________________________________
-
-Any resource can be used as an anonymous clone, as it requires no
-additional support from the resource agent. Whether it makes sense to
-do so depends on your resource and its resource agent.
-
-Resource Agent Requirements for Globally Unique Clones
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
-
-Globally unique clones require additional support in the resource agent. In
-particular, it must only respond with ``${OCF_SUCCESS}`` if the node has that
-exact instance active. All other probes for instances of the clone should
-result in ``${OCF_NOT_RUNNING}`` (or one of the other OCF error codes if
-they are failed).
-
-Individual instances of a clone are identified by appending a colon and a
-numerical offset, e.g. **apache:2**.
-
-Resource agents can find out how many copies there are by examining
-the ``OCF_RESKEY_CRM_meta_clone_max`` environment variable and which
-instance it is by examining ``OCF_RESKEY_CRM_meta_clone``.
-
-The resource agent must not make any assumptions (based on
-``OCF_RESKEY_CRM_meta_clone``) about which numerical instances are active. In
-particular, the list of active copies will not always be an unbroken
-sequence, nor always start at 0.
-
-Resource Agent Requirements for Promotable Clones
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
-
-Promotable clone resources require two extra actions, ``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.
-
-The states can mean whatever you wish, but when the resource is
-started, it must come up in the unpromoted role. From there, the
-cluster will decide which instances to promote.
-
-In addition to the clone requirements for monitor actions, agents must
-also *accurately* report which state they are in. The cluster relies
-on the agent to report its status (including role) accurately and does
-not indicate to the agent what role it currently believes it to be in.
-
-.. table:: **Role implications of OCF return codes**
- :widths: 1 3
-
- +----------------------+--------------------------------------------------+
- | Monitor Return Code | Description |
- +======================+==================================================+
- | OCF_NOT_RUNNING | .. index:: |
- | | single: OCF_NOT_RUNNING |
- | | single: OCF return code; OCF_NOT_RUNNING |
- | | |
- | | Stopped |
- +----------------------+--------------------------------------------------+
- | OCF_SUCCESS | .. index:: |
- | | single: OCF_SUCCESS |
- | | single: OCF return code; OCF_SUCCESS |
- | | |
- | | Running (Unpromoted) |
- +----------------------+--------------------------------------------------+
- | OCF_RUNNING_PROMOTED | .. index:: |
- | | single: OCF_RUNNING_PROMOTED |
- | | single: OCF return code; OCF_RUNNING_PROMOTED |
- | | |
- | | Running (Promoted) |
- +----------------------+--------------------------------------------------+
- | OCF_FAILED_PROMOTED | .. index:: |
- | | single: OCF_FAILED_PROMOTED |
- | | single: OCF return code; OCF_FAILED_PROMOTED |
- | | |
- | | Failed (Promoted) |
- +----------------------+--------------------------------------------------+
- | Other | .. index:: |
- | | single: return code |
- | | |
- | | Failed (Unpromoted) |
- +----------------------+--------------------------------------------------+
-
-Clone Notifications
-~~~~~~~~~~~~~~~~~~~
-
-If the clone has the ``notify`` meta-attribute set to **true**, and the resource
-agent supports the ``notify`` action, Pacemaker will call the action when
-appropriate, passing 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.
-
-.. index::
- single: clone; environment variables
- single: notify; environment variables
-
-.. table:: **Environment variables supplied with Clone notify actions**
- :widths: 1 1
-
- +----------------------------------------------+-------------------------------------------------------------------------------+
- | Variable | Description |
- +==============================================+===============================================================================+
- | OCF_RESKEY_CRM_meta_notify_type | .. index:: |
- | | single: environment variable; OCF_RESKEY_CRM_meta_notify_type |
- | | single: OCF_RESKEY_CRM_meta_notify_type |
- | | |
- | | Allowed values: **pre**, **post** |
- +----------------------------------------------+-------------------------------------------------------------------------------+
- | OCF_RESKEY_CRM_meta_notify_operation | .. index:: |
- | | single: environment variable; OCF_RESKEY_CRM_meta_notify_operation |
- | | single: OCF_RESKEY_CRM_meta_notify_operation |
- | | |
- | | Allowed values: **start**, **stop** |
- +----------------------------------------------+-------------------------------------------------------------------------------+
- | OCF_RESKEY_CRM_meta_notify_start_resource | .. index:: |
- | | single: environment variable; OCF_RESKEY_CRM_meta_notify_start_resource |
- | | single: OCF_RESKEY_CRM_meta_notify_start_resource |
- | | |
- | | Resources to be started |
- +----------------------------------------------+-------------------------------------------------------------------------------+
- | OCF_RESKEY_CRM_meta_notify_stop_resource | .. index:: |
- | | single: environment variable; OCF_RESKEY_CRM_meta_notify_stop_resource |
- | | single: OCF_RESKEY_CRM_meta_notify_stop_resource |
- | | |
- | | Resources to be stopped |
- +----------------------------------------------+-------------------------------------------------------------------------------+
- | OCF_RESKEY_CRM_meta_notify_active_resource | .. index:: |
- | | single: environment variable; OCF_RESKEY_CRM_meta_notify_active_resource |
- | | single: OCF_RESKEY_CRM_meta_notify_active_resource |
- | | |
- | | Resources that are running |
- +----------------------------------------------+-------------------------------------------------------------------------------+
- | OCF_RESKEY_CRM_meta_notify_inactive_resource | .. index:: |
- | | single: environment variable; OCF_RESKEY_CRM_meta_notify_inactive_resource |
- | | single: OCF_RESKEY_CRM_meta_notify_inactive_resource |
- | | |
- | | Resources that are not running |
- +----------------------------------------------+-------------------------------------------------------------------------------+
- | OCF_RESKEY_CRM_meta_notify_start_uname | .. index:: |
- | | single: environment variable; OCF_RESKEY_CRM_meta_notify_start_uname |
- | | single: OCF_RESKEY_CRM_meta_notify_start_uname |
- | | |
- | | Nodes on which resources will be started |
- +----------------------------------------------+-------------------------------------------------------------------------------+
- | OCF_RESKEY_CRM_meta_notify_stop_uname | .. index:: |
- | | single: environment variable; OCF_RESKEY_CRM_meta_notify_stop_uname |
- | | single: OCF_RESKEY_CRM_meta_notify_stop_uname |
- | | |
- | | Nodes on which resources will be stopped |
- +----------------------------------------------+-------------------------------------------------------------------------------+
- | OCF_RESKEY_CRM_meta_notify_active_uname | .. index:: |
- | | single: environment variable; OCF_RESKEY_CRM_meta_notify_active_uname |
- | | single: OCF_RESKEY_CRM_meta_notify_active_uname |
- | | |
- | | Nodes on which resources are running |
- +----------------------------------------------+-------------------------------------------------------------------------------+
-
-The variables come in pairs, such as
-``OCF_RESKEY_CRM_meta_notify_start_resource`` and
-``OCF_RESKEY_CRM_meta_notify_start_uname``, and should be treated as an
-array of whitespace-separated elements.
-
-``OCF_RESKEY_CRM_meta_notify_inactive_resource`` is an exception, as the
-matching **uname** variable does not exist since inactive resources
-are not running on any node.
-
-Thus, in order to indicate that **clone:0** will be started on **sles-1**,
-**clone:2** will be started on **sles-3**, and **clone:3** will be started
-on **sles-2**, the cluster would set:
-
-.. topic:: Notification variables
-
- .. code-block:: none
-
- OCF_RESKEY_CRM_meta_notify_start_resource="clone:0 clone:2 clone:3"
- OCF_RESKEY_CRM_meta_notify_start_uname="sles-1 sles-3 sles-2"
-
-.. note::
-
- Pacemaker will log but otherwise ignore failures of notify actions.
-
-Interpretation of Notification Variables
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
-
-**Pre-notification (stop):**
-
-* Active resources: ``$OCF_RESKEY_CRM_meta_notify_active_resource``
-* Inactive resources: ``$OCF_RESKEY_CRM_meta_notify_inactive_resource``
-* Resources to be started: ``$OCF_RESKEY_CRM_meta_notify_start_resource``
-* Resources to be stopped: ``$OCF_RESKEY_CRM_meta_notify_stop_resource``
-
-**Post-notification (stop) / Pre-notification (start):**
-
-* Active resources
-
- * ``$OCF_RESKEY_CRM_meta_notify_active_resource``
- * minus ``$OCF_RESKEY_CRM_meta_notify_stop_resource``
-* Inactive resources
-
- * ``$OCF_RESKEY_CRM_meta_notify_inactive_resource``
- * plus ``$OCF_RESKEY_CRM_meta_notify_stop_resource``
-
-* Resources that were started: ``$OCF_RESKEY_CRM_meta_notify_start_resource``
-* Resources that were stopped: ``$OCF_RESKEY_CRM_meta_notify_stop_resource``
-
-**Post-notification (start):**
-
-* Active resources:
-
- * ``$OCF_RESKEY_CRM_meta_notify_active_resource``
- * minus ``$OCF_RESKEY_CRM_meta_notify_stop_resource``
- * plus ``$OCF_RESKEY_CRM_meta_notify_start_resource``
-
-* Inactive resources:
-
- * ``$OCF_RESKEY_CRM_meta_notify_inactive_resource``
- * plus ``$OCF_RESKEY_CRM_meta_notify_stop_resource``
- * minus ``$OCF_RESKEY_CRM_meta_notify_start_resource``
-
-* Resources that were started: ``$OCF_RESKEY_CRM_meta_notify_start_resource``
-* Resources that were stopped: ``$OCF_RESKEY_CRM_meta_notify_stop_resource``
-
-Extra Notifications for Promotable Clones
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
-
-.. index::
- single: clone; environment variables
- single: promotable; environment variables
-
-.. table:: **Extra environment variables supplied for promotable clones**
- :widths: 1 1
-
- +------------------------------------------------+---------------------------------------------------------------------------------+
- | Variable | Description |
- +================================================+=================================================================================+
- | OCF_RESKEY_CRM_meta_notify_promoted_resource | .. index:: |
- | | single: environment variable; OCF_RESKEY_CRM_meta_notify_promoted_resource |
- | | single: OCF_RESKEY_CRM_meta_notify_promoted_resource |
- | | |
- | | Resources that are running in the promoted role |
- +------------------------------------------------+---------------------------------------------------------------------------------+
- | OCF_RESKEY_CRM_meta_notify_unpromoted_resource | .. index:: |
- | | single: environment variable; OCF_RESKEY_CRM_meta_notify_unpromoted_resource |
- | | single: OCF_RESKEY_CRM_meta_notify_unpromoted_resource |
- | | |
- | | Resources that are running in the unpromoted role |
- +------------------------------------------------+---------------------------------------------------------------------------------+
- | OCF_RESKEY_CRM_meta_notify_promote_resource | .. index:: |
- | | single: environment variable; OCF_RESKEY_CRM_meta_notify_promote_resource |
- | | single: OCF_RESKEY_CRM_meta_notify_promote_resource |
- | | |
- | | Resources to be promoted |
- +------------------------------------------------+---------------------------------------------------------------------------------+
- | OCF_RESKEY_CRM_meta_notify_demote_resource | .. index:: |
- | | single: environment variable; OCF_RESKEY_CRM_meta_notify_demote_resource |
- | | single: OCF_RESKEY_CRM_meta_notify_demote_resource |
- | | |
- | | Resources to be demoted |
- +------------------------------------------------+---------------------------------------------------------------------------------+
- | OCF_RESKEY_CRM_meta_notify_promote_uname | .. index:: |
- | | single: environment variable; OCF_RESKEY_CRM_meta_notify_promote_uname |
- | | single: OCF_RESKEY_CRM_meta_notify_promote_uname |
- | | |
- | | Nodes on which resources will be promoted |
- +------------------------------------------------+---------------------------------------------------------------------------------+
- | OCF_RESKEY_CRM_meta_notify_demote_uname | .. index:: |
- | | single: environment variable; OCF_RESKEY_CRM_meta_notify_demote_uname |
- | | single: OCF_RESKEY_CRM_meta_notify_demote_uname |
- | | |
- | | Nodes on which resources will be demoted |
- +------------------------------------------------+---------------------------------------------------------------------------------+
- | OCF_RESKEY_CRM_meta_notify_promoted_uname | .. index:: |
- | | single: environment variable; OCF_RESKEY_CRM_meta_notify_promoted_uname |
- | | single: OCF_RESKEY_CRM_meta_notify_promoted_uname |
- | | |
- | | Nodes on which resources are running in the promoted role |
- +------------------------------------------------+---------------------------------------------------------------------------------+
- | OCF_RESKEY_CRM_meta_notify_unpromoted_uname | .. index:: |
- | | single: environment variable; OCF_RESKEY_CRM_meta_notify_unpromoted_uname |
- | | single: OCF_RESKEY_CRM_meta_notify_unpromoted_uname |
- | | |
- | | Nodes on which resources are running in the unpromoted role |
- +------------------------------------------------+---------------------------------------------------------------------------------+
-
-Interpretation of Promotable Notification Variables
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
-
-**Pre-notification (demote):**
-
-* Active resources: ``$OCF_RESKEY_CRM_meta_notify_active_resource``
-* Promoted resources: ``$OCF_RESKEY_CRM_meta_notify_promoted_resource``
-* Unpromoted resources: ``$OCF_RESKEY_CRM_meta_notify_unpromoted_resource``
-* Inactive resources: ``$OCF_RESKEY_CRM_meta_notify_inactive_resource``
-* Resources to be started: ``$OCF_RESKEY_CRM_meta_notify_start_resource``
-* Resources to be promoted: ``$OCF_RESKEY_CRM_meta_notify_promote_resource``
-* Resources to be demoted: ``$OCF_RESKEY_CRM_meta_notify_demote_resource``
-* Resources to be stopped: ``$OCF_RESKEY_CRM_meta_notify_stop_resource``
-
-**Post-notification (demote) / Pre-notification (stop):**
-
-* Active resources: ``$OCF_RESKEY_CRM_meta_notify_active_resource``
-* Promoted resources:
-
- * ``$OCF_RESKEY_CRM_meta_notify_promoted_resource``
- * minus ``$OCF_RESKEY_CRM_meta_notify_demote_resource``
-
-* Unpromoted resources: ``$OCF_RESKEY_CRM_meta_notify_unpromoted_resource``
-* Inactive resources: ``$OCF_RESKEY_CRM_meta_notify_inactive_resource``
-* Resources to be started: ``$OCF_RESKEY_CRM_meta_notify_start_resource``
-* Resources to be promoted: ``$OCF_RESKEY_CRM_meta_notify_promote_resource``
-* Resources to be demoted: ``$OCF_RESKEY_CRM_meta_notify_demote_resource``
-* Resources to be stopped: ``$OCF_RESKEY_CRM_meta_notify_stop_resource``
-* Resources that were demoted: ``$OCF_RESKEY_CRM_meta_notify_demote_resource``
-
-**Post-notification (stop) / Pre-notification (start)**
-
-* Active resources:
-
- * ``$OCF_RESKEY_CRM_meta_notify_active_resource``
- * minus ``$OCF_RESKEY_CRM_meta_notify_stop_resource``
-
-* Promoted resources:
-
- * ``$OCF_RESKEY_CRM_meta_notify_promoted_resource``
- * minus ``$OCF_RESKEY_CRM_meta_notify_demote_resource``
-
-* Unpromoted resources:
-
- * ``$OCF_RESKEY_CRM_meta_notify_unpromoted_resource``
- * minus ``$OCF_RESKEY_CRM_meta_notify_stop_resource``
-
-* Inactive resources:
-
- * ``$OCF_RESKEY_CRM_meta_notify_inactive_resource``
- * plus ``$OCF_RESKEY_CRM_meta_notify_stop_resource``
-
-* Resources to be started: ``$OCF_RESKEY_CRM_meta_notify_start_resource``
-* Resources to be promoted: ``$OCF_RESKEY_CRM_meta_notify_promote_resource``
-* Resources to be demoted: ``$OCF_RESKEY_CRM_meta_notify_demote_resource``
-* Resources to be stopped: ``$OCF_RESKEY_CRM_meta_notify_stop_resource``
-* Resources that were demoted: ``$OCF_RESKEY_CRM_meta_notify_demote_resource``
-* Resources that were stopped: ``$OCF_RESKEY_CRM_meta_notify_stop_resource``
-
-**Post-notification (start) / Pre-notification (promote)**
-
-* Active resources:
-
- * ``$OCF_RESKEY_CRM_meta_notify_active_resource``
- * minus ``$OCF_RESKEY_CRM_meta_notify_stop_resource``
- * plus ``$OCF_RESKEY_CRM_meta_notify_start_resource``
-
-* Promoted resources:
-
- * ``$OCF_RESKEY_CRM_meta_notify_promoted_resource``
- * minus ``$OCF_RESKEY_CRM_meta_notify_demote_resource``
-
-* Unpromoted resources:
-
- * ``$OCF_RESKEY_CRM_meta_notify_unpromoted_resource``
- * minus ``$OCF_RESKEY_CRM_meta_notify_stop_resource``
- * plus ``$OCF_RESKEY_CRM_meta_notify_start_resource``
-
-* Inactive resources:
-
- * ``$OCF_RESKEY_CRM_meta_notify_inactive_resource``
- * plus ``$OCF_RESKEY_CRM_meta_notify_stop_resource``
- * minus ``$OCF_RESKEY_CRM_meta_notify_start_resource``
-
-* Resources to be started: ``$OCF_RESKEY_CRM_meta_notify_start_resource``
-* Resources to be promoted: ``$OCF_RESKEY_CRM_meta_notify_promote_resource``
-* Resources to be demoted: ``$OCF_RESKEY_CRM_meta_notify_demote_resource``
-* Resources to be stopped: ``$OCF_RESKEY_CRM_meta_notify_stop_resource``
-* Resources that were started: ``$OCF_RESKEY_CRM_meta_notify_start_resource``
-* Resources that were demoted: ``$OCF_RESKEY_CRM_meta_notify_demote_resource``
-* Resources that were stopped: ``$OCF_RESKEY_CRM_meta_notify_stop_resource``
-
-**Post-notification (promote)**
-
-* Active resources:
-
- * ``$OCF_RESKEY_CRM_meta_notify_active_resource``
- * minus ``$OCF_RESKEY_CRM_meta_notify_stop_resource``
- * plus ``$OCF_RESKEY_CRM_meta_notify_start_resource``
-
-* Promoted resources:
-
- * ``$OCF_RESKEY_CRM_meta_notify_promoted_resource``
- * minus ``$OCF_RESKEY_CRM_meta_notify_demote_resource``
- * plus ``$OCF_RESKEY_CRM_meta_notify_promote_resource``
-
-* Unpromoted resources:
-
- * ``$OCF_RESKEY_CRM_meta_notify_unpromoted_resource``
- * minus ``$OCF_RESKEY_CRM_meta_notify_stop_resource``
- * plus ``$OCF_RESKEY_CRM_meta_notify_start_resource``
- * minus ``$OCF_RESKEY_CRM_meta_notify_promote_resource``
-
-* Inactive resources:
-
- * ``$OCF_RESKEY_CRM_meta_notify_inactive_resource``
- * plus ``$OCF_RESKEY_CRM_meta_notify_stop_resource``
- * minus ``$OCF_RESKEY_CRM_meta_notify_start_resource``
-
-* Resources to be started: ``$OCF_RESKEY_CRM_meta_notify_start_resource``
-* Resources to be promoted: ``$OCF_RESKEY_CRM_meta_notify_promote_resource``
-* Resources to be demoted: ``$OCF_RESKEY_CRM_meta_notify_demote_resource``
-* Resources to be stopped: ``$OCF_RESKEY_CRM_meta_notify_stop_resource``
-* Resources that were started: ``$OCF_RESKEY_CRM_meta_notify_start_resource``
-* Resources that were promoted: ``$OCF_RESKEY_CRM_meta_notify_promote_resource``
-* Resources that were demoted: ``$OCF_RESKEY_CRM_meta_notify_demote_resource``
-* Resources that were stopped: ``$OCF_RESKEY_CRM_meta_notify_stop_resource``
-
Monitoring Promotable Clone Resources
_____________________________________