The connection was reset using RabbitMQ
<p>Helo,</p>

<p>I am really new at rabbitmq. I was trying to establish a rabbitmq router and send him a HelloWorld in python using pika.</p>

<p>In terminal i do sudo rabbitmq-server start. I can enter localhost:15672. But when i try to connect to localhost:5672 appears "AMQP" for one second and then "The connection was reset".</p>

<p>When doing sudo rabbitmqctl list_connections, my connection doesn't appear.
When doing netstat -tapnl | grep 5672 it appears this:</p>

<pre><code>tcp        0      0 0.0.0.0:15672           0.0.0.0:*               LISTEN      -                   
tcp        0      0 127.0.0.1:5672          0.0.0.0:*               LISTEN      -                   
tcp        0      0 0.0.0.0:25672           0.0.0.0:*               LISTEN      -  
</code></pre>

<p>My python is giving the error ProbableAccessDeniedError, but I have configured all right i think. Here is a snipet:</p>

<pre><code>import pika
from pika.exceptions import ProbableAccessDeniedError
from pika.exceptions import ProbableAuthenticationError


if __name__ == '__main__':

    credentials = pika.PlainCredentials('name', 'pass)
    # change the ip in here!
    parameters = pika.ConnectionParameters(
                   host='localhost', port=5672, vhost='test', credentials=credentials)
    try:
        connection = pika.BlockingConnection(parameters)

        channel = connection.channel()

        channel.basic_publish(exchange='',
                              routing_key='hello',
                              body='Hello World!')
        print(" [x] Sent 'Hello World!'")

    except ProbableAuthenticationError:
        print("Authetication Error")
    except ProbableAccessDeniedError:
        print("Authetication Denied")
    finally:
        if channel:
            channel.close()
        if connection:
            connection.close()
</code></pre>

<p>And here is my rabbitmq.config:</p>

<pre><code>[
  {rabbit, [
    % Network Connectivity
    % ====================
    {tcp_listeners,[{"127.0.0.1",5672}]},
    {num_tcp_acceptors, 5},
    {handshake_timeout, 10000},
    % Default User / VHost
    % ====================
    {default_vhost,       &lt;&lt;"test"&gt;&gt;},
    {default_user,        &lt;&lt;"name"&gt;&gt;},
    {default_pass,        &lt;&lt;"pass"&gt;&gt;},
    {default_permissions, [&lt;&lt;".*"&gt;&gt;, &lt;&lt;".*"&gt;&gt;, &lt;&lt;".*"&gt;&gt;]},
    {loopback_users, []}
  ]}
].
</code></pre>

<p>So I guess the problem is because of the localhost:5672. Any idea?</p>