|
| 1 | +.TH ATTRD_UPDATER "8" "2026-02-27" "Pacemaker 3.0.1" "Pacemaker Manual" |
| 2 | +.SH "NAME" |
| 3 | +attrd_updater \- query and update Pacemaker node attributes |
| 4 | +. |
| 5 | +.SH "SYNOPSIS" |
| 6 | +.SY attrd_updater |
| 7 | +.B { \-n \fIattribute\fB \|| \-P \fIpattern\fB } <command> |
| 8 | +.RI [ option\~ ...] |
| 9 | +.YS |
| 10 | +. |
| 11 | +.SH "DESCRIPTION" |
| 12 | +.B attrd_updater |
| 13 | +manages transient and private node attributes. Transient node attributes are |
| 14 | +recorded in the CIB, but will be erased when the cluster is restarted. Private |
| 15 | +node attributes are never recorded in the CIB. They exist only in memory in the |
| 16 | +Pacemaker attribute daemon (\fBpacemaker\-attrd\fR) and will therefore also be |
| 17 | +erased when the cluster is restarted. |
| 18 | +.P |
| 19 | +.B attrd_updater |
| 20 | +can also be used to create attributes for cluster nodes that do not yet exist, |
| 21 | +and can manage how often attribute changes are flushed to the CIB (called |
| 22 | +"damping") to minimize disk writes for frequent changes. It is also used by |
| 23 | +resource agents, particularly node health agents, for setting and querying |
| 24 | +node status. |
| 25 | +. |
| 26 | +.SH "OPTIONS" |
| 27 | +.SS "Required arguments" |
| 28 | +One of the following arguments must be provided. These arguments are mutually |
| 29 | +exclusive. |
| 30 | +.TP |
| 31 | +.BI \-n\ \fINAME\fB,\ \-\-name=\fINAME |
| 32 | +The attribute's name. |
| 33 | +.TP |
| 34 | +.BI \-P\ \fIPATTERN\fB,\ \-\-pattern=\fIPATTERN |
| 35 | +Operate on all attributes matching this pattern (with \fB\-B\fR, \fB\-D\fR, |
| 36 | +\fB\-U\fR, or \fB\-Y\fR). Patterns are regular expressions as understood by |
| 37 | +.MR regex 7 . |
| 38 | +. |
| 39 | +.SS "Commands" |
| 40 | +One of the following commands must be provided. These options are mutually |
| 41 | +exclusive. |
| 42 | +.TP |
| 43 | +.BI \-B\ \fIVALUE\fB,\ \-\-update\-both=\fIVALUE |
| 44 | +Set the value of the given attribute (creating it if it does not already exist), |
| 45 | +or all attributes matched by the given pattern, to \fIVALUE\fR. Additionally, |
| 46 | +set the attribute's time to wait (dampening) in the attribute manager to the |
| 47 | +value given by \fB\-d\fR or \fB\-\-delay\fR. If this changes the value or |
| 48 | +dampening, the attribute will also be written to the cluster configuration, so |
| 49 | +be aware that repeatedly changing the dampening reduces its effectiveness. |
| 50 | +.TP |
| 51 | +.BR \-D ", " \-\-delete |
| 52 | +Unset the value of the given attribute, or all attributes matched by the given |
| 53 | +pattern, in the attribute manager. At the moment, there is no way to remove |
| 54 | +an attribute. This option will instead set its value to the empty string. |
| 55 | +.TP |
| 56 | +.BR \-Q ", " \-\-query |
| 57 | +Query the attribute's value from the attribute manager. By default, this will |
| 58 | +query the value of the attribute on the local node. Use \fB\-N\fR or \fB\-\-node\fR |
| 59 | +for the value on a given node, or \fB\-A\fR or \fB\-\-all\fR for the value on |
| 60 | +all nodes. |
| 61 | +.TP |
| 62 | +.BR \-R ", " \-\-refresh |
| 63 | +(Advanced) Force the attribute manager to resend all current values to the CIB. |
| 64 | +.TP |
| 65 | +.BI \-U\ \fIVALUE\fB,\ \-\-update=\fIVALUE |
| 66 | +Set the value of the given attribute (creating it if it does not already exist), |
| 67 | +or all attributes matched by the given pattern, to \fIVALUE\fR. If \fB\-d\fR or |
| 68 | +\fB\-\-delay\fR is specified, the delay will be used if the attribute needs to |
| 69 | +be created and ignored otherwise. |
| 70 | +.TP |
| 71 | +.BR \-Y ", " \-\-update-delay |
| 72 | +Set the dampening in the attribute manager for the given attribute, or all |
| 73 | +attributes matched by the given pattern, to the value given by \fB\-d\fR or |
| 74 | +\fB\-\-delay\fR. If this changes the dampening, the attribute will also be |
| 75 | +written to the cluster configuration, so be aware that repeatedly changing the |
| 76 | +dampening reduces its effectiveness. |
| 77 | +. |
| 78 | +.SS "Additional options" |
| 79 | +.TP |
| 80 | +.BR \-A ", " \-\-all |
| 81 | +Show values of the given attribute on all nodes (query only). |
| 82 | +.TP |
| 83 | +.BI \-d\ \fISECONDS\fB,\ \-\-delay=\fISECONDS |
| 84 | +The time to wait (dampening) in seconds for further changes before sending |
| 85 | +to the CIB. |
| 86 | +.TP |
| 87 | +.BI \-l\ \fITIMESPEC\fB,\ \-\-lifetime=\fITIMESPEC |
| 88 | +Use the ISO-8601 \fITIMESPEC\fR as the lifetime of the attribute. \fITIMESPEC\fR |
| 89 | +is given according to |
| 90 | +.UR https://\:en\:.wikipedia\:.org/\:wiki/\:ISO_8601#Durations |
| 91 | +.UE . |
| 92 | +This option is not yet implemented and will be silently ignored by the cluster. |
| 93 | +.TP |
| 94 | +.BI \-n\ \fINODE\fB,\ \-\-node=\fINODE |
| 95 | +Use \fINODE\fR as the node for setting and querying the attribute instead of |
| 96 | +the local one. |
| 97 | +.TP |
| 98 | +.BR \-p ", " \-\-private |
| 99 | +If a new attribute is created, do not write it to the CIB. |
| 100 | +.TP |
| 101 | +.BI \-s\ \fISET\fB,\ \-\-set=\fISE |
| 102 | +(Advanced) The attribute set in which to place the value. |
| 103 | +.TP |
| 104 | +.BI \-w\ \fIUNTIL\fB,\ \-\-wait=\fIUNTIL |
| 105 | +Wait for some event to occur before returning to the shell. Values are: |
| 106 | +.RS |
| 107 | +.IP \fIno\fR (default) |
| 108 | +Wait only for the attribute manager to acknowledge the request. |
| 109 | +.IP \fIlocal\fR |
| 110 | +Wait until the change has propagated to where a local query will return the |
| 111 | +request value, or the value set by a later request. |
| 112 | +.IP \fIcluster\fR |
| 113 | +Wait until the change has propagated to where a query anywhere on the cluster |
| 114 | +will return the requested value, or the value set by a later request. |
| 115 | +.RE |
| 116 | +.TP |
| 117 | +.BR \-z ", " \-\-utilization |
| 118 | +When creating a new attribute, create it as a node utilization attribute |
| 119 | +instead of an instance attribute. If the attribute already exists, its |
| 120 | +existing type will be used regardless (with \fB\-B\fR, \fB\-U\fR, or \fB\-Y\fR). |
| 121 | +. |
| 122 | +.SS "Output options" |
| 123 | +.TP |
| 124 | +.BI \-\-output\-as= FORMAT |
| 125 | +Specify output format as one of: text (default), xml. |
| 126 | +.TP |
| 127 | +.BI \-\-output\-to= DEST |
| 128 | +Specify file name for output (or "\-" for stdout). |
| 129 | +. |
| 130 | +.SS "Help options" |
| 131 | +.TP |
| 132 | +.BR \-h ", " \-\-help |
| 133 | +Show basic help options. |
| 134 | +.TP |
| 135 | +.B \-\-help\-additional |
| 136 | +Show additional options. |
| 137 | +.TP |
| 138 | +.B \-\-help\-all |
| 139 | +Show all help options. |
| 140 | +.TP |
| 141 | +.B \-\-help\-command |
| 142 | +Show program commands. |
| 143 | +.TP |
| 144 | +.B \-\-help\-output |
| 145 | +Show output-related help options. |
| 146 | +.TP |
| 147 | +.B \-\-help\-required |
| 148 | +Show required arguments. |
| 149 | +. |
| 150 | +.SS "Application options" |
| 151 | +.TP |
| 152 | +.BR \-$ ", " \-\-version |
| 153 | +Display software version and exit. |
| 154 | +.TP |
| 155 | +.BR \-V ", " \-\-verbose |
| 156 | +Increase debug output (may be specified multiple times). |
| 157 | +. |
| 158 | +.SH "EXIT STATUS" |
| 159 | +This is not an exhaustive list of exit statuses for \fBattrd_updater\fR. See |
| 160 | +.MR crm_error 8 |
| 161 | +for more information on converting between error codes and their names. |
| 162 | +.TP |
| 163 | +.B CRM_EX_CONFIG |
| 164 | +The given attribute does not exist. |
| 165 | +.TP |
| 166 | +.B ENOTCONN, ECONNREFUSED |
| 167 | +\fBattrd_updater\fR had problems connecting to or communicating with |
| 168 | +\fBpacemaker-attrd\fR. |
| 169 | +. |
| 170 | +.SH "EXAMPLES" |
| 171 | +.EX |
| 172 | +# \fBattrd_updater \-n "#health\-cpu" \-Q |
| 173 | +.EE |
| 174 | +.RS |
| 175 | +Query the value of the \fB#health\-cpu\fR attribute on the current node |
| 176 | +.RE |
| 177 | +.P |
| 178 | +.EX |
| 179 | +# \fBattrd_updater \-n "#health\-cpu" \-Q \-A |
| 180 | +.EE |
| 181 | +.RS |
| 182 | +Query the value of the \fB#health\-cpu\fR attribute on all cluster nodes |
| 183 | +.RE |
| 184 | +.P |
| 185 | +.EX |
| 186 | +# \fBattrd_updater \-n ABC \-U 111 |
| 187 | +.EE |
| 188 | +.RS |
| 189 | +Set the value of the \fBABC\fR attribute to \fB111\fR on the current node |
| 190 | +.RE |
| 191 | +.P |
| 192 | +.EX |
| 193 | +# \fBattrd_updater \-n ABD \-U 222 \-w cluster |
| 194 | +.EE |
| 195 | +.RS |
| 196 | +Set the value of the \fBABD\fR attribute to \fB222\fR on the current node, and |
| 197 | +do not return until this change has propagated to all cluster nodes |
| 198 | +.RE |
| 199 | +.P |
| 200 | +.EX |
| 201 | +# \fBattrd_updater \-n ABE \-U 333 \-Y \-d 15 |
| 202 | +.EE |
| 203 | +.RS |
| 204 | +Set the value of the \fBABE\fR attribute to \fB333\fR on the current node, and |
| 205 | +wait 15 seconds before sending any changes to this attribute to the CIB |
| 206 | +.RE |
| 207 | +.P |
| 208 | +.EX |
| 209 | +# \fBattrd_updater \-P "AB.*" -D |
| 210 | +.EE |
| 211 | +.RS |
| 212 | +Unset the value of all attributes matching the regular expression \fBAB.*\fR |
| 213 | +.RE |
| 214 | +. |
| 215 | +.SH "REPORTING BUGS" |
| 216 | +Report bugs to https://bugs.clusterlabs.org/enter_bug.cgi?product=Pacemaker |
| 217 | +. |
| 218 | +.SH "COPYRIGHT" |
| 219 | +Copyright © 2004-2026 the Pacemaker project contributors. |
| 220 | +.P |
| 221 | +This program is licensed under the GNU General Public License version 2 or |
| 222 | +later (GPLv2+) WITHOUT ANY WARRANTY. |
| 223 | +. |
| 224 | +.SH "SEE ALSO" |
| 225 | +.BR crm_attribute (8), |
| 226 | +.BR crm_error (8), |
| 227 | +.BR regex (7) |
0 commit comments