1RABBITMQCTL(8)            BSD System Manager's Manual           RABBITMQCTL(8)
2

NAME

4     rabbitmqctl — tool for managing RabbitMQ nodes
5

SYNOPSIS

7     rabbitmqctl [-q] [-s] [-l] [-n node] [-t timeout] command
8                 [command_options]
9

DESCRIPTION

11     RabbitMQ is an open source multi-protocol messaging broker.
12
13     rabbitmqctl is the main command line tool for managing a RabbitMQ server
14     node, together with rabbitmq-diagnostics , rabbitmq-upgrade , and others.
15
16     It performs all actions by connecting to the target RabbitMQ node on a
17     dedicated CLI tool communication port and authenticating using a shared
18     secret (known as the cookie file).
19
20     Diagnostic information is displayed if connection failed, the target node
21     was not running, or rabbitmqctl could not authenticate to the target node
22     successfully.  To learn more, see the RabbitMQ CLI Tools guide:
23     https://www.rabbitmq.com/cli.html and RabbitMQ Networking guide:
24     https://www.rabbitmq.com/networking.html
25

OPTIONS

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

COMMANDS

67     help [-l] [command_name]
68
69             Prints usage for all available commands.
70
71             -l, --list-commands
72                     List command usages only, without parameter explanation.
73
74             command_name
75                     Prints usage for the specified command.
76
77     version
78
79             Displays CLI tools version
80
81   Nodes
82     await_startup
83
84             Waits for the RabbitMQ application to start on the target node
85
86             For example, to wait for the RabbitMQ application to start:
87
88                   rabbitmqctl await_startup
89
90     reset
91
92             Returns a RabbitMQ node to its virgin state.
93
94             Removes the node from any cluster it belongs to, removes all data
95             from the management database, such as configured users and
96             vhosts, and deletes all persistent messages.
97
98             For reset and force_reset to succeed the RabbitMQ application
99             must have been stopped, e.g. with stop_app.
100
101             For example, to reset the RabbitMQ node:
102
103                   rabbitmqctl reset
104
105     rotate_logs
106
107             Instructs the RabbitMQ node to perform internal log rotation.
108
109             Log rotation is performed according to the logging settings spec‐
110             ified in the configuration file.  The rotation operation is asyn‐
111             chronous, there is no guarantee that it has completed when this
112             command returns.
113
114             Note that there is no need to call this command in case of exter‐
115             nal log rotation (e.g. from logrotate(8)).
116
117             For example, to initial log rotation:
118
119                   rabbitmqctl rotate_logs
120
121     shutdown
122
123             Shuts down the node, both RabbitMQ and its runtime.  The command
124             is blocking and will return after the runtime process exits.  If
125             RabbitMQ fails to stop, it will return a non-zero exit code.
126             This command infers the OS PID of the target node and therefore
127             can only be used to shut down nodes running on the same host (or
128             broadly speaking, in the same operating system, e.g. in the same
129             VM or container)
130
131             Unlike the stop command, the shutdown command:
132
133             does not require a pid_file to wait for the runtime process
134                 to exit
135
136             returns a non-zero exit code if RabbitMQ node is not running
137
138             For example, this will shut down a locally running RabbitMQ node
139             with default node name:
140
141                   rabbitmqctl shutdown
142
143     start_app
144
145             Starts the RabbitMQ application.
146
147             This command is typically run after performing other management
148             actions that required the RabbitMQ application to be stopped,
149             e.g. reset.
150
151             For example, to instruct the RabbitMQ node to start the RabbitMQ
152             application:
153
154                   rabbitmqctl start_app
155
156     stop [pid_file]
157
158             Stops the Erlang node on which RabbitMQ is running.  To restart
159             the node follow the instructions for "Running the Server" in the
160             installation guide: https://rabbitmq.com/download.html
161
162             If a pid_file is specified, also waits for the process specified
163             there to terminate.  See the description of the wait command for
164             details on this file.
165
166             For example, to instruct the RabbitMQ node to terminate:
167
168                   rabbitmqctl stop
169
170     stop_app
171
172             Stops the RabbitMQ application, leaving the runtime (Erlang VM)
173             running.
174
175             This command is typically run prior to performing other manage‐
176             ment actions that require the RabbitMQ application to be stopped,
177             e.g. reset.
178
179             For example, to instruct the RabbitMQ node to stop the RabbitMQ
180             application:
181
182                   rabbitmqctl stop_app
183
184     wait pid_file, wait --pid pid
185
186             Waits for the RabbitMQ application to start.
187
188             This command will wait for the RabbitMQ application to start at
189             the node.  It will wait for the pid file to be created if pidfile
190             is specified, then for a process with a pid specified in the pid
191             file or the --pid argument, and then for the RabbitMQ application
192             to start in that process.  It will fail if the process terminates
193             without starting the RabbitMQ application.
194
195             If the specified pidfile is not created or erlang node is not
196             started within --timeout the command will fail.  Default timeout
197             is 10 seconds.
198
199             A suitable pid file is created by the rabbitmq-server(8) script.
200             By default this is located in the Mnesia directory.  Modify the
201             RABBITMQ_PID_FILE environment variable to change the location.
202
203             For example, this command will return when the RabbitMQ node has
204             started up:
205
206                   rabbitmqctl wait /var/run/rabbitmq/pid
207
208   Cluster management
209     await_online_nodes count
210
211             Waits for count nodes to join the cluster
212
213             For example, to wait for two RabbitMQ nodes to start:
214
215                   rabbitmqctl await_online_nodes 2
216
217     change_cluster_node_type type
218
219             Changes the type of the cluster node.
220
221             The type must be one of the following:
222             •   disc
223             •   ram
224
225             The node must be stopped for this operation to succeed, and when
226             turning a node into a RAM node the node must not be the only disc
227             node in the cluster.
228
229             For example, this command will turn a RAM node into a disc node:
230
231                   rabbitmqctl change_cluster_node_type disc
232
233     cluster_status
234
235             Displays all the nodes in the cluster grouped by node type, to‐
236             gether with the currently running nodes.
237
238             For example, this command displays the nodes in the cluster:
239
240                   rabbitmqctl cluster_status
241
242     force_boot
243
244             Ensures that the node will start next time, even if it was not
245             the last to shut down.
246
247             Normally when you shut down a RabbitMQ cluster altogether, the
248             first node you restart should be the last one to go down, since
249             it may have seen things happen that other nodes did not.  But
250             sometimes that's not possible: for instance if the entire cluster
251             loses power then all nodes may think they were not the last to
252             shut down.
253
254             In such a case you can invoke force_boot while the node is down.
255             This will tell the node to unconditionally start next time you
256             ask it to.  If any changes happened to the cluster after this
257             node shut down, they will be lost.
258
259             If the last node to go down is permanently lost then you should
260             use forget_cluster_node --offline in preference to this command,
261             as it will ensure that mirrored queues which had their leader
262             replica on the lost node get promoted.
263
264             For example, this will force the node not to wait for other nodes
265             next time it is started:
266
267                   rabbitmqctl force_boot
268
269     force_reset
270
271             Forcefully returns a RabbitMQ node to its virgin state.
272
273             The force_reset command differs from reset in that it resets the
274             node unconditionally, regardless of the current management data‐
275             base state and cluster configuration.  It should only be used as
276             a last resort if the database or cluster configuration has been
277             corrupted.
278
279             For reset and force_reset to succeed the RabbitMQ application
280             must have been stopped, e.g. with stop_app.
281
282             For example, to reset the RabbitMQ node:
283
284                   rabbitmqctl force_reset
285
286     forget_cluster_node [--offline]
287
288             --offline
289                     Enables node removal from an offline node.  This is only
290                     useful in the situation where all the nodes are offline
291                     and the last node to go down cannot be brought online,
292                     thus preventing the whole cluster from starting.  It
293                     should not be used in any other circumstances since it
294                     can lead to inconsistencies.
295
296             Removes a cluster node remotely.  The node that is being removed
297             must be offline, while the node we are removing from must be on‐
298             line, except when using the --offline flag.
299
300             When using the --offline flag , rabbitmqctl will not attempt to
301             connect to a node as normal; instead it will temporarily become
302             the node in order to make the change.  This is useful if the node
303             cannot be started normally.  In this case the node will become
304             the canonical source for cluster metadata (e.g. which queues ex‐
305             ist), even if it was not before.  Therefore you should use this
306             command on the latest node to shut down if at all possible.
307
308             For example, this command will remove the node "rabbit@stringer"
309             from the node "hare@mcnulty":
310
311                   rabbitmqctl -n hare@mcnulty forget_cluster_node
312                   rabbit@stringer
313
314     join_cluster seed-node [--ram]
315
316             seed-node
317                     Existing cluster member (seed node) to cluster with.
318
319             --ram   If provided, the node will join the cluster as a RAM
320                     node.  RAM node use is discouraged. Use only if you un‐
321                     derstand why exactly you need to use them.
322
323             Instructs the node to become a member of the cluster that the
324             specified node is in.  Before clustering, the node is reset, so
325             be careful when using this command.  For this command to succeed
326             the RabbitMQ application must have been stopped, e.g. with
327             stop_app.
328
329             Cluster nodes can be of two types: disc or RAM.  Disc nodes
330             replicate data in RAM and on disc, thus providing redundancy in
331             the event of node failure and recovery from global events such as
332             power failure across all nodes.  RAM nodes replicate data in RAM
333             only (with the exception of queue contents, which can reside on
334             disc if the queue is persistent or too big to fit in memory) and
335             are mainly used for scalability.  RAM nodes are more performant
336             only when managing resources (e.g. adding/removing queues, ex‐
337             changes, or bindings).  A cluster must always have at least one
338             disc node, and usually should have more than one.
339
340             The node will be a disc node by default.  If you wish to create a
341             RAM node, provide the --ram flag.
342
343             After executing the join_cluster command, whenever the RabbitMQ
344             application is started on the current node it will attempt to
345             connect to the nodes that were in the cluster when the node went
346             down.
347
348             To leave a cluster, reset the node.  You can also remove nodes
349             remotely with the forget_cluster_node command.
350
351             For example, this command instructs the RabbitMQ node to join the
352             cluster that "hare@elena" is part of, as a ram node:
353
354                   rabbitmqctl join_cluster hare@elena --ram
355
356             To learn more, see the RabbitMQ Clustering guide:
357             https://www.rabbitmq.com/clustering.html
358
359     rename_cluster_node oldnode1 newnode1 [oldnode2 newnode2 ...]
360
361             Supports renaming of cluster nodes in the local database.
362
363             This subcommand causes rabbitmqctl to temporarily become the node
364             in order to make the change.  The local cluster node must there‐
365             fore be completely stopped; other nodes can be online or offline.
366
367             This subcommand takes an even number of arguments, in pairs rep‐
368             resenting the old and new names for nodes.  You must specify the
369             old and new names for this node and for any other nodes that are
370             stopped and being renamed at the same time.
371
372             It is possible to stop all nodes and rename them all simultane‐
373             ously (in which case old and new names for all nodes must be
374             given to every node) or stop and rename nodes one at a time (in
375             which case each node only needs to be told how its own name is
376             changing).
377
378             For example, this command will rename the node
379             "rabbit@misshelpful" to the node "rabbit@cordelia"
380
381                   rabbitmqctl rename_cluster_node rabbit@misshelpful
382                   rabbit@cordelia
383
384             Note that this command only changes the local database.  It may
385             also be necessary to rename the local database directories, and
386             to configure the new node name.  For example:
387
388             1.   Stop the node:
389
390                        rabbitmqctl stop rabbit@misshelpful
391
392             2.   Rename the node in the local database:
393
394                        rabbitmqctl rename_cluster_node rabbit@misshelpful
395                        rabbit@cordelia
396
397             3.   Rename the local database directories (note, you do not need
398                  to do this if you have set the RABBITMQ_MNESIA_DIR environ‐
399                  ment variable):
400
401                        mv \
402                          /var/lib/rabbitmq/mnesia/rabbit\@misshelpful \
403                          /var/lib/rabbitmq/mnesia/rabbit\@cordelia
404                        mv \
405                          /var/lib/rabbitmq/mnesia/rabbit\@misshelpful-rename \
406                          /var/lib/rabbitmq/mnesia/rabbit\@cordelia-rename
407                        mv \
408                          /var/lib/rabbitmq/mnesia/rabbit\@misshelpful-plugins-expand \
409                          /var/lib/rabbitmq/mnesia/rabbit\@cordelia-plugins-expand
410
411             4.   If node name is configured e.g. using
412                  /etc/rabbitmq/rabbitmq-env.conf it has also be updated
413                  there.
414
415             5.   Start the node when ready
416
417     update_cluster_nodes clusternode
418
419             clusternode
420                     The node to consult for up-to-date information.
421
422             Instructs an already clustered node to contact clusternode to
423             cluster when booting up.  This is different from join_cluster
424             since it does not join any cluster - it checks that the node is
425             already in a cluster with clusternode.
426
427             The need for this command is motivated by the fact that clusters
428             can change while a node is offline.  Consider a situation where
429             node rabbit@A and rabbit@B are clustered.  rabbit@A goes down,
430             rabbit@C clusters with rabbit@B, and then rabbit@B leaves the
431             cluster.  When rabbit@A starts back up, it'll try to contact
432             rabbit@B, but this will fail since rabbit@B is not in the cluster
433             anymore.  The following command will rename node rabbit@B to
434             rabbit@C on node rabbitA
435
436                   update_cluster_nodes -n rabbit@A rabbit@B rabbit@C
437
438             To learn more, see the RabbitMQ Clustering guide:
439             https://www.rabbitmq.com/clustering.html
440
441   Replication
442     sync_queue [-p vhost] queue
443
444             queue   The name of the queue to synchronise.
445
446             Instructs a mirrored queue with unsynchronised mirrors (follower
447             replicas) to synchronise them.  The queue will block while syn‐
448             chronisation takes place (all publishers to and consumers using
449             the queue will block or temporarily see no activity).  This com‐
450             mand can only be used with mirrored queues.  To learn more, see
451             the RabbitMQ Mirroring guide: https://www.rabbitmq.com/ha.html
452
453             Note that queues with unsynchronised replicas and active con‐
454             sumers will become synchronised eventually (assuming that con‐
455             sumers make progress).  This command is primarily useful for
456             queues which do not have active consumers.
457
458     cancel_sync_queue [-p vhost] queue
459
460             queue   The name of the queue to cancel synchronisation for.
461
462             Instructs a synchronising mirrored queue to stop synchronising
463             itself.
464
465   User Management
466     Note that all user management commands rabbitmqctl only can manage users
467     in the internal RabbitMQ database.  Users from any alternative authenti‐
468     cation backends such as LDAP cannot be inspected or managed with those
469     commands.  rabbitmqctl.
470
471     add_user username password
472
473             username
474                     The name of the user to create.
475
476             password
477                     The password the created user will use to log in to the
478                     broker.
479
480             For example, this command instructs the RabbitMQ broker to create
481             a (non-administrative) user named "janeway" with (initial) pass‐
482             word "changeit":
483
484                   rabbitmqctl add_user janeway changeit
485
486     authenticate_user username password
487
488             username
489                     The name of the user.
490
491             password
492                     The password of the user.
493
494             For example, this command instructs the RabbitMQ broker to au‐
495             thenticate the user named "janeway" with password "verifyit":
496
497                   rabbitmqctl authenticate_user janeway verifyit
498
499     change_password username newpassword
500
501             username
502                     The name of the user whose password is to be changed.
503
504             newpassword
505                     The new password for the user.
506
507             For example, this command instructs the RabbitMQ broker to change
508             the password for the user named "janeway" to "newpass":
509
510                   rabbitmqctl change_password janeway newpass
511
512     clear_password username
513
514             username
515                     The name of the user whose password is to be cleared.
516
517             For example, this command instructs the RabbitMQ broker to clear
518             the password for the user named "janeway":
519
520                   rabbitmqctl clear_password janeway
521
522             This user now cannot log in with a password (but may be able to
523             through e.g. SASL EXTERNAL if configured).
524
525     delete_user username
526
527             username
528                     The name of the user to delete.
529
530             For example, this command instructs the RabbitMQ broker to delete
531             the user named "janeway":
532
533                   rabbitmqctl delete_user janeway
534
535     list_users
536
537             Lists users.  Each result row will contain the user name followed
538             by a list of the tags set for that user.
539
540             For example, this command instructs the RabbitMQ broker to list
541             all users:
542
543                   rabbitmqctl list_users
544
545     set_user_tags username [tag ...]
546
547             username
548                     The name of the user whose tags are to be set.
549
550             tag     Zero, one or more tags to set.  Any existing tags will be
551                     removed.
552
553             For example, this command instructs the RabbitMQ broker to ensure
554             the user named "janeway" is an administrator:
555
556                   rabbitmqctl set_user_tags janeway administrator
557
558             This has no effect when the user authenticates using a messaging
559             protocol, but can be used to permit the user to manage users,
560             virtual hosts and permissions when the user logs in via some
561             other means (for example with the management plugin).
562
563             This command instructs the RabbitMQ broker to remove any tags
564             from the user named "janeway":
565
566                   rabbitmqctl set_user_tags janeway
567
568   Access control
569     clear_permissions [-p vhost] username
570
571             vhost   The name of the virtual host to which to deny the user
572                     access, defaulting to "/".
573
574             username
575                     The name of the user to deny access to the specified vir‐
576                     tual host.
577
578             Sets user permissions.
579
580             For example, this command instructs the RabbitMQ broker to deny
581             the user named "janeway" access to the virtual host called
582             "my-vhost":
583
584                   rabbitmqctl clear_permissions -p my-vhost janeway
585
586     clear_topic_permissions [-p vhost] username [exchange]
587
588             vhost   The name of the virtual host to which to clear the topic
589                     permissions, defaulting to "/".
590
591             username
592                     The name of the user to clear topic permissions to the
593                     specified virtual host.
594
595             exchange
596                     The name of the topic exchange to clear topic permis‐
597                     sions, defaulting to all the topic exchanges the given
598                     user has topic permissions for.
599
600             Clear user topic permissions.
601
602             For example, this command instructs the RabbitMQ broker to remove
603             topic permissions for user named "janeway" for the topic exchange
604             "amq.topic" in the virtual host called "my-vhost":
605
606                   rabbitmqctl clear_topic_permissions -p my-vhost janeway
607                   amq.topic
608
609     list_permissions [-p vhost]
610
611             vhost   The name of the virtual host for which to list the users
612                     that have been granted access to it, and their permis‐
613                     sions.  Defaults to "/".
614
615             Lists permissions in a virtual host.
616
617             For example, this command instructs the RabbitMQ broker to list
618             all the users which have been granted access to the virtual host
619             called "my-vhost", and the permissions they have for operations
620             on resources in that virtual host.  Note that an empty string
621             means no permissions granted:
622
623                   rabbitmqctl list_permissions -p my-vhost
624
625     list_topic_permissions [-p vhost]
626
627             vhost   The name of the virtual host for which to list the users
628                     topic permissions.  Defaults to "/".
629
630             Lists topic permissions in a virtual host.
631
632             For example, this command instructs the RabbitMQ broker to list
633             all the users which have been granted topic permissions in the
634             virtual host called "my-vhost:"
635
636                   rabbitmqctl list_topic_permissions -p my-vhost
637
638     list_user_permissions username
639
640             username
641                     The name of the user for which to list the permissions.
642
643             Lists user permissions.
644
645             For example, this command instructs the RabbitMQ broker to list
646             all the virtual hosts to which the user named "janeway" has been
647             granted access, and the permissions the user has for operations
648             on resources in these virtual hosts:
649
650                   rabbitmqctl list_user_permissions janeway
651
652     list_user_topic_permissions username
653
654             username
655                     The name of the user for which to list the topic permis‐
656                     sions.
657
658             Lists user topic permissions.
659
660             For example, this command instructs the RabbitMQ broker to list
661             all the virtual hosts to which the user named "janeway" has been
662             granted access, and the topic permissions the user has in these
663             virtual hosts:
664
665                   rabbitmqctl list_user_topic_permissions janeway
666
667     list_vhosts [vhostinfoitem ...]
668
669             Lists virtual hosts.
670
671             The vhostinfoitem parameter is used to indicate which virtual
672             host information items to include in the results.  The column or‐
673             der in the results will match the order of the parameters.
674             vhostinfoitem can take any value from the list that follows:
675
676             name    The name of the virtual host with non-ASCII characters
677                     escaped as in C.
678
679             tracing
680                     Whether tracing is enabled for this virtual host.
681
682             If no vhostinfoitem are specified then the vhost name is dis‐
683             played.
684
685             For example, this command instructs the RabbitMQ broker to list
686             all virtual hosts:
687
688                   rabbitmqctl list_vhosts name tracing
689
690     set_permissions [-p vhost] user conf write read
691
692             vhost   The name of the virtual host to which to grant the user
693                     access, defaulting to "/".
694
695             user    The name of the user to grant access to the specified
696                     virtual host.
697
698             conf    A regular expression matching resource names for which
699                     the user is granted configure permissions.
700
701             write   A regular expression matching resource names for which
702                     the user is granted write permissions.
703
704             read    A regular expression matching resource names for which
705                     the user is granted read permissions.
706
707             Sets user permissions.
708
709             For example, this command instructs the RabbitMQ broker to grant
710             the user named "janeway" access to the virtual host called
711             "my-vhost", with configure permissions on all resources whose
712             names starts with "janeway-", and write and read permissions on
713             all resources:
714
715                   rabbitmqctl set_permissions -p my-vhost janeway
716                   "^janeway-.*" ".*" ".*"
717
718     set_topic_permissions [-p vhost] user exchange write read
719
720             vhost   The name of the virtual host to which to grant the user
721                     access, defaulting to "/".
722
723             user    The name of the user the permissions apply to in the tar‐
724                     get virtual host.
725
726             exchange
727                     The name of the topic exchange the authorisation check
728                     will be applied to.
729
730             write   A regular expression matching the routing key of the pub‐
731                     lished message.
732
733             read    A regular expression matching the routing key of the con‐
734                     sumed message.
735
736             Sets user topic permissions.
737
738             For example, this command instructs the RabbitMQ broker to let
739             the user named "janeway" publish and consume messages going
740             through the "amp.topic" exchange of the "my-vhost" virtual host
741             with a routing key starting with "janeway-":
742
743                   rabbitmqctl set_topic_permissions -p my-vhost janeway
744                   amq.topic "^janeway-.*" "^janeway-.*"
745
746             Topic permissions support variable expansion for the following
747             variables: username, vhost, and client_id. Note that client_id is
748             expanded only when using MQTT.  The previous example could be
749             made more generic by using "^{username}-.*":
750
751                   rabbitmqctl set_topic_permissions -p my-vhost janeway
752                   amq.topic "^{username}-.*" "^{username}-.*"
753
754   Monitoring, observability and health checks
755     environment
756
757             Displays the name and value of each variable in the application
758             environment for each running application.
759
760     list_bindings [-p vhost] [bindinginfoitem ...]
761
762             Returns binding details.  By default the bindings for the "/"
763             virtual host are returned.  The -p flag can be used to override
764             this default.
765
766             The bindinginfoitem parameter is used to indicate which binding
767             information items to include in the results.  The column order in
768             the results will match the order of the parameters.
769             bindinginfoitem can take any value from the list that follows:
770
771             source_name
772                     The name of the source of messages to which the binding
773                     is attached.  With non-ASCII characters escaped as in C.
774
775             source_kind
776                     The kind of the source of messages to which the binding
777                     is attached.  Currently always exchange.  With non-ASCII
778                     characters escaped as in C.
779
780             destination_name
781                     The name of the destination of messages to which the
782                     binding is attached.  With non-ASCII characters escaped
783                     as in C.
784
785             destination_kind
786                     The kind of the destination of messages to which the
787                     binding is attached.  With non-ASCII characters escaped
788                     as in C.
789
790             routing_key
791                     The binding's routing key, with non-ASCII characters es‐
792                     caped as in C.
793
794             arguments
795                     The binding's arguments.
796
797             If no bindinginfoitem are specified then all above items are dis‐
798             played.
799
800             For example, this command displays the exchange name and queue
801             name of the bindings in the virtual host named "my-vhost"
802
803                   rabbitmqctl list_bindings -p my-vhost exchange_name
804                   queue_name
805
806     list_channels [channelinfoitem ...]
807
808             Returns information on all current channels, the logical contain‐
809             ers executing most AMQP commands.  This includes channels that
810             are part of ordinary AMQP connections, and channels created by
811             various plug-ins and other extensions.
812
813             The channelinfoitem parameter is used to indicate which channel
814             information items to include in the results.  The column order in
815             the results will match the order of the parameters.
816             channelinfoitem can take any value from the list that follows:
817
818             pid     Id of the Erlang process associated with the connection.
819
820             connection
821                     Id of the Erlang process associated with the connection
822                     to which the channel belongs.
823
824             name    Readable name for the channel.
825
826             number  The number of the channel, which uniquely identifies it
827                     within a connection.
828
829             user    Username associated with the channel.
830
831             vhost   Virtual host in which the channel operates.
832
833             transactional
834                     True if the channel is in transactional mode, false oth‐
835                     erwise.
836
837             confirm
838                     True if the channel is in confirm mode, false otherwise.
839
840             consumer_count
841                     Number of logical AMQP consumers retrieving messages via
842                     the channel.
843
844             messages_unacknowledged
845                     Number of messages delivered via this channel but not yet
846                     acknowledged.
847
848             messages_uncommitted
849                     Number of messages received in an as yet uncommitted
850                     transaction.
851
852             acks_uncommitted
853                     Number of acknowledgements received in an as yet uncom‐
854                     mitted transaction.
855
856             messages_unconfirmed
857                     Number of published messages not yet confirmed.  On chan‐
858                     nels not in confirm mode, this remains 0.
859
860             prefetch_count
861                     QoS prefetch limit for new consumers, 0 if unlimited.
862
863             global_prefetch_count
864                     QoS prefetch limit for the entire channel, 0 if unlim‐
865                     ited.
866
867             If no channelinfoitem are specified then pid, user, con‐
868             sumer_count, and messages_unacknowledged are assumed.
869
870             For example, this command displays the connection process and
871             count of unacknowledged messages for each channel:
872
873                   rabbitmqctl list_channels connection
874                   messages_unacknowledged
875
876     list_ciphers
877
878             Lists cipher suites supported by encoding commands.
879
880             For example, this command instructs the RabbitMQ broker to list
881             all cipher suites supported by encoding commands:
882
883                   rabbitmqctl list_ciphers
884
885     list_connections [connectioninfoitem ...]
886
887             Returns TCP/IP connection statistics.
888
889             The connectioninfoitem parameter is used to indicate which con‐
890             nection information items to include in the results.  The column
891             order in the results will match the order of the parameters.
892             connectioninfoitem can take any value from the list that follows:
893
894             pid     Id of the Erlang process associated with the connection.
895
896             name    Readable name for the connection.
897
898             port    Server port.
899
900             host    Server hostname obtained via reverse DNS, or its IP ad‐
901                     dress if reverse DNS failed or was disabled.
902
903             peer_port
904                     Peer port.
905
906             peer_host
907                     Peer hostname obtained via reverse DNS, or its IP address
908                     if reverse DNS failed or was not enabled.
909
910             ssl     Boolean indicating whether the connection is secured with
911                     SSL.
912
913             ssl_protocol
914                     SSL protocol (e.g. "tlsv1").
915
916             ssl_key_exchange
917                     SSL key exchange algorithm (e.g. "rsa").
918
919             ssl_cipher
920                     SSL cipher algorithm (e.g. "aes_256_cbc").
921
922             ssl_hash
923                     SSL hash function (e.g. "sha").
924
925             peer_cert_subject
926                     The subject of the peer's SSL certificate, in RFC4514
927                     form.
928
929             peer_cert_issuer
930                     The issuer of the peer's SSL certificate, in RFC4514
931                     form.
932
933             peer_cert_validity
934                     The period for which the peer's SSL certificate is valid.
935
936             state   Connection state; one of:
937                     starting
938                     tuning
939                     opening
940                     running
941                     flow
942                     blocking
943                     blocked
944                     closing
945                     closed
946
947             channels
948                     Number of channels using the connection.
949
950             protocol
951                     Version of the AMQP protocol in use; currently one of:
952                     {0,9,1}
953                     {0,8,0}
954
955                     Note that if a client requests an AMQP 0-9 connection, we
956                     treat it as AMQP 0-9-1.
957
958             auth_mechanism
959                     SASL authentication mechanism used, such as "PLAIN".
960
961             user    Username associated with the connection.
962
963             vhost   Virtual host name with non-ASCII characters escaped as in
964                     C.
965
966             timeout
967                     Connection timeout / negotiated heartbeat interval, in
968                     seconds.
969
970             frame_max
971                     Maximum frame size (bytes).
972
973             channel_max
974                     Maximum number of channels on this connection.
975
976             client_properties
977                     Informational properties transmitted by the client during
978                     connection establishment.
979
980             recv_oct
981                     Octets received.
982
983             recv_cnt
984                     Packets received.
985
986             send_oct
987                     Octets send.
988
989             send_cnt
990                     Packets sent.
991
992             send_pend
993                     Send queue size.
994
995             connected_at
996                     Date and time this connection was established, as time‐
997                     stamp.
998
999             If no connectioninfoitem are specified then user, peer host, peer
1000             port, time since flow control and memory block state are dis‐
1001             played.
1002
1003             For example, this command displays the send queue size and server
1004             port for each connection:
1005
1006                   rabbitmqctl list_connections send_pend port
1007
1008     list_consumers [-p vhost]
1009
1010             Lists consumers, i.e. subscriptions to a queue´s message stream.
1011             Each line printed shows, separated by tab characters, the name of
1012             the queue subscribed to, the id of the channel process via which
1013             the subscription was created and is managed, the consumer tag
1014             which uniquely identifies the subscription within a channel, a
1015             boolean indicating whether acknowledgements are expected for mes‐
1016             sages delivered to this consumer, an integer indicating the
1017             prefetch limit (with 0 meaning "none"), and any arguments for
1018             this consumer.
1019
1020     list_exchanges [-p vhost] [exchangeinfoitem ...]
1021
1022             Returns exchange details.  Exchange details of the "/" virtual
1023             host are returned if the -p flag is absent.  The -p flag can be
1024             used to override this default.
1025
1026             The exchangeinfoitem parameter is used to indicate which exchange
1027             information items to include in the results.  The column order in
1028             the results will match the order of the parameters.
1029             exchangeinfoitem can take any value from the list that follows:
1030
1031             name    The name of the exchange with non-ASCII characters es‐
1032                     caped as in C.
1033
1034             type    The exchange type, such as:
1035                     direct
1036                     topic
1037                     headers
1038                     fanout
1039
1040             durable
1041                     Whether or not the exchange survives server restarts.
1042
1043             auto_delete
1044                     Whether the exchange will be deleted automatically when
1045                     no longer used.
1046
1047             internal
1048                     Whether the exchange is internal, i.e. cannot be directly
1049                     published to by a client.
1050
1051             arguments
1052                     Exchange arguments.
1053
1054             policy  Policy name for applying to the exchange.
1055
1056             If no exchangeinfoitem are specified then exchange name and type
1057             are displayed.
1058
1059             For example, this command displays the name and type for each ex‐
1060             change of the virtual host named "my-vhost":
1061
1062                   rabbitmqctl list_exchanges -p my-vhost name type
1063
1064     list_hashes
1065
1066             Lists hash functions supported by encoding commands.
1067
1068             For example, this command instructs the RabbitMQ broker to list
1069             all hash functions supported by encoding commands:
1070
1071                   rabbitmqctl list_hashes
1072
1073     list_queues [-p vhost] [--offline | --online | --local] [queueinfoitem
1074             ...]
1075
1076             Returns queue details.  Queue details of the "/" virtual host are
1077             returned if the -p flag is absent.  The -p flag can be used to
1078             override this default.
1079
1080             Displayed queues can be filtered by their status or location us‐
1081             ing one of the following mutually exclusive options:
1082
1083             --offline
1084                     List only those durable queues that are not currently
1085                     available (more specifically, their leader node isn't).
1086
1087             --online
1088                     List queues that are currently available (their leader
1089                     node is).
1090
1091             --local
1092                     List only those queues whose leader replica is located on
1093                     the current node.
1094
1095             The queueinfoitem parameter is used to indicate which queue in‐
1096             formation items to include in the results.  The column order in
1097             the results will match the order of the parameters.
1098             queueinfoitem can take any value from the list that follows:
1099
1100             name    The name of the queue with non-ASCII characters escaped
1101                     as in C.
1102
1103             durable
1104                     Whether or not the queue survives server restarts.
1105
1106             auto_delete
1107                     Whether the queue will be deleted automatically when no
1108                     longer used.
1109
1110             arguments
1111                     Queue arguments.
1112
1113             policy  Effective policy name for the queue.
1114
1115             pid     Erlang process identifier of the queue.
1116
1117             owner_pid
1118                     Id of the Erlang process of the connection which is the
1119                     exclusive owner of the queue.  Empty if the queue is non-
1120                     exclusive.
1121
1122             exclusive
1123                     True if queue is exclusive (i.e. has owner_pid), false
1124                     otherwise.
1125
1126             exclusive_consumer_pid
1127                     Id of the Erlang process representing the channel of the
1128                     exclusive consumer subscribed to this queue.  Empty if
1129                     there is no exclusive consumer.
1130
1131             exclusive_consumer_tag
1132                     Consumer tag of the exclusive consumer subscribed to this
1133                     queue.  Empty if there is no exclusive consumer.
1134
1135             messages_ready
1136                     Number of messages ready to be delivered to clients.
1137
1138             messages_unacknowledged
1139                     Number of messages delivered to clients but not yet ac‐
1140                     knowledged.
1141
1142             messages
1143                     Sum of ready and unacknowledged messages (queue depth).
1144
1145             messages_ready_ram
1146                     Number of messages from messages_ready which are resident
1147                     in ram.
1148
1149             messages_unacknowledged_ram
1150                     Number of messages from messages_unacknowledged which are
1151                     resident in ram.
1152
1153             messages_ram
1154                     Total number of messages which are resident in ram.
1155
1156             messages_persistent
1157                     Total number of persistent messages in the queue (will
1158                     always be 0 for transient queues).
1159
1160             message_bytes
1161                     Sum of the size of all message bodies in the queue.  This
1162                     does not include the message properties (including head‐
1163                     ers) or any overhead.
1164
1165             message_bytes_ready
1166                     Like message_bytes but counting only those messages ready
1167                     to be delivered to clients.
1168
1169             message_bytes_unacknowledged
1170                     Like message_bytes but counting only those messages de‐
1171                     livered to clients but not yet acknowledged.
1172
1173             message_bytes_ram
1174                     Like message_bytes but counting only those messages which
1175                     are currently held in RAM.
1176
1177             message_bytes_persistent
1178                     Like message_bytes but counting only those messages which
1179                     are persistent.
1180
1181             head_message_timestamp
1182                     The timestamp property of the first message in the queue,
1183                     if present.  Timestamps of messages only appear when they
1184                     are in the paged-in state.
1185
1186             disk_reads
1187                     Total number of times messages have been read from disk
1188                     by this queue since it started.
1189
1190             disk_writes
1191                     Total number of times messages have been written to disk
1192                     by this queue since it started.
1193
1194             consumers
1195                     Number of consumers.
1196
1197             consumer_utilisation
1198                     Fraction of the time (between 0.0 and 1.0) that the queue
1199                     is able to immediately deliver messages to consumers.
1200                     This can be less than 1.0 if consumers are limited by
1201                     network congestion or prefetch count.
1202
1203             memory  Bytes of memory allocated by the runtime for the queue,
1204                     including stack, heap and internal structures.
1205
1206             slave_pids
1207                     If the queue is mirrored, this lists the IDs of the mir‐
1208                     rors (follower replicas).  To learn more, see the
1209                     RabbitMQ Mirroring guide:
1210                     https://www.rabbitmq.com/ha.html
1211
1212             synchronised_slave_pids
1213                     If the queue is mirrored, this gives the IDs of the mir‐
1214                     rors (follower replicas) which are in sync with the
1215                     leader replica. To learn more, see the RabbitMQ Mirroring
1216                     guide: https://www.rabbitmq.com/ha.html
1217
1218             state   The state of the queue.  Normally "running", but may be
1219                     "{syncing, message_count}" if the queue is synchronising.
1220
1221                     Queues which are located on cluster nodes that are cur‐
1222                     rently down will be shown with a status of "down" (and
1223                     most other queueinfoitem will be unavailable).
1224
1225             If no queueinfoitem are specified then queue name and depth are
1226             displayed.
1227
1228             For example, this command displays the depth and number of con‐
1229             sumers for each queue of the virtual host named "my-vhost"
1230
1231                   rabbitmqctl list_queues -p my-vhost messages consumers
1232
1233     list_unresponsive_queues [--local] [--queue-timeout milliseconds] [column
1234             ...] [--no-table-headers]
1235
1236             Tests queues to respond within timeout. Lists those which did not
1237             respond
1238
1239             For example, this command lists only those unresponsive queues
1240             whose leader replica is hosted on the target node.
1241                   rabbitmqctl list_unresponsive_queues --local name
1242
1243     ping
1244
1245             Checks that the node OS process is up, registered with EPMD and
1246             CLI tools can authenticate with it
1247
1248             Example:
1249                   rabbitmqctl ping -n rabbit@hostname
1250
1251     report
1252
1253             Generate a server status report containing a concatenation of all
1254             server status information for support purposes.  The output
1255             should be redirected to a file when accompanying a support re‐
1256             quest.
1257
1258             For example, this command creates a server report which may be
1259             attached to a support request email:
1260
1261                   rabbitmqctl report > server_report.txt
1262
1263     schema_info [--no-table-headers] [column ...]
1264
1265             Lists schema database tables and their properties
1266
1267             For example, this command lists the table names and their active
1268             replicas:
1269
1270                   rabbitmqctl schema_info name active_replicas
1271
1272     status
1273
1274             Displays broker status information such as the running applica‐
1275             tions on the current Erlang node, RabbitMQ and Erlang versions,
1276             OS name, memory and file descriptor statistics.  (See the
1277             cluster_status command to find out which nodes are clustered and
1278             running.)
1279
1280             For example, this command displays information about the RabbitMQ
1281             broker:
1282
1283                   rabbitmqctl status
1284
1285   Runtime Parameters and Policies
1286     Certain features of RabbitMQ (such as the Federation plugin) are con‐
1287     trolled by dynamic, cluster-wide parameters. There are 2 kinds of parame‐
1288     ters: parameters scoped to a virtual host and global parameters.  Each
1289     vhost-scoped parameter consists of a component name, a name and a value.
1290     The component name and name are strings, and the value is a valid JSON
1291     document.  A global parameter consists of a name and value.  The name is
1292     a string and the value is an arbitrary Erlang data structure.  Parameters
1293     can be set, cleared and listed.  In general you should refer to the docu‐
1294     mentation for the feature in question to see how to set parameters.
1295
1296     Policies is a feature built on top of runtime parameters.  Policies are
1297     used to control and modify the behaviour of queues and exchanges on a
1298     cluster-wide basis.  Policies apply within a given vhost, and consist of
1299     a name, pattern, definition and an optional priority.  Policies can be
1300     set, cleared and listed.
1301
1302     clear_global_parameter name
1303
1304             Clears a global runtime parameter.  This is similar to
1305             clear_parameter but the key-value pair isn't tied to a virtual
1306             host.
1307
1308             name    The name of the global runtime parameter being cleared.
1309
1310             For example, this command clears the global runtime parameter
1311             "mqtt_default_vhosts":
1312
1313                   rabbitmqctl clear_global_parameter mqtt_default_vhosts
1314
1315     clear_parameter [-p vhost] component_name key
1316
1317             Clears a parameter.
1318
1319             component_name
1320                     The name of the component for which the parameter is be‐
1321                     ing cleared.
1322
1323             name    The name of the parameter being cleared.
1324
1325             For example, this command clears the parameter "node01" for the
1326             "federation-upstream" component in the default virtual host:
1327
1328                   rabbitmqctl clear_parameter federation-upstream node01
1329
1330     list_global_parameters
1331
1332             Lists all global runtime parameters.  This is similar to
1333             list_parameters but the global runtime parameters are not tied to
1334             any virtual host.
1335
1336             For example, this command lists all global parameters:
1337
1338                   rabbitmqctl list_global_parameters
1339
1340     list_parameters [-p vhost]
1341
1342             Lists all parameters for a virtual host.
1343
1344             For example, this command lists all parameters in the default
1345             virtual host:
1346
1347                   rabbitmqctl list_parameters
1348
1349     set_global_parameter name value
1350
1351             Sets a global runtime parameter.  This is similar to
1352             set_parameter but the key-value pair isn't tied to a virtual
1353             host.
1354
1355             name    The name of the global runtime parameter being set.
1356
1357             value   The value for the global runtime parameter, as a JSON
1358                     term.  In most shells you are very likely to need to
1359                     quote this.
1360
1361             For example, this command sets the global runtime parameter
1362             "mqtt_default_vhosts" to the JSON term {"O=client,CN=guest":"/"}:
1363
1364                   rabbitmqctl set_global_parameter mqtt_default_vhosts
1365                   '{"O=client,CN=guest":"/"}'
1366
1367     set_parameter [-p vhost] component_name name value
1368
1369             Sets a parameter.
1370
1371             component_name
1372                     The name of the component for which the parameter is be‐
1373                     ing set.
1374
1375             name    The name of the parameter being set.
1376
1377             value   The value for the parameter, as a JSON term.  In most
1378                     shells you are very likely to need to quote this.
1379
1380             For example, this command sets the parameter "node01" for the
1381             "federation-upstream" component in the default virtual host to
1382             the following JSON "guest":
1383
1384                   rabbitmqctl set_parameter federation-upstream node01
1385                   '{"uri":"amqp://user:password@server/%2F","ack-mode":"on-publish"}'
1386
1387     list_policies [-p vhost]
1388
1389             Lists all policies for a virtual host.
1390
1391             For example, this command lists all policies in the default vir‐
1392             tual host:
1393
1394                   rabbitmqctl list_policies
1395
1396     set_operator_policy [-p vhost] [--priority priority] [--apply-to
1397             apply-to] name pattern definition
1398
1399             Sets an operator policy that overrides a subset of arguments in
1400             user policies.  Arguments are identical to those of set_policy.
1401
1402             Supported arguments are:
1403             expires
1404             message-ttl
1405             max-length
1406             max-length-bytes
1407
1408     set_policy [-p vhost] [--priority priority] [--apply-to apply-to] name
1409             pattern definition
1410
1411             Sets a policy.
1412
1413             name    The name of the policy.
1414
1415             pattern
1416                     The regular expression, which when matches on a given re‐
1417                     sources causes the policy to apply.
1418
1419             definition
1420                     The definition of the policy, as a JSON term.  In most
1421                     shells you are very likely to need to quote this.
1422
1423             priority
1424                     The priority of the policy as an integer.  Higher numbers
1425                     indicate greater precedence.  The default is 0.
1426
1427             apply-to
1428                     Which types of object this policy should apply to.  Pos‐
1429                     sible values are:
1430                     queues
1431                     exchanges
1432                     all
1433                     The default is all ..
1434
1435             For example, this command sets the policy "federate-me" in the
1436             default virtual host so that built-in exchanges are federated:
1437
1438                   rabbitmqctl set_policy federate-me ^amq.
1439                   '{"federation-upstream-set":"all"}'
1440
1441     clear_policy [-p vhost] name
1442
1443             Clears a policy.
1444
1445             name    The name of the policy being cleared.
1446
1447             For example, this command clears the "federate-me" policy in the
1448             default virtual host:
1449
1450                   rabbitmqctl clear_policy federate-me
1451
1452     clear_operator_policy [-p vhost] name
1453
1454             Clears an operator policy.  Arguments are identical to those of
1455             clear_policy.
1456
1457     list_operator_policies [-p vhost]
1458
1459             Lists operator policy overrides for a virtual host.  Arguments
1460             are identical to those of list_policies.
1461
1462   Virtual hosts
1463     Note that rabbitmqctl manages the RabbitMQ internal user database.  Per‐
1464     missions for users from any alternative authorisation backend will not be
1465     visible to rabbitmqctl.
1466
1467     add_vhost vhost
1468
1469             vhost   The name of the virtual host entry to create.
1470
1471             Creates a virtual host.
1472
1473             For example, this command instructs the RabbitMQ broker to create
1474             a new virtual host called "test":
1475
1476                   rabbitmqctl add_vhost test
1477
1478     clear_vhost_limits [-p vhost]
1479
1480             Clears virtual host limits.
1481
1482             For example, this command clears vhost limits in vhost "qa_env":
1483
1484                   rabbitmqctl clear_vhost_limits -p qa_env
1485
1486     delete_vhost vhost
1487
1488             vhost   The name of the virtual host entry to delete.
1489
1490             Deletes a virtual host.
1491
1492             Deleting a virtual host deletes all its exchanges, queues, bind‐
1493             ings, user permissions, parameters and policies.
1494
1495             For example, this command instructs the RabbitMQ broker to delete
1496             the virtual host called "test":
1497
1498                   rabbitmqctl delete_vhost a-vhost
1499
1500     list_vhost_limits [-p vhost] [--global] [--no-table-headers]
1501
1502             Displays configured virtual host limits.
1503
1504             --global
1505                     Show limits for all vhosts.  Suppresses the -p parameter.
1506
1507     restart_vhost vhost
1508
1509             vhost   The name of the virtual host entry to restart.
1510
1511             Restarts a failed vhost data stores and queues.
1512
1513             For example, this command instructs the RabbitMQ broker to
1514             restart a virtual host called "test":
1515
1516                   rabbitmqctl restart_vhost test
1517
1518     set_vhost_limits [-p vhost] definition
1519
1520             Sets virtual host limits.
1521
1522             definition
1523                     The definition of the limits, as a JSON term.  In most
1524                     shells you are very likely to need to quote this.
1525
1526                     Recognised limits are:
1527                     max-connections
1528                     max-queues
1529
1530                     Use a negative value to specify "no limit".
1531
1532             For example, this command limits the max number of concurrent
1533             connections in vhost "qa_env" to 64:
1534
1535                   rabbitmqctl set_vhost_limits -p qa_env '{"max-connections":
1536                   64}'
1537
1538             This command limits the max number of queues in vhost "qa_env" to
1539             256:
1540
1541                   rabbitmqctl set_vhost_limits -p qa_env '{"max-queues":
1542                   256}'
1543
1544             This command clears the max number of connections limit in vhost
1545             "qa_env":
1546
1547                   rabbitmqctl set_vhost_limits -p qa_env '{"max-connections":
1548                   -1}'
1549
1550             This command disables client connections in vhost "qa_env":
1551
1552                   rabbitmqctl set_vhost_limits -p qa_env '{"max-connections":
1553                   0}'
1554
1555     trace_off [-p vhost]
1556
1557             vhost   The name of the virtual host for which to stop tracing.
1558
1559             Stops tracing.
1560
1561     trace_on [-p vhost]
1562
1563             vhost   The name of the virtual host for which to start tracing.
1564
1565             Starts tracing.  Note that the trace state is not persistent; it
1566             will revert to being off if the node is restarted.
1567
1568   Configuration
1569     decode value passphrase [--cipher cipher] [--hash hash] [--iterations
1570             iterations]
1571
1572             value passphrase
1573                     Value to decrypt (as produced by the encode command) and
1574                     passphrase.
1575
1576                     For example:
1577
1578                           rabbitmqctl decode '{encrypted, <<"...">>}'
1579                           mypassphrase
1580
1581             --cipher cipher --hash hash --iterations iterations
1582                     Options to specify the decryption settings.  They can be
1583                     used independently.
1584
1585                     For example:
1586
1587                           rabbitmqctl decode --cipher blowfish_cfb64 --hash
1588                           sha256 --iterations 10000 '{encrypted,<<"...">>}
1589                           mypassphrase
1590
1591     encode value passphrase [--cipher cipher] [--hash hash] [--iterations
1592             iterations]
1593
1594             value passphrase
1595                     Value to encrypt and passphrase.
1596
1597                     For example:
1598
1599                           rabbitmqctl encode '<<"guest">>' mypassphrase
1600
1601             --cipher cipher --hash hash --iterations iterations
1602                     Options to specify the encryption settings.  They can be
1603                     used independently.
1604
1605                     For example:
1606
1607                           rabbitmqctl encode --cipher blowfish_cfb64 --hash
1608                           sha256 --iterations 10000 '<<"guest">>'
1609                           mypassphrase
1610
1611     set_cluster_name name
1612
1613             Sets the cluster name to name.  The cluster name is announced to
1614             clients on connection, and used by the federation and shovel
1615             plugins to record where a message has been.  The cluster name is
1616             by default derived from the hostname of the first node in the
1617             cluster, but can be changed.
1618
1619             For example, this sets the cluster name to "london":
1620
1621                   rabbitmqctl set_cluster_name london
1622
1623     set_disk_free_limit disk_limit
1624
1625             disk_limit
1626                     Lower bound limit as an integer in bytes or a string with
1627                     memory unit symbols (see vm_memory_high_watermark), e.g.
1628                     512M or 1G.  Once free disk space reaches the limit, a
1629                     disk alarm will be set.
1630
1631     set_disk_free_limit mem_relative fraction
1632
1633             fraction
1634                     Limit relative to the total amount available RAM as a
1635                     non-negative floating point number.  Values lower than
1636                     1.0 can be dangerous and should be used carefully.
1637
1638     set_log_level [log_level]
1639
1640             Sets log level in the running node
1641
1642             Supported type values are:
1643             debug
1644             info
1645             warning
1646             error
1647             none
1648
1649             Example:
1650                   rabbitmqctl set_log_level debug
1651
1652     set_vm_memory_high_watermark fraction
1653
1654             fraction
1655                     The new memory threshold fraction at which flow control
1656                     is triggered, as a floating point number greater than or
1657                     equal to 0.
1658
1659     set_vm_memory_high_watermark [absolute] memory_limit
1660
1661             memory_limit
1662                     The new memory limit at which flow control is triggered,
1663                     expressed in bytes as an integer number greater than or
1664                     equal to 0 or as a string with memory unit symbol(e.g.
1665                     512M or 1G).  Available unit symbols are:
1666
1667                     k, kiB  kibibytes (2^10 bytes)
1668
1669                     M, MiB  mebibytes (2^20 bytes)
1670
1671                     G, GiB  gibibytes (2^30 bytes)
1672
1673                     kB      kilobytes (10^3 bytes)
1674
1675                     MB      megabytes (10^6 bytes)
1676
1677                     GB      gigabytes (10^9 bytes)
1678
1679   Feature flags
1680     enable_feature_flag feature_flag
1681
1682             Enables a feature flag on the target node.
1683
1684             Example:
1685                   rabbitmqctl enable_feature_flag quorum_queue
1686
1687             You can also enable all feature flags by specifying "all":
1688                   rabbitmqctl enable_feature_flag all
1689
1690     list_feature_flags [column ...]
1691
1692             Lists feature flags
1693
1694             Supported column values are:
1695             name
1696             state
1697             stability
1698             provided_by
1699             desc
1700             doc_url
1701
1702             Example:
1703                   rabbitmqctl list_feature_flags name state
1704
1705   Connection Operations
1706     close_all_connections [-p vhost] [--global] [--per-connection-delay
1707             delay] [--limit limit] explanation
1708
1709             -p vhost
1710                     The name of the virtual host for which connections should
1711                     be closed.  Ignored when --global is specified.
1712
1713             --global
1714                     If connections should be close for all vhosts.  Overrides
1715                     -p
1716
1717             --per-connection-delay delay
1718                     Time in milliseconds to wait after each connection clos‐
1719                     ing.
1720
1721             --limit limit
1722                     Number of connection to close.  Only works per vhost.
1723                     Ignored when --global is specified.
1724
1725             explanation
1726                     Explanation string.
1727
1728             Instructs the broker to close all connections for the specified
1729             vhost or entire RabbitMQ node.
1730
1731             For example, this command instructs the RabbitMQ broker to close
1732             10 connections on "qa_env" vhost, passing the explanation "Please
1733             close":
1734
1735                   rabbitmqctl close_all_connections -p qa_env --limit 10
1736                   'Please close'
1737
1738             This command instructs broker to close all connections to the
1739             node:
1740
1741                   rabbitmqctl close_all_connections --global
1742
1743
1744     close_connection connectionpid explanation
1745
1746             connectionpid
1747                     Id of the Erlang process associated with the connection
1748                     to close.
1749
1750             explanation
1751                     Explanation string.
1752
1753             Instructs the broker to close the connection associated with the
1754             Erlang process id connectionpid (see also the list_connections
1755             command), passing the explanation string to the connected client
1756             as part of the AMQP connection shutdown protocol.
1757
1758             For example, this command instructs the RabbitMQ broker to close
1759             the connection associated with the Erlang process id
1760             "<rabbit@tanto.4262.0>", passing the explanation "go away" to the
1761             connected client:
1762
1763                   rabbitmqctl close_connection "<rabbit@tanto.4262.0>" "go
1764                   away"
1765
1766   Misc
1767     eval expression
1768
1769             Evaluates an Erlang expression on the target node
1770
1771           Queue Operations
1772             delete_queue queue_name [--if-empty | -e] [--if-unused | -u]
1773
1774                     queue_name
1775                             The name of the queue to delete.
1776
1777                     --if-empty
1778                             Delete the queue if it is empty (has no messages
1779                             ready for delivery)
1780
1781                     --if-unused
1782                             Delete the queue only if it has no consumers
1783
1784                     Deletes a queue.
1785
1786             purge_queue [-p vhost] queue
1787
1788                     queue   The name of the queue to purge.
1789
1790                     Purges a queue (removes all messages in it).
1791

