1.安装erlang
yum install erlang
如报错No package erlang available,需要安装EPEL库
1.安装wget
yum -y install wget
2.安装EPEL库
- 下载
wget http://dl.fedoraproject.org/pub/epel/6/x86_64/epel-release-6-8.noarch.rpm
- 安装
rpm -ivh epel-release-6-8.noarch.rpm
2.安装RabbitMQ rpm包
- 下载
wget http://www.rabbitmq.com/releases/rabbitmq-server/v3.5.0/rabbitmq-server-3.5.0-1.noarch.rpm
- 安装
rpm -ivh rabbitmq-server-3.5.0-1.noarch.rpm
3.启动rabbitmq,并验证启动情况
rabbitmq-server --detached &ps aux |grep rabbitmq
4.以服务的方式启动
service rabbitmq-server start
5.检查端口5672是否打开
/sbin/iptables -I INPUT -p tcp --dport 5672 -j ACCEPT
/etc/rc.d/init.d/iptables save
/etc/init.d/iptables restart
/etc/init.d/iptables status
6.启用维护插件
rabbitmq-plugins enable rabbitmq_management
7.重启RabbitMQ
service rabbitmq-server restart
8.访问UI界面
http://your ip:15672 用户名密码:guest
无法登陆解决:
vim /etc/rabbitmq/rabbitmq.config
写入信息,并保存
[{rabbit, [{loopback_users, []}]}].