环境: ubuntu 16.04
官网的安装向导请点击这里
rabbitmq依赖erlang 首先检查你的erlang版本,当然,最简单的方法是安装最新版本了.
sudo apt-get install erlang
如果系统提醒你
Unable to locate package erlang
那你就这么做
wget https://packages.erlang-solutions.com/erlang-solutions_1.0_all.deb
sudo dpkg -i erlang-solutions_1.0_all.deb
sudo apt-get update
sudo apt-get install erlang
下面开始安装rabbitmq-server
- 创建一个rabbitmq的源列表
echo "deb https://dl.bintray.com/rabbitmq/debian xenial main" | sudo tee /etc/apt/sources.list.d/bintray.rabbitmq.list
- 添加一个public_key
wget -O- https://dl.bintray.com/rabbitmq/Keys/rabbitmq-release-signing-key.asc | sudo apt-key add -
- 更新仓库
sudo apt-get update
- 安装rabbitmq的服务器
sudo apt-get install rabbitmq-server
安装完成后,建议重启一下.
然后 service rabbitmq-server status 查看rabbitmq服务器状态,正常的话,应该是下面的样子:
rabbitmq-server.service - RabbitMQ broker
Loaded: loaded (/lib/systemd/system/rabbitmq-server.service; enabled; vendor
Active: active (running) since Mon 2018-07-23 10:12:11 CST; 52s ago
Main PID: 1043 (beam.smp)
Status: "Initialized"
Tasks: 85
Memory: 78.6M
CPU: 9.017s
CGroup: /system.slice/rabbitmq-server.service
├─1043 /usr/lib/erlang/erts-10.0/bin/beam.smp -W w -A 64 -MBas ageffc
├─1218 /usr/lib/erlang/erts-10.0/bin/epmd -daemon
├─1363 erl_child_setup 1024
├─1380 inet_gethost 4
└─1381 inet_gethost 4
Jul 23 10:12:08 ubuntu-server rabbitmq-server[1043]: ## ##
Jul 23 10:12:08 ubuntu-server rabbitmq-server[1043]: ## ## RabbitMQ 3.7.
Jul 23 10:12:08 ubuntu-server rabbitmq-server[1043]: ########## Licensed unde
Jul 23 10:12:08 ubuntu-server rabbitmq-server[1043]: ###### ##
Jul 23 10:12:08 ubuntu-server rabbitmq-server[1043]: ########## Logs: /var/lo
Jul 23 10:12:08 ubuntu-server rabbitmq-server[1043]: /var/lo
Jul 23 10:12:08 ubuntu-server rabbitmq-server[1043]: Starting brok
...skipping...
SUMMARY OF LESS COMMANDS
Commands marked with * may be preceded by a number, N.
Notes in parentheses indicate the behavior if N is given.
A key preceded by a caret indicates the Ctrl key; thus ^K is ctrl-K.
h H Display this help.
q :q Q :Q ZZ Exit.
---------------------------------------------------------------------------
MOVING
e ^E j ^N CR * Forward one line (or N lines).
y ^Y k ^K ^P * Backward one line (or N lines).
f ^F ^V SPACE * Forward one window (or N lines).
b ^B ESC-v * Backward one window (or N lines).
z * Forward one window (and set window to N).
w * Backward one window (and set window to N).
ESC-SPACE * Forward one window, but don't stop at end-of-file.
d ^D * Forward one half-window (and set half-window to N).
u ^U * Backward one half-window (and set half-window to N).
ESC-) RightArrow * Left one half screen width (or N positions).
HELP -- Press RETURN for more, or q when done