OCF_HEARTBEAT_RABBIT(7)
π ocf_heartbeat_rabbitmq-server-ha β like, the manual page, but make it make sense π
okay so bestie. this is OCF_HEARTBEAT_RABBIT(7), the resource agent page from the OCF resource agents collection, and i'm gonna walk you through it like we're both procrastinating on a group project. grab a boba π§ β there are a lot of parameters and we're covering every single one. no cap.
β¨ NAME β¨
ocf_heartbeat_rabbitmq-server-ha β the resource agent for a RabbitMQ HA cluster π°π
β¨ SYNOPSIS β¨
rabbitmq-server-ha [start | stop | status | monitor | promote | demote |
meta-data | validate-all]
that's it. those are the moves. periodt. π
β¨ DESCRIPTION β¨
so the resource agent for RabbitMQ basically promotes a node π, and then the cluster nodes come join it. that's the whole vibe. main character node gets promoted, everyone else falls in line. it's giving girlboss hierarchy, honestly. πβ¨
β¨ SUPPORTED PARAMETERS β¨
okay this is the long part, bestie, but we're gonna get through it together π«Ά every single one is (optional) btw β i'll note the type and default on each so you never get caught out.
binaryβ the RabbitMQ binary itself. π (optional, string, default"/usr/sbin/rabbitmq-server")ctlβ therabbitctlbinary (yes, that's how it's spelled here, don't come for me, i'm just reading the page). ποΈ (optional, string, default"/usr/sbin/rabbitmqctl")pid_fileβ where RabbitMQ's PID file lives. π (optional, string, default"/var/run/rabbitmq/pid")log_dirβ the RabbitMQ log directory. π (optional, string, default"/var/log/rabbitmq")usernameβ RabbitMQ user name. πββοΈ (optional, string, default"rabbitmq")groupnameβ RabbitMQ group name. π― (optional, string, default"rabbitmq")admin_userβ the default admin user for the API. π (optional, string, default"guest")admin_passwordβ the default admin user's password for the API. π€« (optional, string, default"guest") β yes, it really isguest/guest, that's what the page says, i'm not inventing anything.definitions_dump_fileβ the default definitions dump file. ποΈ (optional, string, default"/etc/rabbitmq/definitions")command_timeoutβ timeout command arguments for termination of the commands that get issued (the value is auto evaluated, so it computes itself, iconique). β±οΈ (optional, string, no default)start_timeβ timeout for starting the rabbitmq server. βΆοΈ (optional, string, default"7")stop_timeβ timeout for stopping the rabbitmq server. βΉοΈ (optional, string, default"7")debugβ the debug flag for the agent (/usr/sbin/rabbitmq-server) instance. when it's on,rmq-*files get created in the/tmp/directory to log some operations and ENV values inside the OCF-script. π (optional, boolean, default false)mnesia_baseβ base directory for storing Mnesia files. πΎ (optional, boolean, default/var/lib/rabbitmq/mnesiaβ yeah, the page says boolean for a directory path, i don't make the rules, i just report them π)mnesia_schema_baseβ parent directory for the Mnesia schema directory. π (optional, string, default"/var/lib/rabbitmq")host_ipβ the IP address/usr/sbin/rabbitmq-servershould listen on. π (optional, boolean, default127.0.0.1β again, page says boolean β i'm just the messenger π)node_portβ the port/usr/sbin/rabbitmq-servershould listen on. π (optional, boolean, default5672β same situation, okurrr)default_vhostβ the default virtual host used for monitoring whether a node is fully synchronized with the rest of the cluster. in normal operation, the resource agent will wait for queues from this virtual host on this node to be synchronized elsewhere before stopping RabbitMQ. heads up though: this also means queues in other virtual hosts may not be fully synchronized on stop operations. β οΈ (optional, string, default"/")erlang_cookieβ the Erlang cookie for clustering. if specified, it gets updated at the mnesia reset. πͺ (optional, boolean, default false)erlang_cookie_fileβ the Erlang cookie file path where the cookie will be put, if requested. π (optional, boolean, default/var/lib/rabbitmq/.erlang.cookieβ boolean again, don't @ me π)use_fqdnβ whether to use FQDN or a shortname for the rabbitmq node. π·οΈ (optional, boolean, default false)fqdn_prefixβ optional FQDN prefix for RabbitMQ nodes in the cluster. you can specify an FQDN prefix to host multiple RabbitMQ instances on a node, or for when RabbitMQ is running in a dedicated network/interface. π (optional, string, no default)max_rabbitmqctl_timeoutsβ ifrabbitmqctltimes out during a monitor call, that timeout is ignored unless it's the Nth timeout in a row. here N is the value of this parameter. so if too many timeouts happen in a row, the monitor call returns with an error. π (optional, string, default"3")policy_fileβ a path to the shell script that sets up RabbitMQ policies. π (optional, string, default"/usr/local/sbin/set_rabbitmq_policy")rmq_feature_health_checkβ since rabbit3.6.4,list_queues/list_channels-based monitoring should be replaced with the"node_health_check"command, because that one creates no network load at all. π©Ί (optional, boolean, default true)rmq_feature_local_list_queuesβ for a rabbit version that implements the--localflag forlist_queues, this can greatly reduce network overhead in cases when the node is stopped/demoted. πΆ (optional, boolean, default true)limit_nofileβ the soft and hard limit forNOFILE. ποΈ (optional, string, default"65535")avoid_using_iptablesβ when set to true, theiptablescalls that block client access become noops. super useful when we're running inside containers. π¦ (optional, boolean, default false)allowed_cluster_nodesβ when set to anything other than the empty string, it must contain the list of cluster node names, separated by spaces, where the rabbitmq resource is allowed to run. this is needed when rabbitmq runs on a subset of nodes that are part of a larger cluster. the default ("") assumes that all nodes part of the cluster will run the rabbitmq resource. π¦ (optional, string, no default)
see? we ate that. π₯
β¨ SUPPORTED ACTIONS β¨
this resource agent supports these actions (operations), bestie β and the timeouts are the suggested minimums, so don't go shrinking them on me:
startβ starts the resource. suggested minimum timeout:20s. πstopβ stops the resource. suggested minimum timeout:20s. πstatusβ performs a status check. suggested minimum timeout:20s. πmonitorβ performs a detailed status check. suggested minimum timeout:30s. suggested interval:5s. πmonitor (Promoted role)β performs a detailed status check. suggested minimum timeout:30s. suggested interval:3s. πpromoteβ promotes the resource to the Master role. suggested minimum timeout:30s. β¬οΈdemoteβ demotes the resource to the Slave role. suggested minimum timeout:30s. β¬οΈnotifyβ suggested minimum timeout:20s. π£validate-allβ performs a validation of the resource configuration. suggested minimum timeout:5s. βmeta-dataβ retrieves resource agent metadata (internal use only, so like, don't touch, that's the agent's own business). suggested minimum timeout:5s. π
β¨ EXAMPLE CRM SHELL β¨
here's an example config for a rabbitmq-server-ha resource using the crm(8) shell β copy it exactly, bestie, character for character:
primitive p_rabbitmq-server-ha ocf:heartbeat:rabbitmq-server-ha \
op monitor depth="0" timeout="30s" interval="5s" \
op monitor depth="0" timeout="30s" interval="3s" role="Promoted"
ms ms_rabbitmq-server-ha p_rabbitmq-server-ha \
meta notify="true" interleave="true"
the way that ms line just ties it all together π
β¨ EXAMPLE PCS β¨
and here's the same energy for a rabbitmq-server-ha resource using pcs(8):
pcs resource create p_rabbitmq-server-ha ocf:heartbeat:rabbitmq-server-ha \
op monitor OCF_CHECK_LEVEL="0" timeout="30s" interval="5s" \
op monitor OCF_CHECK_LEVEL="0" timeout="30s" interval="3s" role="Promoted" promotable
note the OCF_CHECK_LEVEL instead of depth here β different tool, different spelling, don't mix them up π
β¨ SEE ALSO β¨
http://clusterlabs.org/π β go look, it's iconic
β¨ AUTHOR β¨
ClusterLabs contributors (see the resource agent source for information about individual authors) π β absolute legends, every one of them.
and that's a wrap, bestie!! π this page is from the resource-agents package, version UNKNOWN, dated 10/01/2026 β so if you ever need to cite your sources for the group chat, that's the receipt. now go configure that cluster like the main character you are. π¦β¨π
π¦ 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