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:
15           https://www.rabbitmq.com/documentation.html
16     to learn more about RabbitMQ diagnostics, monitoring and health checks.
17
18     rabbitmq-diagnostics allows the operator to inspect node and cluster
19     state. A number of health checks are available to be used interactively
20     and by monitoring tools.
21
22
23     By default if it is not possible to connect to and authenticate with the
24     target node (for example if it is stopped), the operation will fail.  To
25     learn more, see the RabbitMQ Monitoring guide:
26           https://www.rabbitmq.com/monitoring.html
27

OPTIONS

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

COMMANDS

64     Most commands provided by rabbitmq-diagnostics inspect node and cluster
65     state or perform health checks.
66
67     Commands that list topology entities (e.g. queues) use tab as column
68     delimiter.  These commands and their arguments are delegated to rabbit‐
69     mqctl(8).
70
71     Some commands ( list_queues, list_exchanges, list_bindings and
72     list_consumers) accept an optional vhost parameter.
73
74     The list_queues, list_exchanges and list_bindings commands accept an
75     optional virtual host parameter for which to display results.  The
76     default value is "/".
77
78     help
79
80             Displays general help and commands supported by
81             rabbitmq-diagnostics.
82
83     ping
84
85             Most basic health check. Succeeds if target node (runtime) is
86             running and rabbitmq-diagnostics can authenticate with it suc‐
87             cessfully.
88
89     memory_breakdown [--unit memory_unit]
90
91             Displays node's memory usage by category.  Supported memory units
92             are:
93
94             ·   bytes
95
96             ·   megabytes
97
98             ·   gigabytes
99
100             ·   terabytes
101
102             See RabbitMQ Memory Use guide:
103                   https://www.rabbitmq.com/memory-use.html
104             to learn more.
105
106             Example:
107
108                   rabbitmq-diagnostics memory_breakdown --unit gigabytes
109
110     server_version
111
112             Reports target node's version.
113
114             Example:
115                   rabbitmq-diagnostics server_version -q
116
117     erlang_version
118
119             Reports target node's Erlang/OTP version.
120
121             Example:
122                   rabbitmq-diagnostics erlang_version -q
123
124     maybe_stuck
125
126             Periodically samples stack traces of all Erlang processes
127             ("lightweight threads") on the node. Reports the processes for
128             which stack trace samples are identical.
129
130             Identical samples may indicate that the process is not making any
131             progress but is not necessarily an indication of a problem.
132
133             Example:
134                   rabbitmq-diagnostics maybe_stuck -q
135
136     runtime_thread_stats [--sample-interval interval]
137
138             Performs sampling of runtime (kernel) threads' activity for
139             interval seconds and reports it.
140
141             For this command to work, Erlang/OTP on the target node must be
142             compiled with microstate accounting support and have the run‐
143             time_tools package available.
144
145             Example:
146                   rabbitmq-diagnostics runtime_thread_stats --sample-interval
147                   15
148
149     tls_versions
150
151             Lists all TLS versions supported by the runtime on the target
152             node.  Note that RabbitMQ can be configured to only accept a sub‐
153             set of those versions, for example, SSLv3 is disabled by default.
154
155             See RabbitMQ TLS guide:
156                   https://www.rabbitmq.com/ssl.html
157             to learn more.
158
159             Example:
160                   rabbitmq-diagnostics tls_versions -q
161
162     erlang_cookie_hash
163
164             Outputs a hashed value of the shared secret used by the target
165             node to authenticate CLI tools and peers. The value can be com‐
166             pared with the hash found in error messages of CLI tools.
167
168             See RabbitMQ Clustering guide:
169                   https://www.rabbitmq.com/clustering.html#erlang-cookie
170             to learn more.
171
172             Example:
173                   rabbitmq-diagnostics erlang_cookie_hash -q
174
175     discover_peers
176
177             Runs a peer discovery on the target node and prints the discov‐
178             ered nodes, if any.
179
180             See RabbitMQ Cluster Formation guide:
181                   https://www.rabbitmq.com/cluster-formation.html
182             to learn more.
183
184             Example:
185                   rabbitmq-diagnostics discover_peers --timeout 60
186
187     list_channels [channelinfoitem ...]
188             See list_channels in rabbitmqctl(8)
189
190     list_queues [-p vhost] [--offline | --online | --local] [queueinfoitem
191             ...]
192             See list_queues in rabbitmqctl(8)
193
194     list_exchanges [-p vhost] [exchangeinfoitem ...]
195             See list_exchanges in rabbitmqctl(8)
196
197     list_bindings [-p vhost] [bindinginfoitem ...]
198             See list_bindings in rabbitmqctl(8)
199
200     list_connections [connectioninfoitem ...]
201             See list_connections in rabbitmqctl(8)
202
203     list_channels [channelinfoitem ...]
204             See list_channels in rabbitmqctl(8)
205
206     list_consumers [-p vhost]
207             See list_consumers in rabbitmqctl(8)
208
209     alarms
210
211             Lists resource alarms, if any, in the cluster.
212
213             See RabbitMQ Resource Alarms guide:
214                   https://www.rabbitmq.com/alarms.html
215             to learn more.
216
217             Example:
218                   rabbitmq-diagnostics alarms
219
220     listeners
221
222             Lists listeners (bound sockets) on this node. Use this to inspect
223             what protocols and ports the node is listening on for client, CLI
224             tool and peer connections.
225
226             See RabbitMQ Networking guide:
227                   https://www.rabbitmq.com/networking.html
228             to learn more.
229
230             Example:
231                   rabbitmq-diagnostics listeners
232
233     is_running
234
235             Reports if RabbitMQ application is fully booted and running (that
236             is, not stopped) on the target node.
237
238             Example:
239                   rabbitmq-diagnostics is_running
240
241     is_booting
242
243             Reports if RabbitMQ application is currently booting (not
244             booted/running or stopped) on the target node.
245
246             Example:
247                   rabbitmq-diagnostics is_booting
248
249             check_port_connectivity [-t <timeout>]
250
251     check_running
252
253             Health check that fails (returns with a non-zero code) if the
254             RabbitMQ application is not running on the target node.
255
256             If rabbitmqctl(8) was used to stop the application, this check
257             will fail.
258
259             Example:
260                   rabbitmq-diagnostics check_running
261
262     check_local_alarms
263
264             Health check that fails (returns with a non-zero code) if there
265             are alarms in effect on the target node.
266
267             See RabbitMQ Resource Alarms guide:
268                   https://www.rabbitmq.com/alarms.html
269             to learn more.
270
271             Example:
272                   rabbitmq-diagnostics check_local_alarms
273
274     check_alarms
275
276             Health check that fails (returns with a non-zero code) if there
277             are alarms in effect on any of the cluster nodes.
278
279             See RabbitMQ Resource Alarms guide:
280                   https://www.rabbitmq.com/alarms.html
281             to learn more.
282
283             Example:
284                   rabbitmq-diagnostics check_alarms
285
286     check_port_connectivity
287
288             Health check that fails (returns with a non-zero code) if any
289             listener ports on the target node cannot accept a new TCP connec‐
290             tion opened by The check only validates if a new TCP connection
291             is accepted. It does not perform messaging protocol handshake or
292             authenticate.
293
294             See RabbitMQ Networking guide:
295                   https://www.rabbitmq.com/networking.html
296             to learn more.
297
298             Example:
299                   rabbitmq-diagnostics check_port_connectivity
300
301     check_protocol_listener
302
303             Health check that fails (returns with a non-zero code) if the
304             target node does not have a listener for the specified protocol.
305
306             See RabbitMQ Networking guide:
307                   https://www.rabbitmq.com/networking.html
308             to learn more.
309
310             Example:
311                   rabbitmq-diagnostics check_protocol_listener mqtt
312
313     check_port_listener
314
315             Health check that fails (returns with a non-zero code) if the
316             target node is not listening on the specified port (there is no
317             listener that uses that port).
318
319             See RabbitMQ Networking guide:
320                   https://www.rabbitmq.com/networking.html
321             to learn more.
322
323             Example:
324                   rabbitmq-diagnostics check_port_listener 5672
325
326     status  See status in rabbitmqctl(8)
327
328     cluster_status
329             See cluster_status in rabbitmqctl(8)
330
331     environment
332             See environment in rabbitmqctl(8)
333
334     report  See report in rabbitmqctl(8)
335
336     list_global_parameters
337             See list_global_parameters in rabbitmqctl(8)
338
339     list_operator_policies [-p vhost]
340             See list_operator_policies in rabbitmqctl(8)
341
342     list_parameters [-p vhost]
343             See list_parameters in rabbitmqctl(8)
344
345     list_permissions [-p vhost]
346             See list_permissions in rabbitmqctl(8)
347
348     list_policies [-p vhost]
349             See list_policies in rabbitmqctl(8)
350
351     list_topic_permissions [-p vhost]
352             See list_topic_permissions in rabbitmqctl(8)
353
354     list_user_permissions username
355             See list_user_permissions in rabbitmqctl(8)
356
357     list_user_topic_permissions username
358             See list_user_topic_permissions in rabbitmqctl(8)
359
360     list_users
361             See list_users in rabbitmqctl(8)
362
363     list_vhosts [vhostinfoitem ...]
364             See list_vhosts in rabbitmqctl(8)
365
366     node_health_check
367             Performs several health checks of the target node.
368
369             Verifies the rabbit application is running and alarms are not
370             set, then checks that every queue and channel on the node can
371             emit basic stats.
372
373             Example:
374                   rabbitmq-diagnostics node_health_check -n rabbit@hostname
375
376RabbitMQ Server                January 29, 2019                RabbitMQ Server
Impressum