美文网首页
安装rabbitmq

安装rabbitmq

作者: Jetsly | 来源:发表于2016-12-19 09:49 被阅读967次

    安装

    1.下载安装erlang

    $ sudo yum install erlang -y
    

    2.下载安装rpm

    $ sudo rpm --import https://www.rabbitmq.com/rabbitmq-signing-key-public.asc
    $ sudo yum install https://github.com/rabbitmq/rabbitmq-server/releases/download/rabbitmq_v3_5_4/rabbitmq-server-3.5.4-1.noarch.rpm -y
    

    3.配置SELinux

    $ sudo yum install setroubleshoot -y
    $ sudo semodule -l|grep rabbitmq
    $ sudo audit2allow -a
    $ sudo grep beam /var/log/audit/audit.log|audit2allow -M rabbitmq_beam_t
    $ sudo semodule -i rabbitmq_beam_t.pp
    $ sudo semodule -r rabbitmq_beam_t
    $ sudo audit2allow -a
    $ sudo grep beam /var/log/audit/audit.log|audit2allow -M rabbitmq_beam_t
    $ sudo semodule -i rabbitmq_beam_t.pp
    

    4.启动服务

    $ sudo systemctl start rabbitmq-server
    

    5.启用插件

    $  sudo rabbitmq-plugins  enable rabbitmq_management
    

    6.配置防火墙

    $ sudo firewall-cmd --permanent --add-port=5672/tcp
    $ sudo firewall-cmd --permanent --add-port=15672/tcp
    $ sudo firewall-cmd --reload
    $ sudo firewall-cmd --list-all
    

    7.添加用户

    $ sudo rabbitmqctl add_user mintcode 123456
    $ sudo rabbitmqctl set_user_tags mintcode administrator
    

    错误

    1.ERROR: distribution port 25672 in use on localhost (by non-Erlang process?)

    没有配置 SELinux

    相关文章

      网友评论

          本文标题:安装rabbitmq

          本文链接:https://www.haomeiwen.com/subject/gmzzmttx.html