From owner-freebsd-java@FreeBSD.ORG Mon Mar 9 16:29:09 2009 Return-Path: Delivered-To: freebsd-java@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 822E81065B48 for ; Mon, 9 Mar 2009 16:29:09 +0000 (UTC) (envelope-from mikej@rogers.com) Received: from smtp121.rog.mail.re2.yahoo.com (smtp121.rog.mail.re2.yahoo.com [206.190.53.26]) by mx1.freebsd.org (Postfix) with SMTP id 298FE8FC16 for ; Mon, 9 Mar 2009 16:29:09 +0000 (UTC) (envelope-from mikej@rogers.com) Received: (qmail 26750 invoked from network); 9 Mar 2009 16:29:08 -0000 DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=s1024; d=rogers.com; h=Received:X-YMail-OSG:X-Yahoo-Newman-Property:Received:Message-ID:Date:Subject:From:To:User-Agent:MIME-Version:Content-Type:Content-Transfer-Encoding:X-Priority:Importance; b=dUwoDzsB4QLftMe2zqWfnslQ3+PiQJI/iqDJUqETDWFbazuXTPFjcuq1Hl4CSwLQx0/kUWeMHb5ni+R1qa/lCBiP2IoHl97xDgw+RBoqYmJNdX3R9dopG50aLQVQpcsWFQjOjX+okMV3hhKUsBbQn+t4My9EwX924gXs6qL9Mn8= ; Received: from unknown (HELO wettoast.dyndns.org) (mikej@99.227.104.169 with login) by smtp121.rog.mail.re2.yahoo.com with SMTP; 9 Mar 2009 16:29:08 -0000 X-YMail-OSG: BQ9nSu0VM1k5gQm2i39k4Smjliur1jvDxaVWAqBiXfFNWtFXQQ1LIgg1qrIWG_9F7w-- X-Yahoo-Newman-Property: ymail-3 Received: from 38.99.187.34 (SquirrelMail authenticated user mikej) by wettoast.dyndns.org with HTTP; Mon, 9 Mar 2009 12:29:12 -0400 (EDT) Message-ID: Date: Mon, 9 Mar 2009 12:29:12 -0400 (EDT) From: "Mike Jakubik" To: freebsd-java@freebsd.org User-Agent: SquirrelMail/1.4.15 MIME-Version: 1.0 Content-Type: text/plain;charset=iso-8859-1 Content-Transfer-Encoding: 8bit X-Priority: 3 (Normal) Importance: Normal Subject: Problem with Java NIO (java.nio.channels.IllegalBlockingModeException) 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, 09 Mar 2009 16:29:12 -0000 Greetings java users, I have been experiencing a randomly occurring problem with one of my java applications. The application is question is a simple network chat service, used with an online flash game. This application is known to have worked without this problem on Linux for over 2 years now, in multiple deployments. This leads me to believe that either the Linux JDK/network is lax on error checks or there is a problem with the FreeBSD JDK/network implementation. Below is the error that causes the application to stop responding to network requests. --- INFO | jvm 1 | 2009/03/08 21:04:25 | Exception in thread "Thread-0" java.nio.channels.IllegalBlockingModeException INFO | jvm 1 | 2009/03/08 21:04:25 | at sun.nio.ch.ServerSocketAdaptor.accept(ServerSocketAdaptor.java:104) INFO | jvm 1 | 2009/03/08 21:04:25 | at com.precyse.chat.service.connector.ServerSocketChannelConnector.registerSelection(ServerSocketChannelConnector.java:404) INFO | jvm 1 | 2009/03/08 21:04:25 | at com.precyse.chat.service.connector.ServerSocketChannelConnector.run(ServerSocketChannelConnector.java:148) --- http://java.sun.com/j2se/1.4.2/docs/api/java/nio/channels/SelectableChannel.html Unfortunately i do not have access to the source code of this app. I have tried diablo JDK 1.5 and 1.6, as well as the OpenJDK 1.6 port. I am running a recent build of 7.1-AMD64. Any help would be greatly appreciated, i would hate to have to switch to linux because of this. Thank you.