PLUGIN COMMANDS

1793     RabbitMQ plugins can extend rabbitmqctl tool to add new commands when en‐
1794     abled.  Currently available commands can be found in rabbitmqctl help
1795     output.  Following commands are added by RabbitMQ plugins, available in
1796     default distribution:
1797
1798   Shovel plugin
1799     shovel_status
1800             Prints a list of configured Shovels
1801
1802     delete_shovel [-p vhost] name
1803             Instructs the RabbitMQ node to delete the configured shovel by
1804             name.
1805
1806   Federation plugin
1807     federation_status [--only-down]
1808             Prints a list of federation links.
1809
1810             --only-down
1811                     Only list federation links which are not running.
1812
1813     restart_federation_link link_id
1814             Instructs the RabbitMQ node to restart the federation link with
1815             specified link_id.
1816
1817   AMQP 1.0 plugin
1818     list_amqp10_connections [amqp10_connectioninfoitem ...]
1819             Similar to the list_connections command, but returns fields which
1820             make sense for AMQP-1.0 connections.  amqp10_connectioninfoitem
1821             parameter is used to indicate which connection information items
1822             to include in the results.  The column order in the results will
1823             match the order of the parameters.  amqp10_connectioninfoitem can
1824             take any value from the list that follows:
1825
1826             pid     Id of the Erlang process associated with the connection.
1827
1828             auth_mechanism
1829                     SASL authentication mechanism used, such as "PLAIN".
1830
1831             host    Server hostname obtained via reverse DNS, or its IP ad‐
1832                     dress if reverse DNS failed or was disabled.
1833
1834             frame_max
1835                     Maximum frame size (bytes).
1836
1837             timeout
1838                     Connection timeout / negotiated heartbeat interval, in
1839                     seconds.
1840
1841             user    Username associated with the connection.
1842
1843             state   Connection state; one of:
1844                     starting
1845                     waiting_amqp0100
1846                     securing
1847                     running
1848                     blocking
1849                     blocked
1850                     closing
1851                     closed
1852
1853             recv_oct
1854                     Octets received.
1855
1856             recv_cnt
1857                     Packets received.
1858
1859             send_oct
1860                     Octets send.
1861
1862             send_cnt
1863                     Packets sent.
1864
1865             ssl     Boolean indicating whether the connection is secured with
1866                     SSL.
1867
1868             ssl_protocol
1869                     SSL protocol (e.g. "tlsv1").
1870
1871             ssl_key_exchange
1872                     SSL key exchange algorithm (e.g. "rsa").
1873
1874             ssl_cipher
1875                     SSL cipher algorithm (e.g. "aes_256_cbc").
1876
1877             ssl_hash
1878                     SSL hash function (e.g. "sha").
1879
1880             peer_cert_subject
1881                     The subject of the peer's SSL certificate, in RFC4514
1882                     form.
1883
1884             peer_cert_issuer
1885                     The issuer of the peer's SSL certificate, in RFC4514
1886                     form.
1887
1888             peer_cert_validity
1889                     The period for which the peer's SSL certificate is valid.
1890
1891             node    The node name of the RabbitMQ node to which connection is
1892                     established.
1893
1894   MQTT plugin
1895     list_mqtt_connections [mqtt_connectioninfoitem]
1896             Similar to the list_connections command, but returns fields which
1897             make sense for MQTT connections.  mqtt_connectioninfoitem parame‐
1898             ter is used to indicate which connection information items to in‐
1899             clude in the results.  The column order in the results will match
1900             the order of the parameters.  mqtt_connectioninfoitem can take
1901             any value from the list that follows:
1902
1903             host    Server hostname obtained via reverse DNS, or its IP ad‐
1904                     dress if reverse DNS failed or was disabled.
1905
1906             port    Server port.
1907
1908             peer_host
1909                     Peer hostname obtained via reverse DNS, or its IP address
1910                     if reverse DNS failed or was not enabled.
1911
1912             peer_port
1913                     Peer port.
1914
1915             protocol
1916                     MQTT protocol version, which can be on of the following:
1917                     {'MQTT', N/A}
1918                     {'MQTT', 3.1.0}
1919                     {'MQTT', 3.1.1}
1920
1921             channels
1922                     Number of channels using the connection.
1923
1924             channel_max
1925                     Maximum number of channels on this connection.
1926
1927             frame_max
1928                     Maximum frame size (bytes).
1929
1930             client_properties
1931                     Informational properties transmitted by the client during
1932                     connection establishment.
1933
1934             ssl     Boolean indicating whether the connection is secured with
1935                     SSL.
1936
1937             ssl_protocol
1938                     SSL protocol (e.g. "tlsv1").
1939
1940             ssl_key_exchange
1941                     SSL key exchange algorithm (e.g. "rsa").
1942
1943             ssl_cipher
1944                     SSL cipher algorithm (e.g. "aes_256_cbc").
1945
1946             ssl_hash
1947                     SSL hash function (e.g. "sha").
1948
1949             conn_name
1950                     Readable name for the connection.
1951
1952             connection_state
1953                     Connection state; one of:
1954                     starting
1955                     running
1956                     blocked
1957
1958             connection
1959                     Id of the Erlang process associated with the internal
1960                     amqp direct connection.
1961
1962             consumer_tags
1963                     A tuple of consumer tags for QOS0 and QOS1.
1964
1965             message_id
1966                     The last Packet ID sent in a control message.
1967
1968             client_id
1969                     MQTT client identifier for the connection.
1970
1971             clean_sess
1972                     MQTT clean session flag.
1973
1974             will_msg
1975                     MQTT Will message sent in CONNECT frame.
1976
1977             exchange
1978                     Exchange to route MQTT messages configured in rab‐
1979                     bitmq_mqtt application environment.
1980
1981             ssl_login_name
1982                     SSL peer cert auth name
1983
1984             retainer_pid
1985                     Id of the Erlang process associated with retain storage
1986                     for the connection.
1987
1988             user    Username associated with the connection.
1989
1990             vhost   Virtual host name with non-ASCII characters escaped as in
1991                     C.
1992
1993   STOMP plugin
1994     list_stomp_connections [stomp_connectioninfoitem]
1995             Similar to the list_connections command, but returns fields which
1996             make sense for STOMP connections.  stomp_connectioninfoitem pa‐
1997             rameter is used to indicate which connection information items to
1998             include in the results.  The column order in the results will
1999             match the order of the parameters.  stomp_connectioninfoitem can
2000             take any value from the list that follows:
2001
2002             conn_name
2003                     Readable name for the connection.
2004
2005             connection
2006                     Id of the Erlang process associated with the internal
2007                     amqp direct connection.
2008
2009             connection_state
2010                     Connection state; one of:
2011                     running
2012                     blocking
2013                     blocked
2014
2015             session_id
2016                     STOMP protocol session identifier
2017
2018             channel
2019                     AMQP channel associated with the connection
2020
2021             version
2022                     Negotiated STOMP protocol version for the connection.
2023
2024             implicit_connect
2025                     Indicates if the connection was established using im‐
2026                     plicit connect (without CONNECT frame)
2027
2028             auth_login
2029                     Effective username for the connection.
2030
2031             auth_mechanism
2032                     STOMP authorization mechanism.  Can be one of:
2033                     config
2034                     ssl
2035                     stomp_headers
2036
2037             port    Server port.
2038
2039             host    Server hostname obtained via reverse DNS, or its IP ad‐
2040                     dress if reverse DNS failed or was not enabled.
2041
2042             peer_port
2043                     Peer port.
2044
2045             peer_host
2046                     Peer hostname obtained via reverse DNS, or its IP address
2047                     if reverse DNS failed or was not enabled.
2048
2049             protocol
2050                     STOMP protocol version, which can be on of the following:
2051                     {'STOMP', 0}
2052                     {'STOMP', 1}
2053                     {'STOMP', 2}
2054
2055             channels
2056                     Number of channels using the connection.
2057
2058             channel_max
2059                     Maximum number of channels on this connection.
2060
2061             frame_max
2062                     Maximum frame size (bytes).
2063
2064             client_properties
2065                     Informational properties transmitted by the client during
2066                     connection
2067
2068             ssl     Boolean indicating whether the connection is secured with
2069                     SSL.
2070
2071             ssl_protocol
2072                     TLS protocol (e.g. "tlsv1").
2073
2074             ssl_key_exchange
2075                     TLS key exchange algorithm (e.g. "rsa").
2076
2077             ssl_cipher
2078                     TLS cipher algorithm (e.g. "aes_256_cbc").
2079
2080             ssl_hash
2081                     SSL hash function (e.g. "sha").
2082
2083   Management agent plugin
2084     reset_stats_db [--all]
2085             Reset management stats database for the RabbitMQ node.
2086
2087             --all   Reset stats database for all nodes in the cluster.
2088

SEE ALSO

2090     rabbitmq-diagnostics(8), rabbitmq-plugins(8), rabbitmq-server(8),
2091     rabbitmq-queues(8), rabbitmq-upgrade(8), rabbitmq-service(8),
2092     rabbitmq-env.conf(5), rabbitmq-echopid(8)
2093

AUTHOR

2095     The RabbitMQ Team <info@rabbitmq.com>
2096
2097RabbitMQ Server                  June 19, 2021                 RabbitMQ Server
Impressum