centos7安装rabbitmq-3.7.17

centos7安装rabbitmq-3.7.17

准备

访问rabbitmq官网下载页面: https://www.rabbitmq.com/download.html

centos7安装rabbitmq-3.7.17_第1张图片

安装erlang

找到安装erlang: https://www.rabbitmq.com/install-rpm.html#install-from-esl-repository:

centos7安装rabbitmq-3.7.17_第2张图片
即:https://www.erlang-solutions.com/resources/download.html:

centos7安装rabbitmq-3.7.17_第3张图片
安装:

wget https://packages.erlang-solutions.com/erlang/rpm/centos/7/x86_64/esl-erlang_22.0.7-1~centos~7_amd64.rpm

rpm -ivh esl-erlang_22.0.7-1~centos~7_amd64.rpm

安装rabbitmq

https://www.rabbitmq.com/install-rpm.html#downloads:

centos7安装rabbitmq-3.7.17_第4张图片

wget https://github.com/rabbitmq/rabbitmq-server/releases/download/v3.7.17/rabbitmq-server-3.7.17-1.el7.noarch.rpm

rpm -ivh rabbitmq-server-3.7.17-1.el7.noarch.rpm
## 可能需要先安装!!
yum install socat

启动rabbitmq

1.开机启动:

chkconfig rabbitmq-server on

2.查看启动状态:

rabbitmqctl status

3.启动,关闭,重启:

systemctl start rabbitmq-server.service
systemctl stop rabbitmq-server.service
systemctl restart rabbitmq-server.service

启动web管理台

rabbitmq-plugins enable rabbitmq_management

访问: http://192.168.93.129:15672,默认用户:guest/guest,但登陆时显示User can only log in via localhost!!!

解决方案

找到文件/usr/lib/rabbitmq/lib/rabbitmq_server-3.7.17/ebin/rabbit.app:

{loopback_users, [<<"guest">>]},

改为{loopback_users, []},

然后重启服务即可:

systemctl restart rabbitmq-server.service

你可能感兴趣的:(rabbitmq)