1RABBITMQ-DIAGNOSTICS(8)   BSD System Manager's Manual  RABBITMQ-DIAGNOSTICS(8)
2

NAME

4     rabbitmq-diagnostics — RabbitMQ diagnostics, monitoring and health checks
5     tools
6

SYNOPSIS

8     rabbitmq-diagnostics [-q] [-s] [-l] [-n node] [-t timeout] command
9                          [command_options]
10

DESCRIPTION

12     rabbitmq-diagnostics is a command line tool that provides commands used
13     for diagnostics, monitoring and health checks of RabbitMQ nodes.  See the
14     RabbitMQ documentation guides: https://rabbitmq.com/documentation.html to
15     learn more about RabbitMQ diagnostics, monitoring and health checks.
16
17     rabbitmq-diagnostics allows the operator to inspect node and cluster
18     state. A number of health checks are available to be used interactively
19     and by monitoring tools.
20
21
22     By default if it is not possible to connect to and authenticate with the
23     target node (for example if it is stopped), the operation will fail.  To
24     learn more, see the RabbitMQ Monitoring guide:
25     https://rabbitmq.com/monitoring.html
26

OPTIONS

28     -n node
29             Default node is "rabbit@target-hostname", where target-hostname
30             is the local host.  On a host named "myserver.example.com", the
31             node name will usually be "rabbit@myserver" (unless
32             RABBITMQ_NODENAME has been overridden).  The output of "hostname
33             -s" is usually the correct suffix to use after the "@" sign.  See
34             rabbitmq-server(8) for details of configuring a RabbitMQ node.
35
36     -q, --quiet
37             Quiet output mode is selected.  Informational messages are re‐
38             duced when quiet mode is in effect.
39
40     -s, --silent
41             Silent output mode is selected.  Informational messages are re‐
42             duced and table headers are suppressed when silent mode is in ef‐
43             fect.
44
45     -t timeout, --timeout timeout
46             Operation timeout in seconds.  Not all commands support timeouts.
47             Default is infinity.
48
49     -l, --longnames
50             Must be specified when the cluster is configured to use long
51             (FQDN) node names.  To learn more, see the RabbitMQ Clustering
52             guide: https://rabbitmq.com/clustering.html
53
54     --erlang-cookie cookie
55             Shared secret to use to authenticate to the target node.  Prefer
56             using a local file or the RABBITMQ_ERLANG_COOKIE environment
57             variable instead of specifying this option on the command line.
58             To learn more, see the RabbitMQ CLI Tools guide:
59             https://rabbitmq.com/cli.html
60

COMMANDS

