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