Skip to main content

Centos7, RabbitMq quick installation

Centos7, RabbitMq quick installation

1. Install the Erlang environment

Erlang official website: [rabbitmq/erlang - Results for el/7 in rabbitmq/erlang (packagecloud.io)](https://packagecloud.io/app/rabbitmq/erlang/search?q=&filter=all&dist=el/7 "rabbitmq/erlang - Results for el/7 in rabbitmq/erlang (packagecloud.io)")

Centos7, RabbitMq quick installation

1. Enter the official website and click the installation package and enter two commands

    
2. curl -s https://packagecloud.io/install/repositories/rabbitmq/erlang/script.rpm.sh | sudo bash

3. # 安装erlang

4. sudo yum install erlang-23.3.4.11-1.el7.x86_64



2. Install rabbitMq

rabbitMq official website: rabbitmq/rabbitmq-server - Packages · packagecloud

Check the correspondence between Erlang and Rabbit versions, and determine the correspondence between the versions to be downloaded.

1. Execute official orders

    
2. curl -s https://packagecloud.io/install/repositories/rabbitmq/rabbitmq-server/script.rpm.sh | sudo bash

3. # 安装rabbit

4. sudo yum install rabbitmq-server-3.10.0-1.el7.noarch



2. Install mq plug-in

rabbitmq-plugins enable rabbitmq_management

Centos7, RabbitMq quick installation

3. Start mq

systemctl start rabbitmq-server

4. Check the running status

systemctl status rabbitmq-server

Centos7, RabbitMq quick installation

3. Create an account

1. Add admin user and set password rabbitmqctl add_user admin admin

2. Add the admin user to the administrator role rabbitmqctl set_user_tags admin administrator

3. Set the permissions of the admin user, specify the vhost and write/read allowed to access

rabbitmqctl set_permissions -p "/" admin "." "." ".*"

4. Check which users are allowed to access vhost (/) rabbitmqctl list_permissions -p /

5. View the user list rabbitmqctl list_users

Centos7, RabbitMq quick installation