I tried to get Tomcat and JBoss running on FreeBSD 5.3-BETA7. Tomcat would exit after a few seconds and JBoss would run but not listen on any TCP/IP sockets. After being annoyed a little while I remembered a thread on the OpenBSD Java mailinglist about the weird IPv6 support in Java.
The problem is that if Java is compiled with
always creates an
AF_INET6 socket as Otto
Moerbeek explained. So, if embedded IPv4 addresses are available
everything is fine, if not, Java can't talk to IPv4 hosts. I guess it works on
Solaris, perhaps even Windows
and Linux, but not on BSD.
So I recompiled
-DWITH_IPV6 and voila!, it worked. It's just irritating to
have the computer compiling for just over 9½ hours for that, plus
3½ hours for Eclipse which, now that FreeBSD has changed
to GCC 3.4.2 as system compiler,
also depended on the GCC
Amazingly, searching for “IPv6” on bugs.sun.com returns nothing.
Author M. G. Liebach
LastMod 2016-05-01 (9fc4632)