1:安装依赖
yum -y install gcc glibc-devel make ncurses-devel openssl-devel xmlto perl wget
2.下载对应版本的Erlang
wget http://erlang.org/download/otp_src_24.0.tar.gz
3.解压编译安装
tar -zxvf otp_src_24.0.tar.gz
cd otp_src_21.3
./configure --prefix=/usr/local/erlang
make && make install
4:配置环境变量
vim /etc/profile
export PATH=$PATH:/usr/local/erlang/bin
5:编译生效
source /etc/profile
输入erl,会出现版本信息,即安装成功
下载rabbitmq
https://github.com/rabbitmq/rabbitmq-server/releases/tag/v3.8.16
解压:
xz -d rabbitmq-server-generic-unix-3.8.16.tar.xz
tar -xvf rabbitmq-server-generic-unix-3.8.16.tar
export PATH=$PATH:/usr/local/rabbitmq_server-3.8.16/sbin
编译生效
source /etc/profile
启动
cd /usr/local/rabbitmq_server-3.8.16/sbin
./rabbitmq-server start
#后台启动
./rabbitmq-server -detached
因为guest用户只能在本机访问,添加一个admin用户,密码也是admin
./rabbitmqctl add_user admin admin
./rabbitmqctl set_user_tags admin administrator
./rabbitmqctl set_permissions -p / admin ".*" ".*" ".*"
#启用管理插件
./rabbitmq-plugins enable rabbitmq_management
访问:http://虚拟机IP:15672 (记得配置防火墙开通端口 或者 关掉防火墙)
centeros安装rabbitmq
最新推荐文章于 2024-09-22 14:32:59 发布