-

Linux下RabbitMQ安装

Linux

MQ全称为Message Queue, 消息队列(MQ)是一种应用程序对应用程序的通信方法。应用程序通过读写出入队列的消息(针对应用程序的数据)来通信,而无需专用连接来链接它们。RabbitMQ是一个在AMQP基础上完整的,可复用的企业消息系统。这样的话,进行了异步处理,而这种异步处理的方式大大的节省了服务器的请求响应时间,从而提高了系统的吞吐量。

RabbitMQ安装相关知识点
1、安装Erlang
[cc lang=”bash” escaped=”true”][root@MQ ~]# rpm -Uvh http://download.fedoraproject.org/pub/epel/6/i386/epel-release-6-8.noarch.rpm
[root@MQ ~]# yum install erlang[/cc]

2、安装rabbitmq
[cc lang=”bash” escaped=”true”][root@MQ ~]# wget http://www.rabbitmq.com/releases/rabbitmq-server/v3.5.1/rabbitmq-server-3.5.1-1.noarch.rpm
[root@MQ ~]# rpm –import http://www.rabbitmq.com/rabbitmq-signing-key-public.asc
[root@MQ ~]# yum install rabbitmq-server-3.5.1-1.noarch.rpm[/cc]

3、启动rabbitmq
[cc lang=”bash” escaped=”true”][root@MQ ~]# service rabbitmq-server start[/cc]
4、rabbitmq-management plugin提供HTTP_API来管理和监控RabbitMQ Server,具体包含如下功能:
[cc lang=”bash” escaped=”true”][root@MQ ~]# rabbitmq-plugins enable rabbitmq_management  #web访问地址:http://server-name:15672[/cc]

5、登陆rabbitmq,failed
you need to create a user for any vhost on that system (here I use default vhost “/”)创建一个用户
[cc lang=”bash” escaped=”true”][root@MQ ~]# rabbitmqctl add_user yourName yourPass[/cc]

Set the permissions for that user for default vhost设置用户权限
[cc lang=”bash” escaped=”true”][root@MQ ~]# rabbitmqctl set_permissions -p / yourName “.*” “.*” “.*”[/cc]

Set the administrator tag for this user (to enable him access the management pluggin)设置超级管理员标签
[cc lang=”bash” escaped=”true”][root@MQ ~]# rabbitmqctl set_user_tags yourName administrator[/cc]

来源:Linux下RabbitMQ安装

Linux下RabbitMQ安装” 评论

    东方小说阅读网 评论:
    2019年5月10日 下午10:35

    先回复,再欣赏。

发表回复

您的电子邮箱地址不会被公开。 必填项已用 * 标注