I have installed Rabbitmq 3.4 in Linux machine, its running on 5672
port.
When I try to declare an exchange, its prompting me with error.
./rabbitmqadmin declare exchange --vhost=localhost name=SAMPLE_EXCHANGE type=direct
using, python script for rabbitmqadmin , which is places in /usr/local/bin/
Error --
Traceback (most recent call last):
File "/usr/local/bin/rabbitmqadmin", line 953, in <module>
main()
File "/usr/local/bin/rabbitmqadmin", line 389, in main
method()
File "/usr/local/bin/rabbitmqadmin", line 569, in invoke_declare
self.put(uri, json.dumps(upload))
File "/usr/local/bin/rabbitmqadmin", line 415, in put
return self.http("PUT", "/api%s" % path, body)
File "/usr/local/bin/rabbitmqadmin", line 441, in http
resp = conn.getresponse()
File "/usr/lib64/python2.6/httplib.py", line 990, in getresponse
response.begin()
File "/usr/lib64/python2.6/httplib.py", line 391, in begin
version, status, reason = self._read_status()
File "/usr/lib64/python2.6/httplib.py", line 349, in _read_status
line = self.fp.readline()
File "/usr/lib64/python2.6/socket.py", line 433, in readline
data = recv(1)
socket.error: [Errno 104] Connection reset by peer
Help me out with this error, will provide more info if needed.
I faced same issue but for me works next steps:
Run rabbit with a list of ports
And enabling rabbitmq_management
Also for declaring exchanges I use this command