From owner-freebsd-java@FreeBSD.ORG Mon Mar 12 01:50:10 2012 Return-Path: Delivered-To: freebsd-java@hub.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 9D1CA106566B for ; Mon, 12 Mar 2012 01:50:10 +0000 (UTC) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (freefall.freebsd.org [IPv6:2001:4f8:fff6::28]) by mx1.freebsd.org (Postfix) with ESMTP id 75BD48FC14 for ; Mon, 12 Mar 2012 01:50:10 +0000 (UTC) Received: from freefall.freebsd.org (localhost [127.0.0.1]) by freefall.freebsd.org (8.14.5/8.14.5) with ESMTP id q2C1oAug022053 for ; Mon, 12 Mar 2012 01:50:10 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.14.5/8.14.5/Submit) id q2C1oAVr022052; Mon, 12 Mar 2012 01:50:10 GMT (envelope-from gnats) Resent-Date: Mon, 12 Mar 2012 01:50:10 GMT Resent-Message-Id: <201203120150.q2C1oAVr022052@freefall.freebsd.org> Resent-From: FreeBSD-gnats-submit@FreeBSD.org (GNATS Filer) Resent-To: freebsd-java@FreeBSD.org Resent-Reply-To: FreeBSD-gnats-submit@FreeBSD.org, Merlin Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id D95DA106564A for ; Mon, 12 Mar 2012 01:46:06 +0000 (UTC) (envelope-from nobody@FreeBSD.org) Received: from red.freebsd.org (red.freebsd.org [IPv6:2001:4f8:fff6::22]) by mx1.freebsd.org (Postfix) with ESMTP id C425F8FC15 for ; Mon, 12 Mar 2012 01:46:06 +0000 (UTC) Received: from red.freebsd.org (localhost [127.0.0.1]) by red.freebsd.org (8.14.4/8.14.4) with ESMTP id q2C1k67M039121 for ; Mon, 12 Mar 2012 01:46:06 GMT (envelope-from nobody@red.freebsd.org) Received: (from nobody@localhost) by red.freebsd.org (8.14.4/8.14.4/Submit) id q2C1k6ei039120; Mon, 12 Mar 2012 01:46:06 GMT (envelope-from nobody) Message-Id: <201203120146.q2C1k6ei039120@red.freebsd.org> Date: Mon, 12 Mar 2012 01:46:06 GMT From: Merlin To: freebsd-gnats-submit@FreeBSD.org X-Send-Pr-Version: www-3.1 Cc: Subject: java/165957: Enabling IPv6 in port java/jdk16 disables IPv4 X-BeenThere: freebsd-java@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Porting Java to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 12 Mar 2012 01:50:10 -0000 >Number: 165957 >Category: java >Synopsis: Enabling IPv6 in port java/jdk16 disables IPv4 >Confidential: no >Severity: serious >Priority: low >Responsible: freebsd-java >State: open >Quarter: >Keywords: >Date-Required: >Class: sw-bug >Submitter-Id: current-users >Arrival-Date: Mon Mar 12 01:50:10 UTC 2012 >Closed-Date: >Last-Modified: >Originator: Merlin >Release: 9.0-RELEASE >Organization: merlinsbox.net >Environment: FreeBSD machine.merlinsbox.net 9.0-RELEASE FreeBSD 9.0-RELEASE #0: Tue Jan 3 07:46:30 UTC 2012 root@farrell.cse.buffalo.edu:/usr/obj/usr/src/sys/GENERIC amd64 >Description: java/jdk16 with IPV6 enabled in configuration caused ipv4 to be disabled. Many applications which used the network all failed, unless dealing with ipv6 addresses. A test case of creating a connected socket and outputting the exception showed an invalid parameter was being passed to a socket call, which lead to the discovery that only ipv4 addresses were affected by this issue. >How-To-Repeat: Built and installed java/jdk16 from ports inside a jail on a build machine, with IPV6, WEB, POLICY, TZUPDATE, and JAIL selected in the configuration. Installed on two machines with the same effect (no ipv4). Namely, the following test program and methodology was used to diagnose the problem: Started netcat listeners like so: $ nc -lk 127.0.0.1 2000 $ nc -lk ::1 2000 // // test.java // built with javac test.java // ran with java test // import java.net.*; public class test { public static void main(String argv[]) { try { // This line was modified to be 127.0.0.1 to test ipv4 new Socket("::1", 2000); System.out.println("Success"); } catch (Exception e) { e.printStackTrace(); } } } // // end test.java // >Fix: Rebuilding the port without IPV6 has fixed IPV4, but now I cannot of course use IPV6. Thankfully, I didn't really NEED it (not like I NEED IPv4 anyway :P). >Release-Note: >Audit-Trail: >Unformatted: