CentOS7安装RabbitMQ

创建erlang.repo库

curl -s https://packagecloud.io/install/repositories/rabbitmq/erlang/script.rpm.sh | sudo bash

安装erlang

yum install erlang

创建rabbitmq-server.repo库

curl -s https://packagecloud.io/install/repositories/rabbitmq/rabbitmq-server/script.rpm.sh | sudo bash

安装rabbitmq-server

yum install rabbitmq-server

设置开机启动

chkconfig rabbitmq-server on

启动rabbitmq服务

service rabbitmq-server start

image

启用管理后台

rabbitmq-plugins enable rabbitmq_management

添加用户

rabbitmqctl add_user test 123456

配置用户权限

rabbitmqctl set_user_tags test administrator
rabbitmqctl set_permissions -p "/" test ".*" ".*" ".*"

通过浏览器访问管理后台

image

image

停止rabbitmq服务

service rabbitmq-server stop

 

 

https://cloud.tencent.com/developer/article/1447179