目录
Erlang
RabbitMQ
效果展示
安装环境:CentOS V7 7180
JDK使用了系统自带的
[root@localhost ~]# java -version
openjdk version "1.8.0_131"
OpenJDK Runtime Environment (build 1.8.0_131-b12)
OpenJDK 64-Bit Server VM (build 25.131-b12, mixed mode)
yum 安装 erlang
[root@localhost david]# vi /etc/yum.repos.d/rabbitmq_erlang.repo
rabbitmq_erlang.repo文件内容:
[rabbitmq_erlang]
name=rabbitmq_erlang
baseurl=https://packagecloud.io/rabbitmq/erlang/el/7/$basearch
repo_gpgcheck=1
gpgcheck=0
enabled=1
gpgkey=https://packagecloud.io/rabbitmq/erlang/gpgkey
sslverify=1
sslcacert=/etc/pki/tls/certs/ca-bundle.crt
metadata_expire=300
[rabbitmq_erlang-source]
name=rabbitmq_erlang-source
baseurl=https://packagecloud.io/rabbitmq/erlang/el/7/SRPMS
repo_gpgcheck=1
gpgcheck=0
enabled=1
gpgkey=https://packagecloud.io/rabbitmq/erlang/gpgkey
sslverify=1
sslcacert=/etc/pki/tls/certs/ca-bundle.crt
metadata_expire=300
[root@localhost david]# yum install -y erlang
已加载插件:fastestmirror, langpacks
rabbitmq_erlang-source/signature | 819 B 00:00
从 https://packagecloud.io/rabbitmq/erlang/gpgkey 检索密钥
导入 GPG key 0xDF309A0B:
用户ID : "https://packagecloud.io/rabbitmq/erlang (https://packagecloud.io/docs#gpg_signing)
指纹 : 2ebd e413 d3ce 5d35 bcd1 5b7c 71c6 3471 df30 9a0b
来自 : https://packagecloud.io/rabbitmq/erlang/gpgkey
rabbitmq_erlang-source/signature | 951 B 00:00 !!!
rbbitmq_erlang/x86_64/signature | 833 B 00:00
从 https://packagecloud.io/rabbitmq/erlang/gpgkey 检索密钥
导入 GPG key 0xDF309A0B:
用户ID : "https://packagecloud.io/rabbitmq/erlang (https://packagecloud.io/docs#gpg_signing)
指纹 : 2ebd e413 d3ce 5d35 bcd1 5b7c 71c6 3471 df30 9a0b
来自 : https://packagecloud.io/rabbitmq/erlang/gpgkey
rbbitmq_erlang/x86_64/signature | 1.0 kB 00:00 !!!
(1/2): rabbitmq_erlang-source/primary | 175 B 00:06
(2/2): rbbitmq_erlang/x86_64/primary | 192 kB 00:10
Loading mirror speeds from cached hostfile
* base: mirrors.ustc.edu.cn
* extras: mirrors.ustc.edu.cn
* updates: mirrors.ustc.edu.cn
rbbitmq_erlang 30/30
正在解决依赖关系
--> 正在检查事务
---> 软件包 erlang.x86_64.0.23.3-2.el7 将被 安装
--> 解决依赖关系完成
依赖关系解决
================================================================================
Package 架构 版本 源 大小
================================================================================
正在安装:
erlang x86_64 23.3-2.el7 rbbitmq_erlang 19 M
事务概要
================================================================================
安装 1 软件包
总下载量:19 M
安装大小:34 M
Downloading packages:
erlang-23.3-2.el7.x86_64.rpm | 19 MB 00:25
Running transaction check
Running transaction test
Transaction test succeeded
Running transaction
正在安装 : erlang-23.3-2.el7.x86_64 1/1
验证中 : erlang-23.3-2.el7.x86_64 1/1
已安装:
erlang.x86_64 0:23.3-2.el7
完毕!
确认安装:
[root@localhost david]# erl -version
Erlang (SMP,ASYNC_THREADS,HIPE) (BEAM) emulator version 11.2
一小段说明:
RabbitMQ 3.8.14
@pivotal-rabbitmq-ci pivotal-rabbitmq-ci released this 25 days ago · 4399 commits to master since this release
RabbitMQ 3.8.14
RabbitMQ 3.8.14 is a maintenance release that restores
Erlang 22.3 compatibility for environments that use direct reply-to.
Erlang/OTP Compatibility Notes
This release requires Erlang 22.3.
Erlang 23 is highly recommended
for best forward compatibility with future RabbitMQ versions.
Provisioning Latest Erlang Releases explains
what package repositories and tools can be used to provision a recent version of Erlang 23.x.
Upgrade and Compatibility Notes
Upgrade Doc Guides and Change Log
See 3.8.0 release notes upgrade and
compatibility notes first if upgrading from an earlier release series (e.g. 3.7.x).
See the Upgrading guide for general documentation on upgrades and
RabbitMQ change log for release notes of other releases.
Upgrading to Erlang 22.x or Later Versions
When upgrading to this release from 3.7.15 or an older version, extra care has to be taken.
Because older RabbitMQ CLI tools can be incompatible with Erlang 22+ releases,
RabbitMQ must be upgraded at the same time as Erlang.
Alternatively the node can be upgraded to 3.7.18 on Erlang 21.3 first,
then Erlang 22.3 or 23.x, then RabbitMQ to the most recent 3.8.x release.
下载地址:
https://github.com/rabbitmq/rabbitmq-server/releases/
从下载列表看,RabbitMQ很成熟
[root@localhost david]# wget https://github.com/rabbitmq/rabbitmq-server/releases/download/v3.8.14/rabbitmq-server-3.8.14-1.el8.noarch.rpm
--2021-03-28 09:35:19-- https://github.com/rabbitmq/rabbitmq-server/releases/download/v3.8.14/rabbitmq-server-3.8.14-1.el8.noarch.rpm
正在解析主机 github.com (github.com)... 13.250.177.223
正在连接 github.com (github.com)|13.250.177.223|:443... 已连接。
已发出 HTTP 请求,正在等待回应... 302 Found
位置:https://github-releases.githubusercontent.com/924551/01ba1480-7b7e-11eb-9418-5c501bb554ab?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIWNJYAX4CSVEH53A%2F20210327%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20210327T174332Z&X-Amz-Expires=300&X-Amz-Signature=9891b89a4434784013a735ba0d85077cff275596467715c547d6adc1e5efe7dc&X-Amz-SignedHeaders=host&actor_id=0&key_id=0&repo_id=924551&response-content-disposition=attachment%3B%20filename%3Drabbitmq-server-3.8.14-1.el8.noarch.rpm&response-content-type=application%2Foctet-stream [跟随至新的 URL]
--2021-03-28 09:35:20-- https://github-releases.githubusercontent.com/924551/01ba1480-7b7e-11eb-9418-5c501bb554ab?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIWNJYAX4CSVEH53A%2F20210327%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20210327T174332Z&X-Amz-Expires=300&X-Amz-Signature=9891b89a4434784013a735ba0d85077cff275596467715c547d6adc1e5efe7dc&X-Amz-SignedHeaders=host&actor_id=0&key_id=0&repo_id=924551&response-content-disposition=attachment%3B%20filename%3Drabbitmq-server-3.8.14-1.el8.noarch.rpm&response-content-type=application%2Foctet-stream
正在解析主机 github-releases.githubusercontent.com (github-releases.githubusercontent.com)... 185.199.108.154, 185.199.110.154, 185.199.109.154, ...
正在连接 github-releases.githubusercontent.com (github-releases.githubusercontent.com)|185.199.108.154|:443... 已连接。
已发出 HTTP 请求,正在等待回应... 200 OK
长度:15836855 (15M) [application/octet-stream]
正在保存至: “rabbitmq-server-3.8.14-1.el8.noarch.rpm”
100%[==================================================================================================>] 15,836,855 49.9KB/s 用时 3m 50s
2021-03-28 09:39:10 (67.4 KB/s) - 已保存 “rabbitmq-server-3.8.14-1.el8.noarch.rpm” [15836855/15836855])
[root@localhost david]# yum install rabbitmq-server-3.8.14-1.el8.noarch.rpm
已加载插件:fastestmirror, langpacks
正在检查 rabbitmq-server-3.8.14-1.el8.noarch.rpm: rabbitmq-server-3.8.14-1.el8.noarch
rabbitmq-server-3.8.14-1.el8.noarch.rpm 将被安装
正在解决依赖关系
--> 正在检查事务
---> 软件包 rabbitmq-server.noarch.0.3.8.14-1.el8 将被 安装
--> 正在处理依赖关系 socat,它被软件包 rabbitmq-server-3.8.14-1.el8.noarch 需要
rabbitmq_erlang-source/signature | 819 B 00:00:00
rabbitmq_erlang-source/signature | 951 B 00:00:00 !!!
rbbitmq_erlang/x86_64/signature | 833 B 00:00:00
rbbitmq_erlang/x86_64/signature | 1.0 kB 00:00:00 !!!
Loading mirror speeds from cached hostfile
* base: mirrors.ustc.edu.cn
* extras: mirrors.ustc.edu.cn
* updates: mirrors.ustc.edu.cn
--> 正在检查事务
---> 软件包 socat.x86_64.0.1.7.3.2-2.el7 将被 安装
--> 解决依赖关系完成
依赖关系解决
============================================================================================================================================
Package 架构 版本 源 大小
============================================================================================================================================
正在安装:
rabbitmq-server noarch 3.8.14-1.el8 /rabbitmq-server-3.8.14-1.el8.noarch 16 M
为依赖而安装:
socat x86_64 1.7.3.2-2.el7 base 290 k
事务概要
============================================================================================================================================
安装 1 软件包 (+1 依赖软件包)
总计:16 M
总下载量:290 k
安装大小:17 M
Is this ok [y/d/N]: y
Is this ok [y/d/N]: y
Downloading packages:
警告:/var/cache/yum/x86_64/7/base/packages/socat-1.7.3.2-2.el7.x86_64.rpm: 头V3 RSA/SHA256 Signature, 密钥 ID f4a80eb5: NOKEY
socat-1.7.3.2-2.el7.x86_64.rpm 的公钥尚未安装
socat-1.7.3.2-2.el7.x86_64.rpm | 290 kB 00:00:00
从 file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-7 检索密钥
导入 GPG key 0xF4A80EB5:
用户ID : "CentOS-7 Key (CentOS 7 Official Signing Key)
指纹 : 6341 ab27 53d7 8a78 a7c2 7bb1 24c6 a8a7 f4a8 0eb5
软件包 : centos-release-7-4.1708.el7.centos.x86_64 (@anaconda)
来自 : /etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-7
是否继续?[y/N]:y
Running transaction check
Running transaction test
Transaction test succeeded
Running transaction
正在安装 : socat-1.7.3.2-2.el7.x86_64 1/2
正在安装 : rabbitmq-server-3.8.14-1.el8.noarch 2/2
验证中 : socat-1.7.3.2-2.el7.x86_64 1/2
验证中 : rabbitmq-server-3.8.14-1.el8.noarch 2/2
已安装:
rabbitmq-server.noarch 0:3.8.14-1.el8
作为依赖被安装:
socat.x86_64 0:1.7.3.2-2.el7
完毕!
[root@localhost david]# systemctl status rabbitmq-server.service
● rabbitmq-server.service - RabbitMQ broker
Loaded: loaded (/usr/lib/systemd/system/rabbitmq-server.service; disabled; vendor preset: disabled)
Active: inactive (dead)
[root@localhost david]# systemctl start rabbitmq-server
[root@localhost david]# systemctl enable rabbitmq-server
Created symlink from /etc/systemd/system/multi-user.target.wants/rabbitmq-server.service to /usr/lib/systemd/system/rabbitmq-server.service.
[root@localhost david]# systemctl status rabbitmq-server
● rabbitmq-server.service - RabbitMQ broker
Loaded: loaded (/usr/lib/systemd/system/rabbitmq-server.service; enabled; vendor preset: disabled)
Active: active (running) since 日 2021-03-28 09:45:33 CST; 19s ago
Main PID: 51486 (beam.smp)
Status: "Initialized"
CGroup: /system.slice/rabbitmq-server.service
├─51486 /usr/lib64/erlang/erts-11.2/bin/beam.smp -W w -MBas ageffcbf -MHas ageffcbf -MBlmbcs 512 -MHlmbcs 512 -MMmcs 30 -P 104...
├─51505 erl_child_setup 32768
├─51532 /usr/lib64/erlang/erts-11.2/bin/epmd -daemon
├─51557 inet_gethost 4
└─51558 inet_gethost 4
3月 28 09:45:24 localhost.localdomain rabbitmq-server[51486]: ########## Licensed under the MPL 2.0. Website: https://rabbitmq.com
3月 28 09:45:24 localhost.localdomain rabbitmq-server[51486]: Doc guides: https://rabbitmq.com/documentation.html
3月 28 09:45:24 localhost.localdomain rabbitmq-server[51486]: Support: https://rabbitmq.com/contact.html
3月 28 09:45:24 localhost.localdomain rabbitmq-server[51486]: Tutorials: https://rabbitmq.com/getstarted.html
3月 28 09:45:24 localhost.localdomain rabbitmq-server[51486]: Monitoring: https://rabbitmq.com/monitoring.html
3月 28 09:45:24 localhost.localdomain rabbitmq-server[51486]: Logs: /var/log/rabbitmq/[email protected]
3月 28 09:45:24 localhost.localdomain rabbitmq-server[51486]: /var/log/rabbitmq/rabbit@localhost_upgrade.log
3月 28 09:45:24 localhost.localdomain rabbitmq-server[51486]: Config file(s): (none)
3月 28 09:45:33 localhost.localdomain rabbitmq-server[51486]: Starting broker... completed with 0 plugins.
3月 28 09:45:33 localhost.localdomain systemd[1]: Started RabbitMQ broker.
[root@localhost david]# lsof -i:5672
COMMAND PID USER FD TYPE DEVICE SIZE/OFF NODE NAME
beam.smp 51486 rabbitmq 93u IPv6 112791 0t0 TCP *:amqp (LISTEN)
[root@localhost david]# ps aux | grep rabbitmq
rabbitmq 51486 11.9 3.9 2677744 74672 ? Ssl 09:45 0:12 /usr/lib64/erlang/erts-11.2/bin/beam.smp -W w -MBas ageffcbf -MHas ageffcbf -MBlmbcs 512 -MHlmbcs 512 -MMmcs 30 -P 1048576 -t 5000000 -stbt db -zdbbl 128000 -sbwt none -sbwtdcpu none -sbwtdio none -- -root /usr/lib64/erlang -progname erl -- -home /var/lib/rabbitmq -- -pa -noshell -noinput -s rabbit boot -boot start_sasl -lager crash_log false -lager handlers []
rabbitmq 51505 0.0 0.0 4308 548 ? Ss 09:45 0:00 erl_child_setup 32768
rabbitmq 51532 0.0 0.0 44604 508 ? S 09:45 0:00 /usr/lib64/erlang/erts-11.2/bin/epmd -daemon
rabbitmq 51557 0.0 0.0 11544 444 ? Ss 09:45 0:00 inet_gethost 4
rabbitmq 51558 0.0 0.0 13668 672 ? S 09:45 0:00 inet_gethost 4
root 51708 0.0 0.0 112676 984 pts/0 S+ 09:47 0:00 grep --color=auto rabbitmq
[root@localhost david]# rabbitmqctl status
Status of node rabbit@localhost ...
Runtime
OS PID: 51486
OS: Linux
Uptime (seconds): 123
Is under maintenance?: false
RabbitMQ version: 3.8.14
Node name: rabbit@localhost
Erlang configuration: Erlang/OTP 23 [erts-11.2] [source] [64-bit] [smp:4:4] [ds:4:4:10] [async-threads:1] [hipe]
Erlang processes: 282 used, 1048576 limit
Scheduler run queue: 1
Cluster heartbeat timeout (net_ticktime): 60
Plugins
Enabled plugin file: /etc/rabbitmq/enabled_plugins
Enabled plugins:
Data directory
Node data directory: /var/lib/rabbitmq/mnesia/rabbit@localhost
Raft data directory: /var/lib/rabbitmq/mnesia/rabbit@localhost/quorum/rabbit@localhost
Config files
Log file(s)
* /var/log/rabbitmq/[email protected]
* /var/log/rabbitmq/rabbit@localhost_upgrade.log
Alarms
(none)
Memory
Total memory used: 0.0858 gb
Calculation strategy: rss
Memory high watermark setting: 0.4 of available memory, computed to: 0.7647 gb
other_proc: 0.0298 gb (34.6 %)
code: 0.0251 gb (29.19 %)
other_system: 0.0137 gb (15.91 %)
allocated_unused: 0.0121 gb (14.07 %)
other_ets: 0.0029 gb (3.43 %)
atom: 0.0014 gb (1.6 %)
plugins: 0.0005 gb (0.54 %)
metrics: 0.0002 gb (0.25 %)
binary: 0.0002 gb (0.22 %)
mnesia: 0.0001 gb (0.11 %)
quorum_ets: 0.0 gb (0.06 %)
msg_index: 0.0 gb (0.03 %)
connection_channels: 0.0 gb (0.0 %)
connection_other: 0.0 gb (0.0 %)
connection_readers: 0.0 gb (0.0 %)
connection_writers: 0.0 gb (0.0 %)
mgmt_db: 0.0 gb (0.0 %)
queue_procs: 0.0 gb (0.0 %)
queue_slave_procs: 0.0 gb (0.0 %)
quorum_queue_procs: 0.0 gb (0.0 %)
reserved_unallocated: 0.0 gb (0.0 %)
File Descriptors
Total: 2, limit: 32671
Sockets: 0, limit: 29401
Free Disk Space
Low free disk space watermark: 0.05 gb
Free disk space: 45.3787 gb
Totals
Connection count: 0
Queue count: 0
Virtual host count: 1
Listeners
Interface: [::], port: 25672, protocol: clustering, purpose: inter-node and CLI tool communication
Interface: [::], port: 5672, protocol: amqp, purpose: AMQP 0-9-1 and AMQP 1.0
[root@localhost david]# rabbitmqctl
Usage
rabbitmqctl [--node
Available commands:
Help:
autocomplete Provides command name autocomplete variants
help Displays usage information for a command
version Displays CLI tools version
Nodes:
await_startup Waits for the RabbitMQ application to start on the target node
reset Instructs a RabbitMQ node to leave the cluster and return to its virgin state
rotate_logs Instructs the RabbitMQ node to perform internal log rotation
shutdown Stops RabbitMQ and its runtime (Erlang VM). Monitors progress for local nodes. Does not require a PID file path.
start_app Starts the RabbitMQ application but leaves the runtime (Erlang VM) running
stop Stops RabbitMQ and its runtime (Erlang VM). Requires a local node pid file path to monitor progress.
stop_app Stops the RabbitMQ application, leaving the runtime (Erlang VM) running
wait Waits for RabbitMQ node startup by monitoring a local PID file. See also 'rabbitmqctl await_online_nodes'
Cluster:
await_online_nodes Waits for
change_cluster_node_type Changes the type of the cluster node
cluster_status Displays all the nodes in the cluster grouped by node type, together with the currently running nodes
force_boot Forces node to start even if it cannot contact or rejoin any of its previously known peers
force_reset Forcefully returns a RabbitMQ node to its virgin state
forget_cluster_node Removes a node from the cluster
join_cluster Instructs the node to become a member of the cluster that the specified node is in
rename_cluster_node Renames cluster nodes in the local database
update_cluster_nodes Instructs a cluster member node to sync the list of known cluster members from
Replication:
cancel_sync_queue Instructs a synchronising mirrored queue to stop synchronising itself
sync_queue Instructs a mirrored queue with unsynchronised mirrors (follower replicas) to synchronise them
Users:
add_user Creates a new user in the internal database. This user will have no permissions for any virtual hosts by default.
authenticate_user Attempts to authenticate a user. Exits with a non-zero code if authentication fails.
change_password Changes the user password
clear_password Clears (resets) password and disables password login for a user
clear_user_limits Clears user connection/channel limits
delete_user Removes a user from the internal database. Has no effect on users provided by external backends such as LDAP
list_user_limits Displays configured user limits
list_users List user names and tags
set_user_limits Sets user limits
set_user_tags Sets user tags
Access Control:
clear_permissions Revokes user permissions for a vhost
clear_topic_permissions Clears user topic permissions for a vhost or exchange
list_permissions Lists user permissions in a virtual host
list_topic_permissions Lists topic permissions in a virtual host
list_user_permissions Lists permissions of a user across all virtual hosts
list_user_topic_permissions Lists user topic permissions
list_vhosts Lists virtual hosts
set_permissions Sets user permissions for a vhost
set_topic_permissions Sets user topic permissions for an exchange
Monitoring, observability and health checks:
list_bindings Lists all bindings on a vhost
list_channels Lists all channels in the node
list_ciphers Lists cipher suites supported by encoding commands
list_connections Lists AMQP 0.9.1 connections for the node
list_consumers Lists all consumers for a vhost
list_exchanges Lists exchanges
list_hashes Lists hash functions supported by encoding commands
list_node_auth_attempt_stats Lists authentication attempts on the target node
list_queues Lists queues and their properties
list_unresponsive_queues Tests queues to respond within timeout. Lists those which did not respond
ping Checks that the node OS process is up, registered with EPMD and CLI tools can authenticate with it
report Generate a server status report containing a concatenation of all server status information for support purposes
schema_info Lists schema database tables and their properties
status Displays status of a node
Parameters:
clear_global_parameter Clears a global runtime parameter
clear_parameter Clears a runtime parameter.
list_global_parameters Lists global runtime parameters
list_parameters Lists runtime parameters for a virtual host
set_global_parameter Sets a runtime parameter.
set_parameter Sets a runtime parameter.
Policies:
clear_operator_policy Clears an operator policy
clear_policy Clears (removes) a policy
list_operator_policies Lists operator policy overrides for a virtual host
list_policies Lists all policies in a virtual host
set_operator_policy Sets an operator policy that overrides a subset of arguments in user policies
set_policy Sets or updates a policy
Virtual hosts:
add_vhost Creates a virtual host
clear_vhost_limits Clears virtual host limits
delete_vhost Deletes a virtual host
list_vhost_limits Displays configured virtual host limits
restart_vhost Restarts a failed vhost data stores and queues
set_vhost_limits Sets virtual host limits
trace_off
trace_on
Configuration and Environment:
decode Decrypts an encrypted configuration value
encode Encrypts a sensitive configuration value
environment Displays the name and value of each variable in the application environment for each running application
set_cluster_name Sets the cluster name
set_disk_free_limit Sets the disk_free_limit setting
set_log_level Sets log level in the running node
set_vm_memory_high_watermark Sets the vm_memory_high_watermark setting
Definitions:
export_definitions Exports definitions in JSON or compressed Erlang Term Format.
import_definitions Imports definitions in JSON or compressed Erlang Term Format.
Feature flags:
enable_feature_flag Enables a feature flag or all supported feature flags on the target node
list_feature_flags Lists feature flags
Operations:
close_all_connections Instructs the broker to close all connections for the specified vhost or entire RabbitMQ node
close_all_user_connections Instructs the broker to close all connections of the specified user
close_connection Instructs the broker to close the connection associated with the Erlang process id
eval Evaluates a snippet of Erlang code on the target node
eval_file Evaluates a file that contains a snippet of Erlang code on the target node
exec Evaluates a snippet of Elixir code on the CLI node
force_gc Makes all Erlang processes on the target node perform/schedule a full sweep garbage collection
resume_listeners Resumes client connection listeners making them accept client connections again
suspend_listeners Suspends client connection listeners so that no new client connections are accepted
Queues:
delete_queue Deletes a queue
purge_queue Purges a queue (removes all messages in it)
Deprecated:
hipe_compile DEPRECATED. This command is a no-op. HiPE is no longer supported by modern Erlang versions
node_health_check DEPRECATED. Performs intrusive, opinionated health checks on a fully booted node. See https://www.rabbitmq.com/monitoring.html#health-checks instead
Use 'rabbitmqctl help
[root@localhost david]# rabbitmq-plugins enable rabbitmq_management
Enabling plugins on node rabbit@localhost:
rabbitmq_management
The following plugins have been configured:
rabbitmq_management
rabbitmq_management_agent
rabbitmq_web_dispatch
Applying plugin configuration to rabbit@localhost...
The following plugins have been enabled:
rabbitmq_management
rabbitmq_management_agent
rabbitmq_web_dispatch
started 3 plugins.
[root@localhost david]# netstat -a -n |grep 15672
tcp 0 0 0.0.0.0:15672 0.0.0.0:* LISTEN
[root@localhost david]# ifconfig
添加远程管理账号:
[root@localhost rabbitmq]# rabbitmqctl add_user test test
Adding user "test" ...
Done. Don't forget to grant the user permissions to some virtual hosts! See 'rabbitmqctl help set_permissions' to learn more.
RabbitMQ的角色:Admin | Monitoring | Policymaker|Management | Impersonator | None
[root@localhost rabbitmq]# rabbitmqctl set_user_tags test administrator
Setting tags for user "test" to [administrator] ...
[root@localhost rabbitmq]# rabbitmqctl set_permissions -p / test ".*" ".*" ".*"
Setting permissions for user "test" in vhost "/" ...
[root@localhost rabbitmq]# rabbitmq-plugins enable rabbitmq_mqtt
Enabling plugins on node rabbit@localhost:
rabbitmq_mqtt
The following plugins have been configured:
rabbitmq_management
rabbitmq_management_agent
rabbitmq_mqtt
rabbitmq_web_dispatch
Applying plugin configuration to rabbit@localhost...
The following plugins have been enabled:
rabbitmq_mqtt
started 1 plugins.
[root@localhost rabbitmq]# netstat -anp |grep 1883
tcp6 0 0 :::1883 :::* LISTEN 51486/beam.smp
成功连接
http://192.168.0.105:15672/#/