IPV6 Tomcat problems (Was Re: Connecting to Jetty)
Richard Cooper
ric at jonnycalcutta.com
Wed May 24 02:58:03 PDT 2006
Joe Shevland wrote:
> This might be relevant (or rather the link near the top to the Sun bug
> database):
>
> http://mail-archives.apache.org/mod_mbox/tomcat-dev/200511.mbox/%3C4375392B.7000306@cognitiongroup.biz%3E
>
>
> and this JBoss wiki entry says it a bit better wrt releases up to JDK 5:
>
> http://wiki.jboss.org/wiki/Wiki.jsp?page=IPv6
>
> So maybe try:
>
> java -Djava.net.preferIPv4Stack=true ...
This is where I got to (almost) - but it doesn't seem to make any
difference.
I have tomcat55_java_opts="-Djava.net.preferIPv4Stack=true" in rc.conf.
When that didn't work I tried taking INET6 out of the kernel completely.
Then I took all ipv6 references out of the hosts file (I'm getting
desperate, you can see).
I still consistently get the following in the logs (everything starts
fine until this point).
SEVERE: StandardServer.await: create[8005]:
java.net.BindException: Can't assign requested address
at java.net.PlainSocketImpl.socketBind(Native Method)
at java.net.PlainSocketImpl.bind(PlainSocketImpl.java:359)
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:343
at org.apache.catalina.startup.Catalina.await(Catalina.java:600)
at org.apache.catalina.startup.Catalina.start(Catalina.java:560)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.
at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
at java.lang.reflect.Method.invoke(Method.java:585)
at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:275)
at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:413)
There are definitely no services running on that port (netstat
confirms...) and the error seems consistent with other encountering the
ipv6 problems.
I'm not sure what I'm doing wrong, but I'm prepared to accept that it's
something dumb.
Thanks
Richard
More information about the freebsd-java
mailing list