rabbitmq安装过程
第一次安装,居然有些麻烦,记录一下。
操作系统为ubuntu12.04
-
首先安装erlang环境
- 下载源码,otp-18
<pre>
wget http://erlang.org/download/otp_src_18.0.tar.gz
</pre> - 解压
<pre>
tar -zxf otp_src_18.0.tar.gz
</pre> - 进入解压完毕的文件夹
<pre>
cd otp_src_18.0
export ERL_TOP=pwd
./configure
make
make install
</pre>
- 下载源码,otp-18
-
下载deb包
- 进入rabbitmq下载官网,下载deb包
安装
<pre>
dpkg -i rabbitmq-server_3.6.0-1_all.deb
</pre>
出现错误提示
<pre>
Package erlang-nox is not installed.
Package esl-erlang is not installed.
</pre>-
安装erlang-nox
<pre>
apt-get install erlang-nox
</pre>
出现错误提示
<pre>
Reading state information... Done
You might want to run 'apt-get -f install' to correct these:
The following packages have unmet dependencies:
erlang-nox : Depends: erlang-base but it is not going to be installed or
erlang-base-hipe but it is not going to be installed
Depends: erlang-asn1 but it is not going to be installed
Depends: erlang-corba but it is not going to be installed
Depends: erlang-crypto but it is not going to be installed
Depends: erlang-diameter but it is not going to be installe
</pre>
于是按照提示执行
<pre>
apt-get -f install
</pre>
安装erlang-nox成功 -
安装esl-erlang
<pre>
apt-get install esl-erlang
</pre>
出现错误提示
<pre>
Reading package lists... Done
Building dependency tree
Reading state information... Done
Package esl-erlang is not available, but is referred to by another package.
This may mean that the package is missing, has been obsoleted, or
is only available from another source
E: Package 'esl-erlang' has no installation candidate
</pre>
于是解决“'esl-erlang' has no installation candidate”这个问题。- 编辑/etc/apt/sources.list,加入
<pre>
deb http://packages.erlang-solutions.com/ubuntu precise contrib
</pre> - then
<pre>
wget http://packages.erlang-solutions.com/ubuntu/erlang_solutions.asc
sudo apt-key add erlang_solutions.asc
sudo apt-get update
</pre> - 再次安装esl-erlang,
<pre>
apt-get install esl-erlang
</pre>
再次出现错误提示
<pre>
Reading state information... Done
You might want to run 'apt-get -f install' to correct these:
The following packages have unmet dependencies:
erlang-base : Conflicts: erlang-base-hipe
esl-erlang : Depends: libwxbase3.0-0 but it is not installable or
libwxbase2.8-0 but it is not going to be installed
Depends: libwxgtk3.0-0 but it is not installable or
libwxgtk2.8-0 but it is not going to be installed
</pre>- 安装提示,执行命令
<pre>
apt-get -f install
</pre>
安装成功
- 安装提示,执行命令
当"erlang-nox"和"esl-erlang"安装成功后,执行
<pre>
dpkg -i rabbitmq-server_3.6.0-1_all.deb
</pre>启动rabbitmq
<pre>
sudo service rabbitmq-server start
</pre>