rabbitmq配置

主机名要能解析到本机的ip
要大于1GB内存

rabbitmqctl cluster_status
Cluster status of node 'rabbit@jpuyy-rmq-3' ...

[
 {nodes,[{disc,['rabbit@jpuyy-rmq-1','rabbit@jpuyy-rmq-3']},
         {ram,['rabbit@jpuyy-rmq-2','rabbit@jpuyy-set-rmq-1']}]},
 {running_nodes,['rabbit@jpuyy-set-rmq-1','rabbit@jpuyy-rmq-1','rabbit@jpuyy-rmq-2','rabbit@jpuyy-rmq-3']},
 {cluster_name,<<"rabbit@jpuyy-rmq-1">>},
 {partitions,[]}
]

查看队列

rabbitmqctl list_queues -p vhostname

查看 vhosts

rabbitmqctl list_vhosts

查看用户

rabbitmqctl list_users

查看 vhost 的用户权限

rabbitmqctl list_permissions -p myhost

查看某用户的权限

rabbitmqctl list_user_permissions jpuyy
rabbitmqctl add_vhost myvhost                                                   
rabbitmqctl add_user jpuyy jpuyypass
rabbitmqctl set_permissions -p myvhost    
rabbitmqctl set_permissions -p myvhost jpuyy ".*" ".*" ".*"

发表评论

电子邮件地址不会被公开。 必填项已用*标注