SPRINGBOOT-RABBITMQ problem access to Vhost '/' refused for user permission issues

Source: Internet
Author: User
Tags rabbitmq

Exception: Exception in thread "main" java.io.IOException
At Com.rabbitmq.client.impl.AMQChannel.wrap (amqchannel.java:106)
At Com.rabbitmq.client.impl.AMQChannel.wrap (amqchannel.java:102)
At COM.RABBITMQ.CLIENT.IMPL.AMQCHANNEL.EXNWRAPPINGRPC (amqchannel.java:124)
At Com.rabbitmq.client.impl.AMQConnection.start (amqconnection.java:378)
At Com.rabbitmq.client.ConnectionFactory.newConnection (connectionfactory.java:678)
At Com.rabbitmq.client.ConnectionFactory.newConnection (connectionfactory.java:722)
At Upsmart.zhsen.ServerProducer.main (serverproducer.java:33)
caused by:com.rabbitmq.client.ShutdownSignalException:connection error; Protocol method: #method <connection.close> (reply-code=530, reply-text=not_allowed-access to Vhost '/' refused For user ' MQ ', class-id=10, method-id=40)
At Com.rabbitmq.utility.ValueOrException.getValue (valueorexception.java:67)
At Com.rabbitmq.utility.BlockingValueOrException.uninterruptibleGetValue (blockingvalueorexception.java:33)
At Com.rabbitmq.client.impl.amqchannel$blockingrpccontinuation.getreply (amqchannel.java:361)
At COM.RABBITMQ.CLIENT.IMPL.AMQCHANNEL.PRIVATERPC (amqchannel.java:226)
At COM.RABBITMQ.CLIENT.IMPL.AMQCHANNEL.EXNWRAPPINGRPC (amqchannel.java:118)
... 4 more
Reason:
User ' MQ ' does not have access to '/'


sudo rabbitmqctl list_users
List User Rights
Listing users ...
MQ [Administrator]
Guest [Administrator]


sudo rabbitmqctl set_permissions-p/MQ '. * '. * '. * '
This command gives the user MQ the ability to configure, write, and read all the resources in the virtual host to manage the resources in it

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.