You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by "agonat@libero.it" <ag...@libero.it> on 2010/05/22 10:28:10 UTC
intermittent SocketException on startup tomcat 5.5.28 and under
JBOSS 4.2.3GA
Good Morning
Excuse for my poor english
I have a strange error that occours on startup and after some minutes this
cause the block of my appliction, only stop webserver from lot minutes or
restart server sometime resolve the problem. But often the problem persist.
In Short:
I have a web appliction deployed initially under tomcat 5.5.28 (with jre-
1_5_0_22 and SO win2003 Server 32 bit) that sometimes cause specially on
startup the follow error:
17-apr-2010 7.00.49 org.apache.tomcat.util.net.PoolTcpEndpoint acceptSocket
GRAVE: Endpoint [SSL: ServerSocket[addr=0.0.0.0/0.0.0.0,port=0,localport=443]]
ignored exception: java.net.SocketException: socket closed
java.net.SocketException: socket closed
at java.net.PlainSocketImpl.socketAccept(Native Method)
at java.net.PlainSocketImpl.accept(Unknown Source)
at java.net.ServerSocket.implAccept(Unknown Source)
at com.sun.net.ssl.internal.ssl.SSLServerSocketImpl.accept(Unknown Source)
at org.apache.tomcat.util.net.jsse.JSSESocketFactory.acceptSocket
(JSSESocketFactory.java:117)
at org.apache.tomcat.util.net.PoolTcpEndpoint.acceptSocket(PoolTcpEndpoint.
java:408)
at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt
(LeaderFollowerWorkerThread.java:71)
at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.
java:689)
at java.lang.Thread.run(Unknown Source)
17-apr-2010 7.01.10 org.apache.tomcat.util.net.PoolTcpEndpoint acceptSocket
AVVERTENZA: Reinitializing ServerSocket
17-apr-2010 7.52.33 org.apache.tomcat.util.net.PoolTcpEndpoint acceptSocket
GRAVE: Endpoint [SSL: ServerSocket[addr=0.0.0.0/0.0.0.0,port=0,localport=443]]
ignored exception: java.net.SocketException: socket closed
java.net.SocketException: socket closed
at java.net.PlainSocketImpl.socketAccept(Native Method)
at java.net.PlainSocketImpl.accept(Unknown Source)
at java.net.ServerSocket.implAccept(Unknown Source)
at com.sun.net.ssl.internal.ssl.SSLServerSocketImpl.accept(Unknown Source)
at org.apache.tomcat.util.net.jsse.JSSESocketFactory.acceptSocket
(JSSESocketFactory.java:117)
at org.apache.tomcat.util.net.PoolTcpEndpoint.acceptSocket(PoolTcpEndpoint.
java:408)
at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt
(LeaderFollowerWorkerThread.java:71)
at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.
java:689)
at java.lang.Thread.run(Unknown Source)
17-apr-2010 7.52.54 org.apache.tomcat.util.net.PoolTcpEndpoint acceptSocket
AVVERTENZA: Reinitializing ServerSocket
17-apr-2010 7.52.55 org.apache.tomcat.util.net.PoolTcpEndpoint acceptSocket
GRAVE: Endpoint [SSL: ServerSocket[addr=0.0.0.0/0.0.0.0,port=0,localport=443]]
ignored exception: java.net.SocketException: socket closed
java.net.SocketException: socket closed
at java.net.PlainSocketImpl.socketAccept(Native Method)
at java.net.PlainSocketImpl.accept(Unknown Source)
at java.net.ServerSocket.implAccept(Unknown Source)
at com.sun.net.ssl.internal.ssl.SSLServerSocketImpl.accept(Unknown Source)
at org.apache.tomcat.util.net.jsse.JSSESocketFactory.acceptSocket
(JSSESocketFactory.java:117)
at org.apache.tomcat.util.net.PoolTcpEndpoint.acceptSocket(PoolTcpEndpoint.
java:408)
at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt
(LeaderFollowerWorkerThread.java:71)
at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.
java:689)
at java.lang.Thread.run(Unknown Source)
17-apr-2010 7.53.16 org.apache.tomcat.util.net.PoolTcpEndpoint acceptSocket
AVVERTENZA: Reinitializing ServerSocket
17-apr-2010 7.53.17 org.apache.tomcat.util.net.PoolTcpEndpoint acceptSocket
GRAVE: Endpoint [SSL: ServerSocket[addr=0.0.0.0/0.0.0.0,port=0,localport=443]]
ignored exception: java.net.SocketException: socket closed
java.net.SocketException: socket closed
at java.net.PlainSocketImpl.socketAccept(Native Method)
at java.net.PlainSocketImpl.accept(Unknown Source)
at java.net.ServerSocket.implAccept(Unknown Source)
at com.sun.net.ssl.internal.ssl.SSLServerSocketImpl.accept(Unknown Source)
at org.apache.tomcat.util.net.jsse.JSSESocketFactory.acceptSocket
(JSSESocketFactory.java:117)
at org.apache.tomcat.util.net.PoolTcpEndpoint.acceptSocket(PoolTcpEndpoint.
java:408)
at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt
(LeaderFollowerWorkerThread.java:71)
at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.
java:689)
at java.lang.Thread.run(Unknown Source)
17-apr-2010 7.53.38 org.apache.tomcat.util.net.PoolTcpEndpoint acceptSocket
AVVERTENZA: Reinitializing ServerSocket
17-apr-2010 7.53.39 org.apache.tomcat.util.net.PoolTcpEndpoint acceptSocket
GRAVE: Endpoint [SSL: ServerSocket[addr=0.0.0.0/0.0.0.0,port=0,localport=443]]
ignored exception: java.net.SocketException: socket closed
java.net.SocketException: socket closed
at java.net.PlainSocketImpl.socketAccept(Native Method) .....
in tomcat server.xml i have configured 2 connector: one su port 80 and other
on port 443, The connectors configuration is:
Connector port="80" maxHttpHeaderSize="8192"
maxThreads="350" minSpareThreads="25" maxSpareThreads="100"
enableLookups="false" redirectPort="443" acceptCount="100"
connectionTimeout="20000" disableUploadTimeout="true" />
.......
<Connector port="443" maxHttpHeaderSize="8192"
maxThreads="150" minSpareThreads="25" maxSpareThreads="75"
enableLookups="false" disableUploadTimeout="true"
acceptCount="100" scheme="https" secure="true"
clientAuth="false" sslProtocol="TLS"
keystoreFile="C:\CertificatiHTTPS\aaa.pfx"
keystorePass="xxx"
keystoreType="PKCS12"
/>
This problem never occours in the past but arise after we transfer the router
from site to another. After this transfer sometime occours the error, It's
strange. The HW,SW is the same and number of Users is bout the same.
So we think to upgrade in tecnology and after installed jdk 1.6.16 and JBOSS4.
2.3 and deployed the same web application the problem sometime occours
(specially in first 5 minutes on startup.. NOTE in jBOSS we change
JAVA_OPTIONS : -Xms384m -Xmx1024m -XX:MaxPermSize=128m only ) the error is:
010-05-17 12:53:24,112 ERROR [org.apache.tomcat.util.net.JIoEndpoint] Socket
accept failed
java.net.SocketException: socket closed
at java.net.PlainSocketImpl.socketAccept(Native Method)
at java.net.PlainSocketImpl.accept(PlainSocketImpl.java:390)
at java.net.ServerSocket.implAccept(ServerSocket.java:453)
at java.net.ServerSocket.accept(ServerSocket.java:421)
at org.apache.tomcat.util.net.DefaultServerSocketFactory.acceptSocket
(DefaultServerSocketFactory.java:61)
at org.apache.tomcat.util.net.JIoEndpoint$Acceptor.run(JIoEndpoint.java:309)
at java.lang.Thread.run(Thread.java:619)
2010-05-17 12:53:24,127 ERROR [org.apache.tomcat.util.net.JIoEndpoint] Socket
accept failed
in this case we have the same configuration of tomcat connector under jboss
(file C:\jboss-4.2.3.GA\server\default\deploy\jboss-web.deployer\server.xml):
<Connector port="80" address="${jboss.bind.address}"
minSpareThreads="25" maxSpareThreads="100"
maxThreads="350" maxHttpHeaderSize="8192"
emptySessionPath="true" protocol="HTTP/1.1"
enableLookups="false" redirectPort="443" acceptCount="200"
connectionTimeout="20000" disableUploadTimeout="true" />
....
<Connector port="443" protocol="HTTP/1.1" SSLEnabled="true"
minSpareThreads="25" maxSpareThreads="100"
maxThreads="250" scheme="https" secure="true"
clientAuth="false" sslProtocol="TLS"
keystoreFile="C:\CertificatiHTTPS\aaa.pfx"
keystorePass="xxx"
keystoreType="PKCS12"
/>
Can anyone help me because the problem is present in production enviroment.
thanks a lot for every hint .
Agostino
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org
Re: intermittent SocketException on startup tomcat 5.5.28 and under
JBOSS 4.2.3GA
Posted by Pid <pi...@pidster.com>.
On 22/05/2010 09:28, agonat@libero.it wrote:
> Good Morning
>
> Excuse for my poor english
>
> I have a strange error that occours on startup and after some minutes this
> cause the block of my appliction, only stop webserver from lot minutes or
> restart server sometime resolve the problem. But often the problem persist.
>
> In Short:
> I have a web appliction deployed initially under tomcat 5.5.28 (with jre-
> 1_5_0_22 and SO win2003 Server 32 bit) that sometimes cause specially on
> startup the follow error:
>
> 17-apr-2010 7.00.49 org.apache.tomcat.util.net.PoolTcpEndpoint acceptSocket
> GRAVE: Endpoint [SSL: ServerSocket[addr=0.0.0.0/0.0.0.0,port=0,localport=443]]
> ignored exception: java.net.SocketException: socket closed
> java.net.SocketException: socket closed
> at java.net.PlainSocketImpl.socketAccept(Native Method)
> at java.net.PlainSocketImpl.accept(Unknown Source)
> at java.net.ServerSocket.implAccept(Unknown Source)
> at com.sun.net.ssl.internal.ssl.SSLServerSocketImpl.accept(Unknown Source)
> at org.apache.tomcat.util.net.jsse.JSSESocketFactory.acceptSocket
> (JSSESocketFactory.java:117)
> at org.apache.tomcat.util.net.PoolTcpEndpoint.acceptSocket(PoolTcpEndpoint.
> java:408)
> at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt
> (LeaderFollowerWorkerThread.java:71)
> at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.
> java:689)
> at java.lang.Thread.run(Unknown Source)
> 17-apr-2010 7.01.10 org.apache.tomcat.util.net.PoolTcpEndpoint acceptSocket
> AVVERTENZA: Reinitializing ServerSocket
> 17-apr-2010 7.52.33 org.apache.tomcat.util.net.PoolTcpEndpoint acceptSocket
> GRAVE: Endpoint [SSL: ServerSocket[addr=0.0.0.0/0.0.0.0,port=0,localport=443]]
> ignored exception: java.net.SocketException: socket closed
> java.net.SocketException: socket closed
> at java.net.PlainSocketImpl.socketAccept(Native Method)
> at java.net.PlainSocketImpl.accept(Unknown Source)
> at java.net.ServerSocket.implAccept(Unknown Source)
> at com.sun.net.ssl.internal.ssl.SSLServerSocketImpl.accept(Unknown Source)
> at org.apache.tomcat.util.net.jsse.JSSESocketFactory.acceptSocket
> (JSSESocketFactory.java:117)
> at org.apache.tomcat.util.net.PoolTcpEndpoint.acceptSocket(PoolTcpEndpoint.
> java:408)
> at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt
> (LeaderFollowerWorkerThread.java:71)
> at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.
> java:689)
> at java.lang.Thread.run(Unknown Source)
> 17-apr-2010 7.52.54 org.apache.tomcat.util.net.PoolTcpEndpoint acceptSocket
> AVVERTENZA: Reinitializing ServerSocket
> 17-apr-2010 7.52.55 org.apache.tomcat.util.net.PoolTcpEndpoint acceptSocket
> GRAVE: Endpoint [SSL: ServerSocket[addr=0.0.0.0/0.0.0.0,port=0,localport=443]]
> ignored exception: java.net.SocketException: socket closed
> java.net.SocketException: socket closed
> at java.net.PlainSocketImpl.socketAccept(Native Method)
> at java.net.PlainSocketImpl.accept(Unknown Source)
> at java.net.ServerSocket.implAccept(Unknown Source)
> at com.sun.net.ssl.internal.ssl.SSLServerSocketImpl.accept(Unknown Source)
> at org.apache.tomcat.util.net.jsse.JSSESocketFactory.acceptSocket
> (JSSESocketFactory.java:117)
> at org.apache.tomcat.util.net.PoolTcpEndpoint.acceptSocket(PoolTcpEndpoint.
> java:408)
> at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt
> (LeaderFollowerWorkerThread.java:71)
> at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.
> java:689)
> at java.lang.Thread.run(Unknown Source)
> 17-apr-2010 7.53.16 org.apache.tomcat.util.net.PoolTcpEndpoint acceptSocket
> AVVERTENZA: Reinitializing ServerSocket
> 17-apr-2010 7.53.17 org.apache.tomcat.util.net.PoolTcpEndpoint acceptSocket
> GRAVE: Endpoint [SSL: ServerSocket[addr=0.0.0.0/0.0.0.0,port=0,localport=443]]
> ignored exception: java.net.SocketException: socket closed
> java.net.SocketException: socket closed
> at java.net.PlainSocketImpl.socketAccept(Native Method)
> at java.net.PlainSocketImpl.accept(Unknown Source)
> at java.net.ServerSocket.implAccept(Unknown Source)
> at com.sun.net.ssl.internal.ssl.SSLServerSocketImpl.accept(Unknown Source)
> at org.apache.tomcat.util.net.jsse.JSSESocketFactory.acceptSocket
> (JSSESocketFactory.java:117)
> at org.apache.tomcat.util.net.PoolTcpEndpoint.acceptSocket(PoolTcpEndpoint.
> java:408)
> at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt
> (LeaderFollowerWorkerThread.java:71)
> at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.
> java:689)
> at java.lang.Thread.run(Unknown Source)
> 17-apr-2010 7.53.38 org.apache.tomcat.util.net.PoolTcpEndpoint acceptSocket
> AVVERTENZA: Reinitializing ServerSocket
> 17-apr-2010 7.53.39 org.apache.tomcat.util.net.PoolTcpEndpoint acceptSocket
> GRAVE: Endpoint [SSL: ServerSocket[addr=0.0.0.0/0.0.0.0,port=0,localport=443]]
> ignored exception: java.net.SocketException: socket closed
> java.net.SocketException: socket closed
> at java.net.PlainSocketImpl.socketAccept(Native Method) .....
>
> in tomcat server.xml i have configured 2 connector: one su port 80 and other
> on port 443, The connectors configuration is:
>
> Connector port="80" maxHttpHeaderSize="8192"
> maxThreads="350" minSpareThreads="25" maxSpareThreads="100"
> enableLookups="false" redirectPort="443" acceptCount="100"
> connectionTimeout="20000" disableUploadTimeout="true" />
> .......
>
> <Connector port="443" maxHttpHeaderSize="8192"
> maxThreads="150" minSpareThreads="25" maxSpareThreads="75"
> enableLookups="false" disableUploadTimeout="true"
> acceptCount="100" scheme="https" secure="true"
> clientAuth="false" sslProtocol="TLS"
> keystoreFile="C:\CertificatiHTTPS\aaa.pfx"
> keystorePass="xxx"
> keystoreType="PKCS12"
> />
>
> This problem never occours in the past but arise after we transfer the router
> from site to another. After this transfer sometime occours the error, It's
> strange. The HW,SW is the same and number of Users is bout the same.
>
> So we think to upgrade in tecnology and after installed jdk 1.6.16 and JBOSS4.
> 2.3 and deployed the same web application the problem sometime occours
> (specially in first 5 minutes on startup.. NOTE in jBOSS we change
> JAVA_OPTIONS : -Xms384m -Xmx1024m -XX:MaxPermSize=128m only ) the error is:
>
> 010-05-17 12:53:24,112 ERROR [org.apache.tomcat.util.net.JIoEndpoint] Socket
> accept failed
> java.net.SocketException: socket closed
> at java.net.PlainSocketImpl.socketAccept(Native Method)
> at java.net.PlainSocketImpl.accept(PlainSocketImpl.java:390)
> at java.net.ServerSocket.implAccept(ServerSocket.java:453)
> at java.net.ServerSocket.accept(ServerSocket.java:421)
> at org.apache.tomcat.util.net.DefaultServerSocketFactory.acceptSocket
> (DefaultServerSocketFactory.java:61)
> at org.apache.tomcat.util.net.JIoEndpoint$Acceptor.run(JIoEndpoint.java:309)
> at java.lang.Thread.run(Thread.java:619)
> 2010-05-17 12:53:24,127 ERROR [org.apache.tomcat.util.net.JIoEndpoint] Socket
> accept failed
>
> in this case we have the same configuration of tomcat connector under jboss
> (file C:\jboss-4.2.3.GA\server\default\deploy\jboss-web.deployer\server.xml):
>
> <Connector port="80" address="${jboss.bind.address}"
> minSpareThreads="25" maxSpareThreads="100"
> maxThreads="350" maxHttpHeaderSize="8192"
> emptySessionPath="true" protocol="HTTP/1.1"
> enableLookups="false" redirectPort="443" acceptCount="200"
> connectionTimeout="20000" disableUploadTimeout="true" />
> ....
> <Connector port="443" protocol="HTTP/1.1" SSLEnabled="true"
> minSpareThreads="25" maxSpareThreads="100"
> maxThreads="250" scheme="https" secure="true"
> clientAuth="false" sslProtocol="TLS"
> keystoreFile="C:\CertificatiHTTPS\aaa.pfx"
> keystorePass="xxx"
> keystoreType="PKCS12"
> />
>
> Can anyone help me because the problem is present in production enviroment.
If I'm reading the stack trace correctly, the listening socket is being
closed shortly after being opened. Do you have a firewall that is
blocking the port perhaps?
If you start a completely new log file, what messages appear before the
error appears?
p
> thanks a lot for every hint .
>
> Agostino
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
> For additional commands, e-mail: users-help@tomcat.apache.org
>