centos7安装rabbitmq

rabbitmq用erlang开发的,先装这东西

依次执行

yum install -y epel-release

wget https://packages.erlang-solutions.com/erlang-solutions-1.0-1.noarch.rpm

rpm -Uvh erlang-solutions-1.0-1.noarch.rpm

yum install -y erlang

验证安装成功

erl -version

对应版本

 

 

 

 

 

 看上去好像有点不一样。。。

yum list installed

 

 

 没问题了,上述命令会安装最新版本,如果版本低了可删除

yum -y remove erlang*

---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

根据对应版本安装rabbitmq(转自:https://www.cnblogs.com/LiuFqiang/p/13791026.html)

运行下载安装npm包
wget http://www.rabbitmq.com/releases/rabbitmq-server/v3.8.14/rabbitmq-server-3.8.14-1.el7.noarch.rpm

通过运行导入GPG密钥
rpm –import https://www.rabbitmq.com/rabbitmq-release-signing-key.asc

运行rpm包
rpm -Uvh rabbitmq-server-3.8.14-1.el7.noarch.rpm

安装完成,启动RabbitMQ
systemctl start rabbitmq-server

设置开启自启动
systemctl enable rabbitmq-server

查看RabbitMQ运行启动状态
systemctl status rabbitmq-server

启用管理后台
rabbitmq-plugins enable rabbitmq_management

配置权限
chown -R rabbitmq:rabbitmq /var/lib/rabbitmq/

增加用户
rabbitmqctl add_user admin admin

设置角色    
rabbitmqctl set_user_tags admin administrator

设置用户权限
rabbitmqctl set_permissions -p / admin '.*' '.*' '.*'

 

posted on 2021-03-11 00:17  MasterTumbler  阅读(41)  评论(0编辑  收藏  举报

导航