RabbitMQ 初级教程[0] - Mac下安装
原文参考:Downloading and Installing RabbitMQ - MacOS: Homebrew
安装Homebrew
参见:Homebrew
安装RabbitMQ
#自动升级homebrew brew update #安装RabbitMQ server brew install rabbitmq
安装完成后用brew info rabbitmq
检查信息:
rabbitmq: stable 3.7.3 Messaging broker https://www.rabbitmq.com /usr/local/Cellar/rabbitmq/3.7.2 (232 files, 12.6MB) * Built from source on 2018-01-02 at 09:45:16 From: https://github.com/Homebrew/homebrew-core/blob/master/Formula/rabbitmq.rb ==> Dependencies Required: erlang ✔ ==> Caveats Management Plugin enabled by default at http://localhost:15672 Bash completion has been installed to: /usr/local/etc/bash_completion.d To have launchd start rabbitmq now and restart at login: brew services start rabbitmq Or, if you don't want/need a background service you can just run: rabbitmq-server
- 默认安装地址:
/usr/local/sbin
- 默认用户名:
guest
,密码:guest
。(仅支持本地连接) - 默认 Virtual Host:
/
- 默认 TCP Listener:
127.0.0.1:5672
- 默认log:
/usr/local/var/log/rabbitmq/[email protected]
添加环境变量:
#用vi指令进入 vi ~/.bash_profile #添加环境变量 RABBITMQ_HOME=/usr/local/sbin PATH=$PATH:$RABBITMQ_HOME #保存退出 :wq #指令生效 source ~/.bash_profile
启动RabbitMQ
#直接启动 rabbitmq-server #后台启动 rabbitmq-server -detached #查询进程 ps -ef|grep rabbitmq #本地登录地址 http://localhost:15672 #关闭 rabbitmqctl stop #检查状态 rabbitmqctl status #默认日志 /usr/local/var/log/rabbitmq/[email protected]
用户管理(部分指令)
利用rabbitmqctl
管理 RabbitMQ 内部用户数据信息
- add_user username password
rabbitmqctl add_user tonyg changeit
- delete_user username
rabbitmqctl delete_user tonyg
- change_password username newpassword
rabbitmqctl delete_user tonyg
- clear_password username
rabbitmqctl clear_password tonyg
RabbitMQ 提供了官方标准的配置文件样例:rabbitmq.conf.example
相关推荐
zhuxue 2020-10-14
shenzhenzsw 2020-10-09
shyoldboy 2020-09-27
leihui00 2020-09-16
lishijian 2020-08-17
程序员伊成 2020-08-06
ljcsdn 2020-07-27
waitzkj 2020-07-25
powrexly 2020-07-20
liym 2020-07-20
zhoucheng0 2020-07-19
shenzhenzsw 2020-07-18
woaishanguosha 2020-07-18
waitzkj 2020-07-18
zhoucheng0 2020-07-08
json0000 2020-07-04
NVEFLY 2020-07-04
OnMyHeart 2020-07-04