上一篇提到了,若是經過系統默認的源安裝的rabbitmq一般不是最新的,好比我在作測試的時候,rabbitmq的版本已是3.7.7(http://www.rabbitmq.com),而我經過系統默認源安裝獲得的rabbitmq的版本是3.5.7html
兩種方法安裝到新版本的rabbitmqnode
1. 經過增長rabbitmq的源到系統的倉庫裏面bash
2. 下載發行包本身安裝app
第一種方式是rabbitmq推薦的: http://www.rabbitmq.com/install-debian.html#bintray-apt-repo-erlangionic
首先讓咱們的系統信任咱們要增長的源:測試
wget -O - 'https://dl.bintray.com/rabbitmq/Keys/rabbitmq-release-signing-key.asc' | sudo apt-key add -
增長erlang和rabbitmq源:server
echo "deb https://dl.bintray.com/rabbitmq/debian bionic main erlang" | sudo tee /etc/apt/sources.list.d/bintray.rabbitmq.list
源更新事後要運行:htm
apt-get update
卸載erlang rabbitmq(若是以前安裝過的話):blog
apt-get remove rabbitmq apt-get purge erlang apt-get autoremove
從新安裝erlang 和 rabbitmq:rabbitmq
apt-get install erlang apt-get install rabbitmq-server
再檢查rabbitmq的版本:
rabbitmqctl status
已是最新版本的3.7.7
root@iZuf6cdovpqjj6q2xqxrjlZ:/usr/lib# rabbitmqctl status Status of node rabbit@iZuf6cdovpqjj6q2xqxrjlZ ... [{pid,3167}, {running_applications, [{rabbit,"RabbitMQ","3.7.7"}, {mnesia,"MNESIA CXC 138 12","4.15.4"}, {rabbit_common, "Modules shared by rabbitmq-server and rabbitmq-erlang-client", "3.7.7"},