springboot集成使用rabbitmq笔记(1.rabbitmq安装)

1.选择适配的版本,参考---https://www.rabbitmq.com/which-erlang.html

springboot集成使用rabbitmq笔记(1.rabbitmq安装)_第1张图片

2.下载rpm包---https://www.erlang-solutions.com/resources/download.html

  本人下载的是:esl-erlang_20.3.8.22-1_centos_7_amd64.rpm

3.安装包

yum -y install gcc
yum -y install gcc-c++
        
rpm -ivh esl-erlang_20.3.8.22-1_centos_7_amd64.rpm 

出现缺少依赖

error: Failed dependencies:
        libGL.so.1()(64bit) is needed by esl-erlang-19.3-1.x86_64
        libGLU.so.1()(64bit) is needed by esl-erlang-19.3-1.x86_64
        libodbc.so.2()(64bit) is needed by esl-erlang-19.3-1.x86_64
        ...................

安装依赖

yum install epel-release        
yum install unixODBC unixODBC-devel wxBase wxGTK SDL wxGTK-gl

再安装rpm包

rpm --import https://github.com/rabbitmq/signing-keys/releases/download/2.0/rabbitmq-release-signing-key.asc#

此示例假定包的CentOS 7版本

yum install rabbitmq-server-3.7.15-1.el7.noarch.rpm

4.启动

  启动RabbitMQ服务 systemctl start rabbitmq-server.service
  查看RabbitMQ服务状态 systemctl status rabbitmq-server.service
  启用插件 rabbitmq-plugins enable rabbitmq_management
  重启RabbitMQ服务 systemctl restart rabbitmq-server.service
  添加帐号密码:rabbitmqctl add_user 用户名 密码
  赋予其administrator角色 rabbitmqctl set_user_tags name administrator
  设置权限 rabbitmqctl set_permissions -p / name ".*" ".*" ".*"
  加入开机自启 systemctl enable rabbitmq-server.service或chkconfig rabbitmq-server on

若访问不了,可以关闭防火墙
systemctl stop firewalld.service
(systemctl disable firewalld.service)
(centos从7开始默认用的是firewalld,这个是基于iptables的,虽然有iptables的核心,但是iptables的服务是没安装的。)

 

转载于:https://www.cnblogs.com/lantuanqing/p/11288531.html

你可能感兴趣的:(springboot集成使用rabbitmq笔记(1.rabbitmq安装))