You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tomcat.apache.org by bu...@apache.org on 2010/11/15 16:39:42 UTC

DO NOT REPLY [Bug 50273] New: AprEndpoint logs socket accept fails altough error is harmless

https://issues.apache.org/bugzilla/show_bug.cgi?id=50273

           Summary: AprEndpoint logs socket accept fails altough error is
                    harmless
           Product: Tomcat 6
           Version: 6.0.29
          Platform: PC
        OS/Version: Windows XP
            Status: NEW
          Severity: normal
          Priority: P2
         Component: Native:Integration
        AssignedTo: dev@tomcat.apache.org
        ReportedBy: 1983-01-06@gmx.net


I use the above Tomcat on my HP-UX 11.23 system. I have compiled libtcnative
1.1.20 successfully. Tomcat is spamming my log files with this error message:

5.11.2010 09:06:29 org.apache.tomcat.util.net.AprEndpoint$Acceptor run
SCHWERWIEGEND: Socket accept failed
org.apache.tomcat.jni.Error: Kein Pufferplatz verfügbar
        at org.apache.tomcat.jni.Socket.accept(Native Method)
        at
org.apache.tomcat.util.net.AprEndpoint$Acceptor.run(AprEndpoint.java:1169)
        at java.lang.Thread.run(Thread.java:619)

In English: No buffer space available. I googled for the problem and this out:
http://forums.devx.com/archive/index.php/t-99967.html

This bug occurs with the IE6 & IE8 on our setup. I wasn't able to filter this
our with java logging, it simple ignored loading my filter.
Searching the APR docs I found this:
http://dev.ariel-networks.com/apr/apr-tutorial/html/apr-tutorial-13.html
Section "Detection of the remote host closed the socket"

The error seems to be harmless, a debug or info would satisfy here but in the
level severe it simply spams my disk.

Is there a way to fix that according to the APR docs? I have no clue in C.

-- 
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org


DO NOT REPLY [Bug 50273] AprEndpoint logs socket accept fails altough error is harmless

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=50273

Michael Osipov <19...@gmx.net> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Platform|PC                          |HP
         OS/Version|Windows XP                  |HP-UX

-- 
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org


DO NOT REPLY [Bug 50273] AprEndpoint logs socket accept fails altough error is harmless

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=50273

