Debian updates which block Java RMI (Tomcat / Jameica / Hibiscus for example and other Socket Binding)

I noticed that from one point to another some programs which uses ports, stopped working.

The Java Exception has got parts like this:

"java.rmi.server.ExportException: Listen failed on port: 0;"

Some problem happens with Tomcat Servers:

StandardServer.await: create[localhost: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.(ServerSocket.java:185)
at org.apache.catalina.core.StandardServer.await(StandardServer.java:381)
at org.apache.catalina.startup.Catalina.await(Catalina.java:672)
at org.apache.catalina.startup.Catalina.start(Catalina.java:625)
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:290)
at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:418)

You get the same problems with Java Jetty (and so all depending libs like Apache tuscany).
The same issues hold up NFS to be mountable without disabling locking. So if you notice problems with that Programms, try the following setting:

Modify your

/etc/sysctl.d/bindv6only.conf

and change 'net.ipv6.bindv6only = 1' to

'net.ipv6.bindv6only = 0'

alternativ you can change this without restart with

sysctl -w net.ipv6.bindv6only=0

After a reboot everything should work fine again.

Statusupdates about this bug can be found on the Debian Bugtracker.

alternativ you can use

-Djava.net.preferIPv4Stack=true