"RABBITMQ"--centos7 installation RABBITMQ Tutorial

Source: Internet
Author: User
Tags rabbitmq rabbitmq tutorial

Introduction

Message Queuing now applies a lot to the Internet project, and the next blog post will delve into the implementation of MQ, and in this blog I'll explain how to install MQ under CENTOS7 and the problems that are encountered.

First step: Install Erlang

Because RABBITMQ is written in Erlang language, we first need to install Erlang

     RPM-UVH http://www.rabbitmq.com/releases/erlang/erlang-18.1-1.el7.centos.x86_64.rpm
Step two, install Rabbitmq-server

The installation method provided by official website:

    RPM--import https://www.rabbitmq.com/rabbitmq-signing-key-public.asc
    Yum Install rabbitmq-server-3.5.6-1.noarch.rpm

I installed the successful way:

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

The third step, to see if the Rabbitmq-server has been installed, can be found that the instructions have been installed completed.

   Rpm-qa|grep RABBITMQ

Fourth step, open Rabbit-server

      Service Rabbitmq-server Start

Step fifth, turn off Rabbit-server (verify command)

Service Rabbitmq-server Stop

Sixth step, view status

Rabbitmqctl status



This way, although we've started the RABBITMQ service normally, we can't connect when we enter ip:15672 in the physical machine browser, because we haven't configured the maintenance plugin and turned on the remote connection yet.

Step seventh, install command maintenance plugin

Rabbitmq-plugins Enable Rabbitmq_management

Step eighth, set up profiles, and turn on user remote access


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

 #mv Rabbitmq.config.example Rabbitmq.config

Vi/etc/rabbitmq/rabbitmq.config


Step eighth, restart Rabbit-server service

Service Rabbitmq-server Restart

Step Nineth, login access

Enter ip:15672 in the browser to appear login page, username and password are guest

If all the above steps are very smooth, then congratulations you have been installed successfully. But I didn't go so well, and share some of the problems I've encountered.

Error message: The following error message appears after entering service rabbitmq-server start command

Job for Rabbitmq-server.service failed. ' Systemctl status Rabbitmq-server.service ' and ' journalctl-xn ' for details.

Solution:

Add 5672 ports to the firewall white list

Firewall-cmd--permanent--add-port=5672/tcp
Firewall-cmd--reload
Setsebool-p nis_enabled 1

The rough way is to shut down the firewall directly and close the SELinux

Systemctl Stop Firewalld

Setenforce 0

Error two, after the login page, enter the Guest account information, can not log in.

This is because we did not turn on remote user access, the solution that was listed in the previous steps and not repeated.

Summary

After these steps have been correctly installed RABBITMQ, small set in the installation encountered some problems, especially in centos6 above, encountered problems are not resolved, transferred to the CENTOS7 above, installation or relatively smooth, hereby record, I hope to help you.


Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.