开发者

Can't start Tomcat 6.0.26 after update to Debian Squeeze

Working Tomcat setup stopped working after dist-upgrade on Debian (to Squeeze). 8005 is the shutdown port but it is not occupied. Any ideas on what it may be? It's not quite self-speaking exception. This is log from catalina:

org.apache.catalina.core.StandardServer await
SEVERE: StandardServer.await: create[8005]:                          
java.net.SocketException: Invalid argument                                      
        at java.net.PlainSocketImpl.socketBind(Native Method)        
        at java.net.PlainSocketImpl.bind(PlainSocketImpl.java:365)
        at java.net.ServerSocket.bind(ServerSocket.java:319)
        at java.net.ServerSocket.<init>(ServerSocket.java:185)
        at org.apache.catalina.core.StandardServer.await(StandardServer.java:373)
        at org.apache.catalina.startup.Catalina.awai开发者_高级运维t(Catalina.java:662)
        at org.apache.catalina.startup.Catalina.start(Catalina.java:614)
        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.start(Bootstrap.java:289)
        at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:414)


Problem solved, it's related to some IPv6 stuff so to skip this you need to add -Djava.net.preferIPv4Stack=true option to JAVA_OPTS variable in catalina.sh script or alter kernel configuration. More on this:

http://confluence.atlassian.com/pages/viewpage.action?pageId=214863647


According to this bug report, http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=572048

It is preferable to: echo 0 > /proc/sys/net/ipv6/bindv6only and committing that to: /etc/sysctl.d/bindv6only.conf

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