Support Questions

Find answers, ask questions, and share your expertise

ListenTCP warning "listenTCP rejecting connection from xx.xx.xx.xx:12345 because max connections has been met"


Hi All,

Thanks to this awesome community.

I have a listenTCP processor which is listening on some IP and port number, everything is running fine however it keeps giving warning such as "warning listenTCP rejecting connection from xx.xx.xx.xx:12345 because max connections has been met" how do I avoid it? should I change the Max COnnections from 2 to 1?

Any thoughts?






I tried increasing the value to 6 or 8, then it started giving error such as " Connection reset by peer" and if l decreased it till default 2 it gave me the same warning. I have a 5 node cluster.


@Matt Burgess @Pierre Villard Need you help to debug this behavior, any ideas please

If you are seeing "max connections has been met" then it means that a given instance of ListenTCP has received more incoming connections than the Max Connections. The default value for max connections is 2, so this means whatever is connecting to ListenTCP is opening more than 2 connections at the same time. You need to adjust the value to meet your needs, and also keep in mind that if you have a 5 node cluster, then each node has its own ListenTCP with its own max connections, so it is up to you to ensure your clients are utilizing each instance of ListenTCP.

The message about "Connection reset by peer" means whatever is sending data to ListenTCP has closed the connection while ListenTCP expected to keep reading from it.


@Bryan Bende Thanks for the reply. Appreciate it. I read this answer from your previous post at stackoverflow

and tried adjusting the value, after adjsuting the max connections value to say something like 5, it starts giving error message instead of warning.

Error "Connection reset by peer" . Any suggestions to fix this

If I deccrease the max connections value value to 3, it starts giving warning again

Thanks again


So it sounds like you need Max Connections to be more than 3 based on what you described...

The "Connection Reset by peer" is really not a problem with ListenTCP, its with the client closing connections.

What is sending the data to ListenTCP?


@Bryan Bende Thanks again, Yes I need to set the max cnnections to be more than 3. there is a firewall pfsense (actually there are multiple pfsense firewall pushing data to nifi load balancer) should I not be worried about "Connection Reset by peer" ?

Well it is normal behavior for the server (ListenTCP) to encounter that error when the client unexpectedly closes a connection that the server was attempting to read from or write to.

So the question is whether there should be connections being unexpectedly closed by your pfsense devices or possibly by your load balancer, which I really can't answer.

You may want to find a repeatable way to produce the error and then use a network capture tool to see what is being sent back and forth when this occurs.

Take a Tour of the Community
Don't have an account?
Your experience may be limited. Sign in to explore more.