4

I would like to know if there is a way to configure RabbitMQ to close lost connections regardless the heartbeat.

My issue is that if a connection was opened with heartbeat set to 0 and the connection is lost (like disabling the network interface) the server keep the connection open forever, I understand that the TCP timeout is 11 minutes but the connection is not closing even hours later.

I did added keepalive configuration to the server but with the same result (I'm working with SSL).

Is there a way to configure the server to close this connections regardless to the heartbeat configuration?

Or maybe I can reject connection with low heartbeat configuration?

Environment Details:

OS ubuntu server 14.04

RabbitMQ server version 3.5.4

Configuration:

{tcp_listen_options, [binary,
                     {packet,        raw},
                     {reuseaddr,     true},
                     {backlog,       128},
                     {nodelay,       true},
                     {exit_on_close, true},
                     {keepalive,     true}]}

{ssl_options, [{cacertfile,           "/etc/rabbitmq/certs/cacert.pem"},
                  {certfile,             "/etc/rabbitmq/certs/cert.pem"},
                  {keyfile,              "/etc/rabbitmq/certs/key.pem"},
                  {verify,               verify_peer},
                  {keepalive,            true},
                  {fail_if_no_peer_cert, false}]},
Amir Rossert
  • 226
  • 2
  • 15
  • What is your configuration? What is exactly "added keepalive configuration"? How it doesn't work? Do you have logs? As written, this question is looks like you are asking for debug help but doesn't provide any detailed info about actual and expected result, your environment, software and configuration (but not limited to). – pinepain Nov 26 '15 at 11:52
  • I added to the configuration and some details, what I'm trying to do is prevent the situation that a connection is lost but the rabbitmq server keep it open. – Amir Rossert Nov 26 '15 at 13:11

0 Answers0