码迷,mamicode.com
首页 > 其他好文 > 详细

centos7安装RabbitMQ

时间:2019-05-18 15:47:11      阅读:130      评论:0      收藏:0      [点我收藏+]

标签:rabbit   gem   mct   let   配置文件   mqc   details   ase   emctl   

1.安装运行环境 erlang

  rpm -Uvh http://www.rabbitmq.com/releases/erlang/erlang-18.1-1.el7.centos.x86_64.rpm

2.安装 rabbitmq-server

  rpm -Uvh http://www.rabbitmq.com/releases/rabbitmq-server/v3.5.6/rabbitmq-server-3.5.6-1.noarch.rpm

3.查看是否安装成功

  rpm -qa|grep erlang

  rpm -qa|grep rabbitmq

4.启动及常用命令

  systemctl start rabbitmq-server

  systemctl status rabbitmq-server

  systemctl stop rabbitmq-server

  systemctl restart rabbitmq-server

  rabbitmqctl status

  rabbitmqctl list_users

  rabbitmqctl add_user [user] [pwd] 

  rabbitmqctl delete_user [user]

5.安装 rabbitmq_management 管理插件

  rabbitmqct

  rabbitmq-plugins enable rabbitmq_management

6.开启远程访问

  添加 config 配置文件

    cd /etc/rabbitmq

    cp /usr/share/doc/rabbitmq-server-3.5.6/rabbitmq.config.example /etc/rabbitmq/

    mv rabbitmq.config.example rabbitmq.config

  添加  {loopback_users, []},找到“%%{loopback_users, []}, ”,在其下添加

    {loopback_users, []}

7.开放端口

  firewall-cmd --zone=public --add-port=5672/tcp --permanent

  firewall-cmd --zone=public --add-port=15672/tcp --permanent

  firewall-cmd --reload

  firewall-cmd --zone=public --query-port=5672/tcp

  firewall-cmd --zone=public --query-port=15672/tcp

 8.登陆访问

   http://ip:15672

 

 

 

参考文章:

  https://blog.csdn.net/zhuzhezhuzhe1/article/details/80464291

  https://www.cnblogs.com/zongyl/p/5913808.html

centos7安装RabbitMQ

标签:rabbit   gem   mct   let   配置文件   mqc   details   ase   emctl   

原文地址:https://www.cnblogs.com/tarencez/p/10885810.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!