On 15/02/2023 12:24, Patkar Omkar Anant wrote:
Hi All,

We are facing an issue with Apache Tomcat 9. I had posted this issue in 
Bugzilla forum, and from there I was re-directed here.

The link to the bug is = https://bz.apache.org/bugzilla/show_bug.cgi?id=66476

I will elaborate the details here: -

----------------------------------
ERROR: -
----------------------------------
10-Feb-2023 02:16:19.618 SEVERE [http-nio-80-Acceptor] 
org.apache.tomcat.util.net.Acceptor.run Socket accept failed
         java.io.IOException: Duplicate accept detected. This is a known OS 
bug. Please consider reporting that you are affected:

The only result of that error message is that the duplicate accept is ignored. It should be transparent to the client as request processing will continue on the original connection.

If you see this message as a result of a false positive then the client connection will be dropped. That is obviously more problematic.

----------------------------------
We are using Camunda 7.16 BPMN tool which comes with inbuilt Apache Tomcat 
9.0.58. This is deployed on our Linux VM (CentOS). The VM is within our company 
network, and ... via company's firewall another trusted application on Azure 
cloud (outside company network)...is only allowed to make REST API calls to 
Camunda (hosted on Tomcat). When Tomcat is started all works fine, requests 
placed from trusted application on Azure Cloud are able to reach our Tomcat and 
our application works on it, until out of the blue and randomly above error 
occurs and tomcat no longer serves request coming from external application on 
cloud.

To be clear, no further requests can be served from the external application but internal clients can continue?

What has been tried so far ?: -
 From several posts after google search it was found that Linux Kernel version 
could help. Previously it was 3.x and now it is upgraded to 6.0.9-1 and Apache 
Tomcat version is 9.0.58... still we face the above error.

That suggests you are seeing false positives rather than the Linux bug. To avoid the false positives, you need to upgrade as the detection got a lot better in 9.0.59 onwards.

1) Why it behaves strangely with external requests and not with internal ones ?

Do internal and external requests go to the same connector?

It would be worth running Wireshark or equivalent to look at the external traffic that is being received. In particular, look at the source port for the requests once the problem starts.

2) How can we consistently reproduce the issue ?

If you want to test the original Linux bug, steps to reproduce are in the Ubuntu issue referenced in the error message.

If you want to recreate the issue you are seeing (which I suspect is specific to your environment) you'll need to figure out what is happening first.

3) What could be the possible cause and how to fix it ?

Assuming you are seeing false positives with the Linux bug detection, the client using the same port for multiple requests. If the Linux bug error message is a red herring, then an Acceptor crash might explain what you are seeing.

Mark

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org

Reply via email to