Getting Connection timed out error in logstash

Hi All,

I have created one logstash pipeline using rabbitmq input plugin. But i am getting below error.

[ERROR] 2025-09-25 09:35:08.167 [[prabbitmq]<rabbitmq] rabbitmq - RabbitMQ connection error, will retry {:exception=>MarchHare::ConnectionRefused, :message=>"Connection timed out. Target host list: xxxxxxxxxxxxx.com:123, target virtual host: /, username: abbcc", :cause=>#<Java::JavaUtilConcurrent::TimeoutException: >}

i have verified connection between rabbitmq servers and logstash using telnet command it is showing connected.

My logstash configuration is

input {
rabbitmq {
host => "abc.bcq.com"
port => 123
user => "myuser"
password => "mypassword"
queue => "topic"
automatic_recovery => true
heartbeat => 30
}
}

JavaUtilConcurrent::TimeoutException
It's something related to:

  • open network path, LS server must be able to reach RMQ on the target port
  • correct hostname, username/pass
  • ssl connection, maybe to set: ssl => false, if you are not using.

Can you confirm that you have tested telnet from LS to rabbitmq on port 123? Not from your host or any other.
Have you checked RMQ logs? Any trace on that side? FW log, RMQ log, anything?