24check_placement_strategy(
const char *value)
37 "no-quorum-policy", NULL,
"select",
"stop, freeze, ignore, demote, suicide",
39 N_(
"What to do when the cluster does not have quorum"),
43 "symmetric-cluster", NULL,
"boolean", NULL,
45 N_(
"Whether resources can run on any node by default"),
49 "maintenance-mode", NULL,
"boolean", NULL,
51 N_(
"Whether the cluster should refrain from monitoring, starting, "
52 "and stopping resources"),
56 "start-failure-is-fatal", NULL,
"boolean", NULL,
58 N_(
"Whether a start failure should prevent a resource from being "
59 "recovered on the same node"),
60 N_(
"When true, the cluster will immediately ban a resource from a node "
61 "if it fails to start there. When false, the cluster will instead "
62 "check the resource's fail count against its migration-threshold.")
65 "enable-startup-probes", NULL,
"boolean", NULL,
67 N_(
"Whether the cluster should check for active resources during start-up"),
73 N_(
"Whether to lock resources to a cleanly shut down node"),
74 N_(
"When true, resources active on a node when it is cleanly shut down "
75 "are kept \"locked\" to that node (not allowed to run elsewhere) "
76 "until they start again on that node after it rejoins (or for at "
77 "most shutdown-lock-limit, if set). Stonith resources and "
78 "Pacemaker Remote connections are never locked. Clone and bundle "
79 "instances and the promoted role of promotable clones are "
80 "currently never locked, though support could be added in a future "
86 N_(
"Do not lock resources to a cleanly shut down node longer than "
88 N_(
"If shutdown-lock is true and this is set to a nonzero time "
89 "duration, shutdown locks will expire after this much time has "
90 "passed since the shutdown was initiated, even if the node has not "
96 "stonith-enabled", NULL,
"boolean", NULL,
98 N_(
"*** Advanced Use Only *** "
99 "Whether nodes may be fenced as part of recovery"),
100 N_(
"If false, unresponsive nodes are immediately assumed to be harmless, "
101 "and resources that were active on them may be recovered "
102 "elsewhere. This can result in a \"split-brain\" situation, "
103 "potentially leading to data loss and/or service unavailability.")
106 "stonith-action", NULL,
"select",
"reboot, off, poweroff",
108 N_(
"Action to send to fence device when a node needs to be fenced "
109 "(\"poweroff\" is a deprecated alias for \"off\")"),
113 "stonith-timeout", NULL,
"time", NULL,
115 N_(
"*** Advanced Use Only *** Unused by Pacemaker"),
116 N_(
"This value is not used by Pacemaker, but is kept for backward "
117 "compatibility, and certain legacy fence agents might use it.")
122 N_(
"Whether watchdog integration is enabled"),
123 N_(
"This is set automatically by the cluster according to whether SBD "
124 "is detected to be in use. User-configured values are ignored. "
125 "The value `true` is meaningful if diskless SBD is used and "
126 "`stonith-watchdog-timeout` is nonzero. In that case, if fencing "
127 "is required, watchdog-based self-fencing will be performed via "
128 "SBD without requiring a fencing resource explicitly configured.")
131 "concurrent-fencing", NULL,
"boolean", NULL,
133 N_(
"Allow performing fencing operations in parallel"),
137 "startup-fencing", NULL,
"boolean", NULL,
139 N_(
"*** Advanced Use Only *** Whether to fence unseen nodes at start-up"),
140 N_(
"Setting this to false may lead to a \"split-brain\" situation,"
141 "potentially leading to data loss and/or service unavailability.")
146 N_(
"Apply fencing delay targeting the lost nodes with the highest total resource priority"),
147 N_(
"Apply specified delay for the fencings that are targeting the lost "
148 "nodes with the highest total resource priority in case we don't "
149 "have the majority of the nodes in our cluster partition, so that "
150 "the more significant nodes potentially win any fencing match, "
151 "which is especially meaningful under split-brain of 2-node "
152 "cluster. A promoted resource instance takes the base priority + 1 "
153 "on calculation if the base priority is not 0. Any static/random "
154 "delays that are introduced by `pcmk_delay_base/max` configured "
155 "for the corresponding fencing resources will be added to this "
156 "delay. This delay should be significantly greater than, safely "
157 "twice, the maximum `pcmk_delay_base/max`. By default, priority "
158 "fencing delay is disabled.")
162 "cluster-delay", NULL,
"time", NULL,
164 N_(
"Maximum time for node-to-node communication"),
165 N_(
"The node elected Designated Controller (DC) will consider an action "
166 "failed if it does not get a response from the node executing the "
167 "action within this time (after considering the action's own "
168 "timeout). The \"correct\" value will depend on the speed and "
169 "load of your network and cluster nodes.")
172 "batch-limit", NULL,
"integer", NULL,
174 N_(
"Maximum number of jobs that the cluster may execute in parallel "
176 N_(
"The \"correct\" value will depend on the speed and load of your "
177 "network and cluster nodes. If set to 0, the cluster will "
178 "impose a dynamically calculated limit when any node has a "
182 "migration-limit", NULL,
"integer", NULL,
184 N_(
"The number of live migration actions that the cluster is allowed "
185 "to execute in parallel on a node (-1 means no limit)")
190 "stop-all-resources", NULL,
"boolean", NULL,
192 N_(
"Whether the cluster should stop all active resources"),
196 "stop-orphan-resources", NULL,
"boolean", NULL,
198 N_(
"Whether to stop resources that were removed from the configuration"),
202 "stop-orphan-actions", NULL,
"boolean", NULL,
204 N_(
"Whether to cancel recurring actions removed from the configuration"),
208 "remove-after-stop", NULL,
"boolean", NULL,
210 N_(
"*** Deprecated *** Whether to remove stopped resources from "
212 N_(
"Values other than default are poorly tested and potentially dangerous."
213 " This option will be removed in a future release.")
218 "pe-error-series-max", NULL,
"integer", NULL,
220 N_(
"The number of scheduler inputs resulting in errors to save"),
221 N_(
"Zero to disable, -1 to store unlimited.")
224 "pe-warn-series-max", NULL,
"integer", NULL,
226 N_(
"The number of scheduler inputs resulting in warnings to save"),
227 N_(
"Zero to disable, -1 to store unlimited.")
230 "pe-input-series-max", NULL,
"integer", NULL,
232 N_(
"The number of scheduler inputs without errors or warnings to save"),
233 N_(
"Zero to disable, -1 to store unlimited.")
243 N_(
"How cluster should react to node health attributes"),
244 N_(
"Requires external entities to create node attributes (named with "
245 "the prefix \"#health\") with values \"red\", "
246 "\"yellow\", or \"green\".")
251 N_(
"Base health score assigned to a node"),
252 N_(
"Only used when \"node-health-strategy\" is set to \"progressive\".")
257 N_(
"The score to use for a node health attribute whose value is \"green\""),
258 N_(
"Only used when \"node-health-strategy\" is set to \"custom\" or \"progressive\".")
263 N_(
"The score to use for a node health attribute whose value is \"yellow\""),
264 N_(
"Only used when \"node-health-strategy\" is set to \"custom\" or \"progressive\".")
269 N_(
"The score to use for a node health attribute whose value is \"red\""),
270 N_(
"Only used when \"node-health-strategy\" is set to \"custom\" or \"progressive\".")
275 "placement-strategy", NULL,
"select",
276 "default, utilization, minimal, balanced",
277 "default", check_placement_strategy,
278 N_(
"How the cluster should allocate resources to nodes"),
286 const char *desc_short =
"Pacemaker scheduler options";
287 const char *desc_long =
"Cluster options used by Pacemaker's scheduler";
311 const char *
result =
"<unknown>";
339 result =
"restart-container";
390 crm_trace(
"Unsupported action: %s", task);
399 const char *
result =
"<unknown>";
460#ifdef PCMK__COMPAT_2_0
466#ifdef PCMK__COMPAT_2_0
495 crm_err(
"Unknown role: %s", role);
504 crm_trace(
"Adding name='%s' value='%s' to hash table",
505 pcmk__s(
name,
"<null>"), pcmk__s(value,
"<null>"));
506 if (
name == NULL || value == NULL) {
512 }
else if (g_hash_table_lookup(hash,
name) == NULL) {
513 g_hash_table_insert(hash, strdup(
name), strdup(value));
526 }
else if(rsc == NULL) {
547 pe_rsc_trace(rsc,
"%s: Looking for %s on the container host %s",
549 return g_hash_table_lookup(
host->details->attrs,
name);
552 pe_rsc_trace(rsc,
"%s: Not looking for %s on the container host: %s is inactive",
bool pcmk__is_fencing_action(const char *action)
void verify_pe_options(GHashTable *options)
enum action_tasks text2task(const char *task)
const char * pe_node_attribute_raw(const pe_node_t *node, const char *name)
gboolean was_processing_error
const char * fail2text(enum action_fail_response fail)
const char * role2text(enum rsc_role_e role)
const char * task2text(enum action_tasks task)
const char * pe_pref(GHashTable *options, const char *name)
gboolean was_processing_warning
const char * pe_node_attribute_calculated(const pe_node_t *node, const char *name, const pe_resource_t *rsc)
void pe_metadata(pcmk__output_t *out)
enum rsc_role_e text2role(const char *role)
void add_hash_param(GHashTable *hash, const char *name, const char *value)
#define RSC_ROLE_UNPROMOTED_S
#define RSC_ROLE_PROMOTED_LEGACY_S
#define RSC_ROLE_STARTED_S
@ action_fail_reset_remote
@ action_fail_restart_container
#define RSC_ROLE_STOPPED_S
#define RSC_ROLE_UNPROMOTED_LEGACY_S
rsc_role_e
Possible roles that a resource can be in.
#define RSC_ROLE_PROMOTED_S
#define RSC_ROLE_UNKNOWN_S
#define PCMK__CONCURRENT_FENCING_DEFAULT
#define CRMD_ACTION_DEMOTED
#define CRMD_ACTION_CANCEL
#define CRMD_ACTION_NOTIFY
#define CRMD_ACTION_PROMOTED
#define CRMD_ACTION_MIGRATED
#define CRMD_ACTION_STATUS
#define CRMD_ACTION_DEMOTE
#define CRMD_ACTION_STARTED
#define CRMD_ACTION_DELETE
#define CRMD_ACTION_MIGRATE
#define CRMD_ACTION_START
#define CRMD_ACTION_PROMOTE
#define CRMD_ACTION_STOPPED
#define CRMD_ACTION_NOTIFIED
bool pcmk__validate_health_strategy(const char *value)
#define CRM_CHECK(expr, failure_action)
#define crm_err(fmt, args...)
#define crm_trace(fmt, args...)
#define XML_RSC_ATTR_TARGET
#define XML_ATTR_HAVE_WATCHDOG
#define XML_CONFIG_ATTR_PRIORITY_FENCING_DELAY
#define XML_CONFIG_ATTR_SHUTDOWN_LOCK
#define XML_CONFIG_ATTR_SHUTDOWN_LOCK_LIMIT
#define PCMK__OPT_NODE_HEALTH_STRATEGY
bool pcmk__valid_interval_spec(const char *value)
#define PCMK__VALUE_MIGRATE_ON_RED
#define PCMK__VALUE_ONLY_GREEN
bool pcmk__valid_boolean(const char *value)
bool pcmk__valid_number(const char *value)
#define PCMK__OPT_NODE_HEALTH_RED
#define PCMK__VALUE_PROGRESSIVE
gchar * pcmk__format_option_metadata(const char *name, const char *desc_short, const char *desc_long, pcmk__cluster_option_t *option_list, int len)
bool pcmk__valid_quorum(const char *value)
#define PCMK__OPT_NODE_HEALTH_GREEN
const char * pcmk__cluster_option(GHashTable *options, const pcmk__cluster_option_t *option_list, int len, const char *name)
void pcmk__validate_cluster_options(GHashTable *options, pcmk__cluster_option_t *option_list, int len)
#define PCMK__OPT_NODE_HEALTH_BASE
#define PCMK__VALUE_CUSTOM
#define PCMK__OPT_NODE_HEALTH_YELLOW
pcmk__action_result_t result
#define pe_rsc_trace(rsc, fmt, args...)
bool pcmk__strcase_any_of(const char *s,...) G_GNUC_NULL_TERMINATED
This structure contains everything that makes up a single output formatter.
int(*) int(*) void(*) void(* output_xml)(pcmk__output_t *out, const char *name, const char *buf)
struct pe_node_shared_s * details
pe_resource_t * remote_rsc
pe_resource_t * container
Wrappers for and extensions to libxml2.