62     Most commands provided by rabbitmq-diagnostics inspect node and cluster
63     state or perform health checks.
64
65     Commands that list topology entities (e.g. queues) use tab as column de‐
66     limiter.  These commands and their arguments are delegated to rabbit‐
67     mqctl(8).
68
69     Some commands ( list_queues, list_exchanges, list_bindings and
70     list_consumers) accept an optional vhost parameter.
71
72     The list_queues, list_exchanges and list_bindings commands accept an op‐
73     tional virtual host parameter for which to display results.  The default
74     value is "/".
75
76 Help
77   help [-l] [command_name]
78
79           Prints usage for all available commands.
80
81           -l, --list-commands
82                   List command usages only, without parameter explanation.
83
84           command_name
85                   Prints usage for the specified command.
86
87   version
88
89           Displays CLI tools version
90
91 Nodes
92   wait
93
94           See wait in rabbitmqctl(8)
95
96 Cluster
97   cluster_status
98
99           See cluster_status in rabbitmqctl(8)
100
101 Users
102   list_users
103
104           See list_users in rabbitmqctl(8)
105
106 Access Control
107   list_permissions [-p vhost]
108
109           See list_permissions in rabbitmqctl(8)
110
111   list_topic_permissions [-p vhost]
112
113           See list_topic_permissions in rabbitmqctl(8)
114
115   list_user_permissions username
116
117           See list_user_permissions in rabbitmqctl(8)
118
119   list_user_topic_permissions username
120
121           See list_user_topic_permissions in rabbitmqctl(8)
122
123   list_vhosts [vhostinfoitem ...]
124
125           See list_vhosts in rabbitmqctl(8)
126
127 Monitoring, observability and health checks
128   alarms
129
130           Lists resource alarms, if any, in the cluster.
131
132           See RabbitMQ Resource Alarms guide:
133           https://rabbitmq.com/alarms.html to learn more.
134
135           Example:
136                 rabbitmq-diagnostics alarms
137
138   certificates
139
140           Displays the node certificates for every listener on target node
141           that is configured to use TLS.
142
143           Example:
144
145                 rabbitmq-diagnostics certificates
146
147   check_alarms
148
149           Health check that fails (returns with a non-zero code) if there are
150           alarms in effect on any of the cluster nodes.
151
152           See RabbitMQ Resource Alarms guide:
153           https://rabbitmq.com/alarms.html to learn more.
154
155           Example:
156                 rabbitmq-diagnostics check_alarms
157
158   check_certificate_expiration [--unit time_unit] [--within seconds]
159
160           Checks the expiration date on the certificates for every listener
161           on target node that is configured to use TLS.  Supported time units
162           are:
163
164           days
165
166           weeks
167
168           months
169
170           years
171
172           Example:
173                 rabbitmq-diagnostics check_certificate_expiration --unit
174                 weeks --within 6
175
176   check_local_alarms
177
178           Health check that fails (returns with a non-zero code) if there are
179           alarms in effect on the target node.
180
181           See RabbitMQ Resource Alarms guide:
182           https://rabbitmq.com/alarms.html to learn more.
183
184           Example:
185                 rabbitmq-diagnostics check_local_alarms
186
187   check_port_connectivity
188
189           Health check that fails (returns with a non-zero code) if any lis‐
190           tener ports on the target node cannot accept a new TCP connection
191           opened by rabbitmq-diagnostics
192
193           The check only validates if a new TCP connection is accepted. It
194           does not perform messaging protocol handshake or authenticate.
195
196           See RabbitMQ Networking guide: https://rabbitmq.com/networking.html
197           to learn more.
198
199           Example:
200                 rabbitmq-diagnostics check_port_connectivity
201
202   check_port_listener port
203
204           Health check that fails (returns with a non-zero code) if the tar‐
205           get node is not listening on the specified port (there is no lis‐
206           tener that uses that port).
207
208           See RabbitMQ Networking guide: https://rabbitmq.com/networking.html
209           to learn more.
210
211           Example:
212                 rabbitmq-diagnostics check_port_listener 5672
213
214   check_protocol_listener protocol
215
216           Health check that fails (returns with a non-zero code) if the tar‐
217           get node does not have a listener for the specified protocol.
218
219           See RabbitMQ Networking guide: https://rabbitmq.com/networking.html
220           to learn more.
221
222           Example:
223                 rabbitmq-diagnostics check_protocol_listener mqtt
224
225   check_running
226
227           Health check that fails (returns with a non-zero code) if the Rab‐
228           bitMQ application is not running on the target node.
229
230           If rabbitmqctl(8) was used to stop the application, this check will
231           fail.
232
233           Example:
234                 rabbitmq-diagnostics check_running
235
236   check_virtual_hosts
237
238           Health check that checks if all vhosts are running in the target
239           node
240
241           Example:
242                 rabbitmq-diagnostics check_virtual_hosts --timeout 60
243
244   cipher_suites
245
246           Lists cipher suites enabled by default. To list all available ci‐
247           pher suites, add the --all argument.
248
249           Example:
250                 rabbitmq-diagnostics cipher_suites --format openssl --all
251
252   command_line_arguments
253
254           Displays target node's command-line arguments and flags as reported
255           by the runtime.
256
257           Example:
258                 rabbitmq-diagnostics command_line_arguments -n
259                 rabbit@hostname
260
261   consume_event_stream [--duration seconds | -d seconds] [--pattern pattern]
262           [--timeout milliseconds]
263
264           Streams internal events from a running node. Output is jq-compati‐
265           ble.
266
267           Example:
268                 rabbitmq-diagnostics consume_event_stream -n rabbit@hostname
269                 --duration 20 --pattern queue_.*
270
271   discover_peers
272
273           Runs a peer discovery on the target node and prints the discovered
274           nodes, if any.
275
276           See RabbitMQ Cluster Formation guide: https://rabbitmq.com/cluster-
277           formation.html to learn more.
278
279           Example:
280                 rabbitmq-diagnostics discover_peers --timeout 60
281
282   environment
283           See environment in rabbitmqctl(8)
284
285   erlang_cookie_hash
286
287           Outputs a hashed value of the shared secret used by the target node
288           to authenticate CLI tools and peers. The value can be compared with
289           the hash found in error messages of CLI tools.
290
291           See RabbitMQ Clustering guide:
292           https://rabbitmq.com/clustering.html#erlang-cookie to learn more.
293
294           Example:
295                 rabbitmq-diagnostics erlang_cookie_hash -q
296
297   erlang_version
298
299           Reports target node's Erlang/OTP version.
300
301           Example:
302                 rabbitmq-diagnostics erlang_version -q
303
304   is_booting
305
306           Reports if RabbitMQ application is currently booting (not
307           booted/running or stopped) on the target node.
308
309           Example:
310                 rabbitmq-diagnostics is_booting
311
312   is_running
313
314           Reports if RabbitMQ application is fully booted and running (that
315           is, not stopped) on the target node.
316
317           Example:
318                 rabbitmq-diagnostics is_running
319
320   list_bindings [-p vhost] [bindinginfoitem ...]
321
322           See list_bindings in rabbitmqctl(8)
323
324   list_channels [channelinfoitem ...]
325
326           See list_channels in rabbitmqctl(8)
327
328   list_ciphers
329
330           See list_ciphers in rabbitmqctl(8)
331
332   list_connections [connectioninfoitem ...]
333
334           See list_connections in rabbitmqctl(8)
335
336   list_consumers [-p vhost]
337
338           See list_consumers in rabbitmqctl(8)
339
340   list_exchanges [-p vhost] [exchangeinfoitem ...]
341
342           See list_exchanges in rabbitmqctl(8)
343
344   list_hashes
345
346           See list_hashes in rabbitmqctl(8)
347
348   list_queues [-p vhost] [--offline | --online | --local] [queueinfoitem ...]
349
350           See list_queues in rabbitmqctl(8)
351           ] [--local] [--queue-timeout milliseconds] [column ...]
352           [--no-table-headers]
353
354   list_unresponsive_queues
355
356           See list_unresponsive_queues in rabbitmqctl(8)
357
358   listeners
359
360           Lists listeners (bound sockets) on this node. Use this to inspect
361           what protocols and ports the node is listening on for client, CLI
362           tool and peer connections.
363
364           See RabbitMQ Networking guide: https://rabbitmq.com/networking.html
365           to learn more.
366
367           Example:
368                 rabbitmq-diagnostics listeners
Impressum