欢迎您访问程序员文章站本站旨在为大家提供分享程序员计算机编程知识!
您现在的位置是: 首页

rabbitMQ安装监控管理页面

程序员文章站 2022-06-25 18:23:29
...

rabbitMQ安装监控

      官方地址:http://www.rabbitmq.com/management.html

      Windows

进入到rabbitmq安装目录下,如我的windowsrabbitmq的安装目录为D:\Program Files (x86)\RabbitMQ Server\rabbitmq_server-3.5.1\sbin

           第一步启动管理插件(先启动rabbitmq服务再装插件)

                 rabbitmq-plugins enable rabbitmq_management

                 具体启动:

                        mochiweb

                        webmachine

                        rabbitmq_mochiweb

                        amqp_client

                        rabbitmq_management_agent

                        rabbitmq_management

                 查看安装:

                       rabbitmq-plugins list

                     

           第二步 windows 需要的特定步骤

                 Windows service users need to take additional steps when changing plugins.

                

                 Restarting RabbitMQ Windows Service

                 运行下面命令:

                      rabbitmq-service.bat stop

                      rabbitmq-service.bat install

                      rabbitmq-service.bat start

                

                                      

      Linux

           只需第一步骤即可

           启动

          

      Getting started

           The web UI is located at:

http://localhost:15672/mgmt/

           The HTTP API and its documentation are both located at: http://localhost:15672/api/

           (or view our latest HTTP API documentation here).

           Download rabbitmqadmin at:

http://localhost:15672/cli/

 

          

           用户/密码:guest/guest

 

 

注意:如果是登录远程管理界面(比如物理机访问虚拟机的管理界面时),除了关闭防火墙开通相应允许的端口以外,也不能用guest/guest访问,而应该新创建用户并赋予管理员权限才可访问

如下命令是创建了用户yangjy,密码为123456,并且赋予了管理员和监控页面权限

[root@yangjuanying rabbitmq]# rabbitmqctl add_user yangjy 123456
Creating user "yangjy" ...
[root@yangjuanying rabbitmq]# rabbitmqctl set_user_tags yangjy administrator monitoring
Setting tags for user "yangjy" to [administrator] ...
[root@yangjuanying rabbitmq]#

[root@yangjuanying rabbitmq]# rabbitmqctl set_permissions -p / yangjy ".*" ".*" ".*"
Setting permissions for user "yangjy" in vhost "/" ...

可以用新添加的管理员用户访问rabbitmq监控页面