一、windows 上下载依赖文件以及安装文件
https://d28dx6y1hfq314.cloudfront.net/828/1033/el/7/package_files/1305009.rpm?t=1694767188_8bd28780066a52b94cc2edfb2b7f574333d72318
https://d28dx6y1hfq314.cloudfront.net/828/1039/el/7/package_files/1038460.rpm?t=1694767132_8b19990c49052cb3361c3508e0ba750b972b19b7
二、将下载后的文件上传至服务器
三、安装 erlang和 rabbitmq
首先安装 erlang ,安装成功之后才安装 rabbitmq
yum localinstall erlang-22.3.4.12-1.el7.x86_64.rpm
rpm --import https://www.rabbitmq.com/rabbitmq-release-signing-key.asc
yum localinstall rabbitmq-server-3.8.13-1.el7.noarch.rpm
如果安装erlang出现以下错误说明之前安装过,先进行删除,其中 package 之后的代表是版本 需要进行删除
Transaction check error:
file /usr/lib64/erlang/bin/epmd from install of erlang-22.3.4.12-1.el7.x86_64 conflicts with file from package erlang-erts-R16B-03.18.el7.x86_64
file /usr/lib64/erlang/bin/erl from install of erlang-22.3.4.12-1.el7.x86_64 conflicts with file from package erlang-erts-R16B-03.18.el7.x86_64
file /usr/lib64/erlang/bin/erlc from install of erlang-22.3.4.12-1.el7.x86_64 conflicts with file from package erlang-erts-R16B-03.18.el7.x86_64
file /usr/lib64/erlang/bin/escript from install of erlang-22.3.4.12-1.el7.x86_64 conflicts with file from package erlang-erts-R16B-03.18.el7.x86_64
file /usr/lib64/erlang/bin/run_erl from install of erlang-22.3.4.12-1.el7.x86_64 conflicts with file from package erlang-erts-R16B-03.18.el7.x86_64
file /usr/lib64/erlang/bin/to_erl from install of erlang-22.3.4.12-1.el7.x86_64 conflicts with file from package erlang-erts-R16B-03.18.el7.x86_64
file /usr/lib64/erlang/bin/no_dot_erlang.boot from install of erlang-22.3.4.12-1.el7.x86_64 conflicts with file from package erlang-erts-R16B-03.18.el7.x86_64
file /usr/lib64/erlang/bin/start from install of erlang-22.3.4.12-1.el7.x86_64 conflicts with file from package erlang-erts-R16B-03.18.el7.x86_64
file /usr/lib64/erlang/bin/start.boot from install of erlang-22.3.4.12-1.el7.x86_64 conflicts with file from package erlang-erts-R16B-03.18.el7.x86_64
file /usr/lib64/erlang/bin/start.script from install of erlang-22.3.4.12-1.el7.x86_64 conflicts with file from package erlang-erts-R16B-03.18.el7.x86_64
file /usr/lib64/erlang/bin/start_clean.boot from install of erlang-22.3.4.12-1.el7.x86_64 conflicts with file from package erlang-erts-R16B-03.18.el7.x86_64
file /usr/lib64/erlang/bin/start_erl from install of erlang-22.3.4.12-1.el7.x86_64 conflicts with file from package erlang-erts-R16B-03.18.el7.x86_64
file /usr/lib64/erlang/bin/start_sasl.boot from install of erlang-22.3.4.12-1.el7.x86_64 conflicts with file from package erlang-erts-R16B-03.18.el7.x86_64
file /usr/lib64/erlang/usr/include/driver_int.h from install of erlang-22.3.4.12-1.el7.x86_64 conflicts with file from package erlang-erts-R16B-03.18.el7.x86_64
file /usr/lib64/erlang/usr/include/erl_driver.h from install of erlang-22.3.4.12-1.el7.x86_64 conflicts with file from package erlang-erts-R16B-03.18.el7.x86_64
file /usr/lib64/erlang/usr/include/erl_drv_nif.h from install of erlang-22.3.4.12-1.el7.x86_64 conflicts with file from package erlang-erts-R16B-03.18.el7.x86_64
file /usr/lib64/erlang/usr/include/erl_fixed_size_int_types.h from install of erlang-22.3.4.12-1.el7.x86_64 conflicts with file from package erlang-erts-R16B-03.18.el7.x86_64
file /usr/lib64/erlang/usr/include/erl_int_sizes_config.h from install of erlang-22.3.4.12-1.el7.x86_64 conflicts with file from package erlang-erts-R16B-03.18.el7.x86_64
file /usr/lib64/erlang/usr/include/erl_memory_trace_parser.h from install of erlang-22.3.4.12-1.el7.x86_64 conflicts with file from package erlang-erts-R16B-03.18.el7.x86_64
file /usr/lib64/erlang/usr/include/erl_nif.h from install of erlang-22.3.4.12-1.el7.x86_64 conflicts with file from package erlang-erts-R16B-03.18.el7.x86_64
file /usr/lib64/erlang/usr/include/erl_nif_api_funcs.h from install of erlang-22.3.4.12-1.el7.x86_64 conflicts with file from package erlang-erts-R16B-03.18.el7.x86_64
file /usr/lib64/erlang/usr/lib/liberts.a from install of erlang-22.3.4.12-1.el7.x86_64 conflicts with file from package erlang-erts-R16B-03.18.el7.x86_64
file /usr/lib64/erlang/usr/lib/liberts_r.a from install of erlang-22.3.4.12-1.el7.x86_64 conflicts with file from package erlang-erts-R16B-03.18.el7.x86_64
file /usr/lib64/erlang/usr/include/ei.h from install of erlang-22.3.4.12-1.el7.x86_64 conflicts with file from package erlang-erts-R16B-03.18.el7.x86_64
file /usr/lib64/erlang/usr/include/ei_connect.h from install of erlang-22.3.4.12-1.el7.x86_64 conflicts with file from package erlang-erts-R16B-03.18.el7.x86_64
file /usr/lib64/erlang/usr/include/eicode.h from install of erlang-22.3.4.12-1.el7.x86_64 conflicts with file from package erlang-erts-R16B-03.18.el7.x86_64
file /usr/lib64/erlang/usr/include/erl_interface.h from install of erlang-22.3.4.12-1.el7.x86_64 conflicts with file from package erlang-erts-R16B-03.18.el7.x86_64
file /usr/lib64/erlang/usr/lib/libei.a from install of erlang-22.3.4.12-1.el7.x86_64 conflicts with file from package erlang-erts-R16B-03.18.el7.x86_64
file /usr/lib64/erlang/usr/lib/libei_st.a from install of erlang-22.3.4.12-1.el7.x86_64 conflicts with file from package erlang-erts-R16B-03.18.el7.x86_64
file /usr/lib64/erlang/usr/lib/liberl_interface.a from install of erlang-22.3.4.12-1.el7.x86_64 conflicts with file from package erlang-erts-R16B-03.18.el7.x86_64
file /usr/lib64/erlang/usr/lib/liberl_interface_st.a from install of erlang-22.3.4.12-1.el7.x86_64 conflicts with file from package erlang-erts-R16B-03.18.el7.x86_64
file /usr/lib64/erlang/releases/RELEASES from install of erlang-22.3.4.12-1.el7.x86_64 conflicts with file from package erlang-erts-R16B-03.18.el7.x86_64
file /usr/lib64/erlang/releases/RELEASES.src from install of erlang-22.3.4.12-1.el7.x86_64 conflicts with file from package erlang-erts-R16B-03.18.el7.x86_64
file /usr/lib64/erlang/releases/start_erl.data from install of erlang-22.3.4.12-1.el7.x86_64 conflicts with file from package erlang-erts-R16B-03.18.el7.x86_64
Error Summary
删除之前的 erlang 版本 ,之后再继续执行上面的安装教程
yum remove erlang-22.3.4.12-1.el7.x86_64 # 这个版本号换成上面package 之后的那个
四 RabbitMQ Web界面管理
rabbitmq-plugins enable rabbitmq_management
五、启动 mq 服务设置开机启动
systemctl restart rabbitmq-server
systemctl enable rabbitmq-server
六、放开防火墙端口、添加登录账户 并访问
firewall-cmd --zone=public --add-port=15672/tcp --permanent
firewall-cmd --zone=public --add-port=5672/tcp --permanent
systemctl restart firewalld
# 添加账户 guest 和 admin 都存在了的
rabbitmqctl add_user 用户名 密码
# 设置用户分配操作权限。
rabbitmqctl set_user_tags 用户 administrator