Peter Crowther wrote:
2009/10/15 Ken Johanson <tomcat-u...@kensystem.com>

SEVERE: Error starting endpoint
java.lang.Exception: Socket bind failed: [98] Address already in use
       at org.apache.tomcat.util.net.AprEndpoint.init(AprEndpoint.java:612)
..
(no listener is actually running on 98; this is just generic Sun msg when
not allowed to bind to prv'd port)


98 is the errno (EADDRINUSE), not the port.  The error message doesn't list
which port failed.


Is there a configuration to change the port that APR uses from 98 to a
non-privileged (>1024) one?


APR doesn't use any ports other than the ones you configure in your
connectors.  Something is holding onto one of the ports you want.  Check
what ports Tomcat wants, and check there isn't another process running on
the box that is using one of them - it might even be an old Tomcat.  Don't
forget to check the shutdown port (8005 by default), although from the stack
trace it looks like the problem port is a connector, not the shutdown port.


PS - Connector.xml excerpts:
   <Connector
              protocol="org.apache.coyote.http11.Http11AprProtocol"
              port="8443"
              enableLookups="false"
              SSLEnabled="true"
              scheme="https"
              secure="true"
              SSLCertificateFile="${catalina.base}/conf/cert.crt"
              SSLCertificateKeyFile="${catalina.base}/conf/cert.key"
              disableUploadTimeout="true"
   />
   <Listener className="org.apache.catalina.core.AprLifecycleListener"
SSLEngine="on" />


Any other connectors defined?

- Peter


Thank you Peter you are correct! The 98 being mentioned by itself is very misleading, at least for a lay person like myself :)

It was indeed the normal listeners (8080 and 8443 in my case). I COMPLETELY took for granted that my init script was handing the shutdown... it is not. Using APR and an init-script* (or jsvc) that worked just fine for JIO and NIO, the server does not shutdown for APR. I have to `ps` for the java proc then send a kill signal to it. I'm not sure why.... but it may be related to bad cleanup code for the following, *newly observed problem*.....

After doing a kill, then startup I now get:

java.lang.Exception: Invalid Server SSL Protocol
        at org.apache.tomcat.jni.SSLContext.make(Native Method)
at org.apache.tomcat.util.net.AprEndpoint.init(AprEndpoint.java:693) at org.apache.coyote.http11.Http11AprProtocol.init(Http11AprProtocol.java:107) at org.apache.catalina.connector.Connector.initialize(Connector.java:1058)
...........
Oct 15, 2009 10:10:44 PM org.apache.catalina.startup.Catalina load
SEVERE: Catalina.start
LifecycleException: Protocol handler initialization failed: java.lang.Exception: Invalid Server SSL Protocol
        at
......

But I can't see where I'm deviating from docs with:
<Connector
    port="8443"
    enableLookups="false"
    SSLEnabled="true" scheme="https" secure="true"
    SSLCertificateFile="${catalina.base}/conf/cert.pem"
    SSLCertificateKeyFile="${catalina.base}/conf/key.pem"
    disableUploadTimeout="true"
    SSLVerifyClient="optional"
    sslProtocol="TLS"
/>

BTW I'm now tryng recent apache-tomcat-6.0.20 and rebuilt tomcat-native-1.1.16.

Any insight would be immensely appreciated!

Best regards,
-Ken



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

Reply via email to