If it was that simple, I would not ask your help ^^.

An example :

Tomcat was stopped before, and the commands :
 sockstat -p 8080

give nothing.


And when I start tomcat, I got :


SEVERE: Failed to initialize end point associated with ProtocolHandler
["http-bio-8080"]
java.net.BindException: Address already in use <null>:8080
        at org.apache.tomcat.util.net.JIoEndpoint.bind(JIoEndpoint.java:378)
        at
org.apache.tomcat.util.net.AbstractEndpoint.init(AbstractEndpoint.java:482)
        at
org.apache.coyote.AbstractProtocolHandler.init(AbstractProtocolHandler.java:354)
        at
org.apache.coyote.http11.AbstractHttp11JsseProtocol.init(AbstractHttp11JsseProtocol.java:119)
        at
org.apache.catalina.connector.Connector.initInternal(Connector.java:910)
        at
org.apache.catalina.util.LifecycleBase.init(LifecycleBase.java:101)
        at
org.apache.catalina.core.StandardService.initInternal(StandardService.java:559)
        at
org.apache.catalina.util.LifecycleBase.init(LifecycleBase.java:101)
        at
org.apache.catalina.core.StandardServer.initInternal(StandardServer.java:781)
        at
org.apache.catalina.util.LifecycleBase.init(LifecycleBase.java:101)
        at org.apache.catalina.startup.Catalina.load(Catalina.java:572)
        at org.apache.catalina.startup.Catalina.load(Catalina.java:595)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
        at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
        at java.lang.reflect.Method.invoke(Method.java:597)
        at org.apache.catalina.startup.Bootstrap.load(Bootstrap.java:262)
        at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:430)
Caused by: java.net.BindException: Address already in use
        at java.net.PlainSocketImpl.socketBind(Native Method)
        at java.net.PlainSocketImpl.bind(PlainSocketImpl.java:383)
        at java.net.ServerSocket.bind(ServerSocket.java:328)
        at java.net.ServerSocket.<init>(ServerSocket.java:194)
        at java.net.ServerSocket.<init>(ServerSocket.java:150)
        at
org.apache.tomcat.util.net.DefaultServerSocketFactory.createSocket(DefaultServerSocketFactory.java:48)
        at org.apache.tomcat.util.net.JIoEndpoint.bind(JIoEndpoint.java:365)
        ... 17 more
May 20, 2011 3:04:59 PM org.apache.catalina.core.StandardService
initInternal
SEVERE: Failed to initialize connector [Connector[HTTP/1.1-8080]]
org.apache.catalina.LifecycleException: Protocol handler initialization
failed
        at
org.apache.catalina.connector.Connector.initInternal(Connector.java:912)
        at
org.apache.catalina.util.LifecycleBase.init(LifecycleBase.java:101)
        at
org.apache.catalina.core.StandardService.initInternal(StandardService.java:559)
        at
org.apache.catalina.util.LifecycleBase.init(LifecycleBase.java:101)
        at
org.apache.catalina.core.StandardServer.initInternal(StandardServer.java:781)
        at
org.apache.catalina.util.LifecycleBase.init(LifecycleBase.java:101)
        at org.apache.catalina.startup.Catalina.load(Catalina.java:572)
        at org.apache.catalina.startup.Catalina.load(Catalina.java:595)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)


I really don't understand this problem ...




On Fri, May 20, 2011 at 11:59 AM, André Warnier <a...@ice-sa.com> wrote:

> Micka wrote:
> ...
>
>
>> *Problem 2 :*
>>
>>
>> After  sudo /etc/init.d/tomcat stop , I try again to start the server, but
>> i
>> got :
>>
>> May 19, 2011 4:28:22 PM org.apache.catalina.core.AprLifecycleListener init
>> INFO: The APR based Apache Tomcat Native library which allows optimal
>> performance in production environments was not found on the
>> java.library.pa$
>> May 19, 2011 4:28:22 PM org.apache.coyote.AbstractProtocolHandler init
>> INFO: Initializing ProtocolHandler ["http-bio-8080"]
>> May 19, 2011 4:28:22 PM org.apache.coyote.AbstractProtocolHandler init
>> SEVERE: Failed to initialize end point associated with ProtocolHandler
>> ["http-bio-8080"]
>> java.net.BindException: Address already in use <null>:8080
>>        at
>> org.apache.tomcat.util.net.JIoEndpoint.bind(JIoEndpoint.java:378)
>>
>>
> It means that another instance of Tomcat is already (or still) running.
>
>
>  I don't understand, because sockstat -p 8080 give an empty answer :
>> USER     PROCESS              PID      PROTO  SOURCE ADDRESS
>> FOREIGN ADDRESS           STATE
>>
>>
> Probably just because between the first error, and your "sockstat" command,
> Tomcat really stopped.
>
>
>  And if try to stop again tomcat i got :
>>
>> java.net.ConnectException: Connection refused
>>        at java.net.PlainSocketImpl.socketConnect(Native Method)
>>        at java.net.PlainSocketImpl.doConnect(PlainSocketImpl.java:351)
>>        at
>>
>
> And there again, just a timing issue : Tomcat is not running, si you can't
> stop it.
> (The connection is refused because the "stop" process tries to connect to a
> running Tomcat's port 8005, but since there is no Tomcat running, nothing is
> listening on that port and the connection is refused).
>
> In other words, the important part is your problem #1.
> When you have solved that one, problem #2 will probably go away by itself.
> But for problem #1, I cannot help you.
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
> For additional commands, e-mail: users-h...@tomcat.apache.org
>
>

Reply via email to