--- Comment #4 from Mark Thomas <ma...@apache.org> 2010-11-21 14:38:37 EST ---
Created an attachment (id=26323)
 --> (https://issues.apache.org/bugzilla/attachment.cgi?id=26323)
Proposed patch for Tomcat 7

The proposed patch adds a separate logger for the acceptor and reduces the log
level from SEVERE to WARNING if the error code is 233. This should allow it to
be filtered out on HP-UX but it will still be logged by default on other
platforms.
To filter these messages out, add the following to logging.properties
org.apache.tomcat.util.net.AprEndpoint$Acceptor.level = SEVERE

-- 
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org


DO NOT REPLY [Bug 50273] AprEndpoint logs socket accept fails altough error is harmless

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=50273

Mark Thomas <ma...@apache.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
         Resolution|                            |FIXED

--- Comment #11 from Mark Thomas <ma...@apache.org> 2010-11-25 12:22:25 EST ---
Fixed in 6.0.x and will be included in 6.0.30 onwards.

-- 
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org


[Bug 50273] AprEndpoint logs socket accept fails altough error is harmless

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=50273

--- Comment #12 from Jackie Rosen <ja...@hushmail.com> ---
*** Bug 260998 has been marked as a duplicate of this bug. ***
Seen from the domain http://volichat.com
Page where seen: http://volichat.com/adult-chat-rooms
Marked for reference. Resolved as fixed @bugzilla.

-- 
You are receiving this mail because:
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org


DO NOT REPLY [Bug 50273] AprEndpoint logs socket accept fails altough error is harmless

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=50273

--- Comment #10 from Michael Osipov <19...@gmx.net> 2010-11-22 09:00:00 EST ---
Great news. Thanks for the quick help.
Do you think it is worth raising a ticket at APR with a link to this one?

-- 
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org


DO NOT REPLY [Bug 50273] AprEndpoint logs socket accept fails altough error is harmless

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=50273

--- Comment #5 from Mark Thomas <ma...@apache.org> 2010-11-21 14:50:02 EST ---
Created an attachment (id=26324)
 --> (https://issues.apache.org/bugzilla/attachment.cgi?id=26324)
Binary patch for Tomcat 6

The attached binary patch for Tomcat 6 is purely for the OP to test this on
their test platform. It is not an official release from the ASF. Use it at your
own risk.

To test this patch, create the following directory structure under the
instance's lib directory:
org/apache/tomcat/util/net
and place the file AprEndpoint$Acceptor.class in that directory. Restart Tomcat
and you should be able to filter out the message using the logging
configuration above. Please report back either way.

If it works, I'll apply the fix to Tomcat 7 and proposed it for Tomcat 6. It it
doesn't work, then I'll provide a patch with further debugging info and we can
go from there.

-- 
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org


DO NOT REPLY [Bug 50273] AprEndpoint logs socket accept fails altough error is harmless

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=50273

--- Comment #8 from Mark Thomas <ma...@apache.org> 2010-11-22 08:26:06 EST ---
Thanks for your testing. This is good news. I'll get this fix into 7.0.x and
proposed for 6.0.x later today.

Yes the solution is a workaround but while HP-UX is returning this error code
for multiple errors - some of which are fatal and some of which are not - there
isn't a huge amount that can be done about it.

It is probably possible to put a work-around into Tomcat's native connector or
maybe even the APR library but I avoided that for two reasons:
- my C knowledge is only very basic
- the fact that the error message can't just be ignored - even on HP-UX means
that an error code has to be returned to Tomcat's acceptor thread anyway which
would require a work-around not dissimilar from what I already wrote.

-- 
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org


DO NOT REPLY [Bug 50273] AprEndpoint logs socket accept fails altough error is harmless

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=50273

--- Comment #2 from Mark Thomas <ma...@apache.org> 2010-11-19 14:43:32 EST ---
Hmm. The error code is indeed 233 but the HP-UX folks have re-used an existing
error code that can also a genuine error has occurred. Therefore, we can't
ignore this universally since it will represent real problems on other
platforms (and possibly also on HP-UX). There is some useful info in this httpd
thread http://httpd.markmail.org/thread/djrcyntamxrkulns

I have a couple of ideas for this that I need to try out.

-- 
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org


DO NOT REPLY [Bug 50273] AprEndpoint logs socket accept fails altough error is harmless

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=50273

--- Comment #7 from Michael Osipov <19...@gmx.net> 2010-11-22 07:40:03 EST ---
Mark,

now I get this:

INFO: Pausing Coyote HTTP/1.1 on http-8443
22.11.2010 13:30:21 org.apache.tomcat.util.net.AprEndpoint$Acceptor run
WARNUNG: Socket accept failed
org.apache.tomcat.jni.Error: Kein Pufferplatz verfügbar
        at org.apache.tomcat.jni.Socket.accept(Native Method)
        at
org.apache.tomcat.util.net.AprEndpoint$Acceptor.run(AprEndpoint.java:1170)
        at java.lang.Thread.run(Thread.java:619)
22.11.2010 13:30:22 org.apache.catalina.core.StandardService stop
INFO: Stopping service Catalina

Which seems correct. I changed the log level and will check the logs in the
next couple of days. But it seems to be fixed by that.

I am just curious if the root cause of this can be fixed in APR or not? Your
solution is a mere workaround.

-- 
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org


DO NOT REPLY [Bug 50273] AprEndpoint logs socket accept fails altough error is harmless

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=50273

Mark Thomas <ma...@apache.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
          Component|Native:Integration          |Connectors

--- Comment #1 from Mark Thomas <ma...@apache.org> 2010-11-19 14:05:10 EST ---
We need to figure out the error number to correctly filter out this particular
error. I'll take a look and see if I can figure out what it is from the Tomcat
native / APR source (233 is looking like a good bet). In case I can't and for
future use, I have modified the 7.0.x code to include it in the exception
message.

-- 
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org


DO NOT REPLY [Bug 50273] AprEndpoint logs socket accept fails altough error is harmless

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=50273

--- Comment #3 from Michael Osipov <19...@gmx.net> 2010-11-19 16:37:58 EST ---
Mark,

if I can assist somehow, please let me now. I am running 6.0.x only. I can
recompile a patched libtcnative and see if this works and a modified tomcat for
test purposes with the current libtcnative.

-- 
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org


DO NOT REPLY [Bug 50273] AprEndpoint logs socket accept fails altough error is harmless

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=50273

--- Comment #6 from Michael Osipov <19...@gmx.net> 2010-11-21 15:18:51 EST ---
Mark,
thanks for the the binary patch. Will test this tomorrow. Btw, the patch is
incorrect. Bug Id stated in the patch has to be 50273 and not 50773

-- 
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org


DO NOT REPLY [Bug 50273] AprEndpoint logs socket accept fails altough error is harmless

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=50273

--- Comment #9 from Mark Thomas <ma...@apache.org> 2010-11-22 08:45:45 EST ---
Fixed in 7.0.x and will be included in 7.0.5 onwards
Proposed for 6.0.x

-- 
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org