From owner-freebsd-java@FreeBSD.ORG Sun May 27 03:53:41 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 F3B76106564A; Sun, 27 May 2012 03:53:40 +0000 (UTC) (envelope-from glewis@FreeBSD.org) Received: from freefall.freebsd.org (freefall.freebsd.org [IPv6:2001:4f8:fff6::28]) by mx1.freebsd.org (Postfix) with ESMTP id C84B38FC12; Sun, 27 May 2012 03:53:40 +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 q4R3reVc061462; Sun, 27 May 2012 03:53:40 GMT (envelope-from glewis@freefall.freebsd.org) Received: (from glewis@localhost) by freefall.freebsd.org (8.14.5/8.14.5/Submit) id q4R3reEF061458; Sun, 27 May 2012 03:53:40 GMT (envelope-from glewis) Date: Sun, 27 May 2012 03:53:40 GMT Message-Id: <201205270353.q4R3reEF061458@freefall.freebsd.org> To: bas@kompasmedia.nl, glewis@FreeBSD.org, freebsd-java@FreeBSD.org From: glewis@FreeBSD.org Cc: Subject: Re: ports/166996: java/openjdk6 should depend on archivers/unzip 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: Sun, 27 May 2012 03:53:41 -0000 Synopsis: java/openjdk6 should depend on archivers/unzip State-Changed-From-To: open->closed State-Changed-By: glewis State-Changed-When: Sun May 27 03:53:02 UTC 2012 State-Changed-Why: I've committed a change I think should fix this. I don't have a 9.x system to check on though. Please let me know if the problem persists. http://www.freebsd.org/cgi/query-pr.cgi?pr=166996 From owner-freebsd-java@FreeBSD.ORG Sun May 27 04:00:12 2012 Return-Path: Delivered-To: freebsd-java@hub.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 71FE2106566B for ; Sun, 27 May 2012 04:00: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 479958FC12 for ; Sun, 27 May 2012 04:00: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 q4R40Arw061671 for ; Sun, 27 May 2012 04:00:10 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.14.5/8.14.5/Submit) id q4R40AAF061670; Sun, 27 May 2012 04:00:10 GMT (envelope-from gnats) Date: Sun, 27 May 2012 04:00:10 GMT Message-Id: <201205270400.q4R40AAF061670@freefall.freebsd.org> To: freebsd-java@FreeBSD.org From: dfilter@FreeBSD.ORG (dfilter service) Cc: Subject: Re: ports/166996: commit references a PR X-BeenThere: freebsd-java@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: dfilter service List-Id: Porting Java to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 27 May 2012 04:00:12 -0000 The following reply was made to PR ports/166996; it has been noted by GNATS. From: dfilter@FreeBSD.ORG (dfilter service) To: bug-followup@FreeBSD.org Cc: Subject: Re: ports/166996: commit references a PR Date: Sun, 27 May 2012 03:51:28 +0000 (UTC) glewis 2012-05-27 03:51:15 UTC FreeBSD ports repository Modified files: java/openjdk6 Makefile Log: . Specifically reference zip/unzip in ${LOCALBASE}/bin, since that is where the JDK build looks for them, but FreeBSD 9.x has them available in /usr/bin. Adjusting the JDK check is a harder fix, this will get things building again on 9.x quickly. PR: 166996 Revision Changes Path 1.64 +2 -2 ports/java/openjdk6/Makefile _______________________________________________ cvs-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/cvs-all To unsubscribe, send any mail to "cvs-all-unsubscribe@freebsd.org" From owner-freebsd-java@FreeBSD.ORG Mon May 28 11:07:31 2012 Return-Path: Delivered-To: freebsd-java@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id B2A67106564A for ; Mon, 28 May 2012 11:07:31 +0000 (UTC) (envelope-from owner-bugmaster@FreeBSD.org) Received: from freefall.freebsd.org (freefall.freebsd.org [IPv6:2001:4f8:fff6::28]) by mx1.freebsd.org (Postfix) with ESMTP id 842228FC21 for ; Mon, 28 May 2012 11:07:31 +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 q4SB7VbY063395 for ; Mon, 28 May 2012 11:07:31 GMT (envelope-from owner-bugmaster@FreeBSD.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.14.5/8.14.5/Submit) id q4SB7USN063393 for freebsd-java@FreeBSD.org; Mon, 28 May 2012 11:07:30 GMT (envelope-from owner-bugmaster@FreeBSD.org) Date: Mon, 28 May 2012 11:07:30 GMT Message-Id: <201205281107.q4SB7USN063393@freefall.freebsd.org> X-Authentication-Warning: freefall.freebsd.org: gnats set sender to owner-bugmaster@FreeBSD.org using -f From: FreeBSD bugmaster To: freebsd-java@FreeBSD.org Cc: Subject: Current problem reports assigned to freebsd-java@FreeBSD.org 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, 28 May 2012 11:07:31 -0000 Note: to view an individual PR, use: http://www.freebsd.org/cgi/query-pr.cgi?pr=(number). The following is a listing of current problems submitted by FreeBSD users. These represent problem reports covering all versions including experimental development code and obsolete releases. S Tracker Resp. Description -------------------------------------------------------------------------------- o ports/167903 java [PATCH] java/openjdk6: Fix build failure in 8.3 jail r o java/166844 java openjdk7 can't open library when remote debug enabled o ports/162991 java java/openjdk6 fails to build o java/162522 java OpenJDK 6 is not setting close on exec o java/160553 java Jaikoz java based audio tagger core dumps o ports/159787 java java/openjdk6 nio muti-thread bug o ports/155657 java java/openjdk6: missing symlink for include/freebsd/* o ports/154884 java java/openjdk6: Every NetBeans version on FreeBSD 8.1 c o ports/151923 java [patch] java/openjdk6: free and native openjdk bootstr o ports/151042 java [patch] java/openjdk6 Respect CC o java/147512 java Crash of RXTX-2.1-7 on AMD64 system o java/138729 java java/jdk16: setting 'export AWT_TOOLKIT=MToolkit' caus o java/138728 java java/jdk16: SIGSEGV in java runtime o java/128948 java java/jdk16 built from source can't bind a socket, but o java/128809 java JVM aborted when GNU RXTX write to serial port. o java/123555 java linux-sun-jdk15, linux-sun-jdk16 produce a coredump o java/122513 java native JDKs unbuildable with Linux ones f java/121692 java java/jdk16: Java 1.5 1.5.0.14p8 crashes in RMI TCP Con o java/120146 java java/jdk15: netbeans 6.0 causes java core dump on amd6 o ports/119732 java java/linux-sun-jre16: linux-sun-jre16 plugin doesn't w o java/119063 java An unexpected error has been detected by Java Runtime o java/116667 java linux-sun-javac1.4 hangs on SMP o ports/116082 java java/linux-sun-jdk16 jconsole is unable to connect to o ports/113751 java java/linux-sun-jdk15: linux-sun-jdk-1.5.0.12,2 - java 24 problems total. From owner-freebsd-java@FreeBSD.ORG Tue May 29 00:01:20 2012 Return-Path: Delivered-To: java@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 72ED6106564A for ; Tue, 29 May 2012 00:01:20 +0000 (UTC) (envelope-from euhf@walmart.com) Received: from mail06.syd.optusnet.com.au (mail06.syd.optusnet.com.au [211.29.132.187]) by mx1.freebsd.org (Postfix) with ESMTP id E7D2C8FC14 for ; Tue, 29 May 2012 00:01:19 +0000 (UTC) Received: from WebDemo (static-58-108-218-230.optusnet.com.au [58.108.218.230] (may be forged)) (authenticated sender bgnhirise) by mail06.syd.optusnet.com.au (8.13.1/8.13.1) with ESMTP id q4SNk1aM017201 for ; Tue, 29 May 2012 10:01:17 +1000 Message-Id: <201205290001.q4SNk1aM017201@mail06.syd.optusnet.com.au> From: "Wal~Mart." To: java@FreeBSD.org MIME-Version: 1.0 Date: Tue, 29 May 2012 10:01:17 +1000 Content-Type: text/plain Content-Transfer-Encoding: quoted-printable X-Content-Filtered-By: Mailman/MimeDel 2.1.5 Cc: Subject: Job 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: Tue, 29 May 2012 00:01:20 -0000 - This mail is in HTML. Some elements may be ommited in plain text. - Wal~Mart is looking for A M y s t e r y S h o p p e r to hel= p us evaluate our services in your area. Please visit our page to SignUp =2E. From owner-freebsd-java@FreeBSD.ORG Tue May 29 10:40:41 2012 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 592A2106564A for ; Tue, 29 May 2012 10:40:41 +0000 (UTC) (envelope-from Kustaa.Nyholm@planmeca.com) Received: from fsmsg.planmeca.com (fsmsg.planmeca.com [193.94.173.206]) by mx1.freebsd.org (Postfix) with ESMTP id C08868FC12 for ; Tue, 29 May 2012 10:40:40 +0000 (UTC) Received: from srvfihkiexh01.pmgroup.local ([172.26.0.107]) by fsmsg.planmeca.com (8.14.5/8.14.5) with ESMTP id q4TAedTo000932 for ; Tue, 29 May 2012 13:40:39 +0300 Received: from SRVFIHKIEXB01.pmgroup.local ([172.26.0.201]) by srvfihkiexh01.pmgroup.local ([172.26.0.107]) with mapi; Tue, 29 May 2012 13:40:38 +0300 From: Kustaa Nyholm To: "freebsd-java@freebsd.org" Date: Tue, 29 May 2012 13:40:36 +0300 Thread-Topic: tcgetattr hangs Thread-Index: Ac09h3xekCYHHK4aRfyv6ViR+Dr+Tw== Message-ID: Accept-Language: en-US, fi-FI Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: user-agent: Microsoft-MacOutlook/14.0.0.100825 acceptlanguage: en-US, fi-FI Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10432:5.6.7580, 1.0.260, 0.0.0000 definitions=2012-05-29_03:2012-05-21, 2012-05-29, 1970-01-01 signatures=0 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 spamscore=0 ipscore=0 suspectscore=0 phishscore=0 bulkscore=0 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=7.0.1-1112030000 definitions=main-1205290068 Subject: tcgetattr hangs 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: Tue, 29 May 2012 10:40:41 -0000 Hi, this maybe wrong list but it was suggested I try my luck here. MY feeling is that this NOT a Java issue per se but here goes. I'm the developer of PureJavaComm (PJC) , a pure Java serial port access library that runs on Mac OS X, Linux, Windows and soon I hope on FreeBSD. I'm co-operating with someone to port the library to FreeBSD but we have run into mysterious problem that has defeated all our debugging efforts. PJC can be found at: https://github.com/nyholku/purejavacomm Some background. PJC uses JNA which is a library to access C-code APIs from Java by writing Java classes that JNA automatically turns in to standard C calls. The C functions we are using are very simple and few, here is the complete list to put you into the picture (btw, this is Java): int errno(); int fcntl(int fd, int cmd, int arg); int cfgetispeed(Termios termios); int cfgetospeed(Termios termios); int setspeed(int fd, int speed); int cfsetispeed(Termios termios, int speed); int cfsetospeed(Termios termios, int speed) int tcflush(int fd, int b); int tcdrain(int fd); void cfmakeraw(Termios termios); int tcgetattr(int fd, Termios termios); int tcsetattr(int fd, int cmd, Termios termios); int tcsendbreak(int fd, int duration); int open(String s, int t); int close(int fd); int write(int fd, byte[] buffer, int len); int read(int fd, byte[] buffer, int len); int ioctl(int fd, int cmd, int[] data); int select(int n, FDSet read, FDSet write, FDSet error, TimeVal timeout); So far we have been able to run PJC testsuite in FreeBSD 32 bit Intel with no problems. Now however, on FreeBSD 64 bit AMD our test set hangs in a call to tcgetattr() in the third test case in our test suite. The first test opens a port and wiggles some control lines, then closes the port. The second test sends and receives a some hundreds of messages using a background thread and select(). This is the test that is causing problem further down the line. After this test the next test (regardless what it is) hangs in a call to tcgetattr() after successfully opening the port. So how can tcgetattr() hang??? I found one reference to a similar problem but no solution: http://freebsd.1045724.n5.nabble.com/Re-cups-bugs-tcgetattr-causes-lockup-i n-USB-backend-on-FreeBSD6-STABLE-td3950285.html Here is a piece of our debug log that shows the calls from Java to the native API showing the end of the successful Test2 and the hang at the beginning of Test3: log: > select(9,[8],[],[],jtermios.TimeVal@6f507fb2) .................................. OK average speed log: < select(9,[],[],[],jtermios.TimeVal@6f507fb2) =3D> 0 log: > select(9,[8],[],[],jtermios.TimeVal@6f507fb2) 18241 b/sec at baud rate 19200 log: > fcntl(8, 3, 0) log: < fcntl(8, 3, 0) =3D> 2 log: > fcntl(8, 4, 6) log: < fcntl(8, 4, 6) =3D> 0 log: > close(8) log: < close(8) =3D> 0 Test3 - transmit all characters log: < select(9,[8],[],[],jtermios.TimeVal@6f507fb2) =3D> -1 log: > open('cuau0',00008006) log: < open('cuau0',00008006) =3D> 8 log: > close(8) log: < close(8) =3D> 0 log: > open('cuau0',00008006) log: < open('cuau0',00008006) =3D> 8 log: > fcntl(8, 3, 0) log: < fcntl(8, 3, 0) =3D> 6 log: > fcntl(8, 4, 2) log: < fcntl(8, 4, 2) =3D> 0 log: > tcgetattr(8,jtermios.Termios@5a77a7f9) All comments welcome. be Kusti From owner-freebsd-java@FreeBSD.ORG Tue May 29 11:03:52 2012 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 CEA091065690 for ; Tue, 29 May 2012 11:03:52 +0000 (UTC) (envelope-from kostikbel@gmail.com) Received: from mail.zoral.com.ua (mx0.zoral.com.ua [91.193.166.200]) by mx1.freebsd.org (Postfix) with ESMTP id 6A0128FC14 for ; Tue, 29 May 2012 11:03:52 +0000 (UTC) Received: from skuns.kiev.zoral.com.ua (localhost [127.0.0.1]) by mail.zoral.com.ua (8.14.2/8.14.2) with ESMTP id q4TB2R6Z006879; Tue, 29 May 2012 14:02:27 +0300 (EEST) (envelope-from kostikbel@gmail.com) Received: from deviant.kiev.zoral.com.ua (kostik@localhost [127.0.0.1]) by deviant.kiev.zoral.com.ua (8.14.5/8.14.5) with ESMTP id q4TB2LsR003097; Tue, 29 May 2012 14:02:21 +0300 (EEST) (envelope-from kostikbel@gmail.com) Received: (from kostik@localhost) by deviant.kiev.zoral.com.ua (8.14.5/8.14.5/Submit) id q4TB2Lt5003096; Tue, 29 May 2012 14:02:21 +0300 (EEST) (envelope-from kostikbel@gmail.com) X-Authentication-Warning: deviant.kiev.zoral.com.ua: kostik set sender to kostikbel@gmail.com using -f Date: Tue, 29 May 2012 14:02:20 +0300 From: Konstantin Belousov To: Kustaa Nyholm Message-ID: <20120529110220.GI2358@deviant.kiev.zoral.com.ua> References: Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="lE3gG894P96VuAc/" Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.4.2.3i X-Virus-Scanned: clamav-milter 0.95.2 at skuns.kiev.zoral.com.ua X-Virus-Status: Clean X-Spam-Status: No, score=-3.8 required=5.0 tests=ALL_TRUSTED,AWL,BAYES_00, URI_HEX autolearn=no version=3.2.5 X-Spam-Checker-Version: SpamAssassin 3.2.5 (2008-06-10) on skuns.kiev.zoral.com.ua Cc: "freebsd-java@freebsd.org" Subject: Re: tcgetattr hangs 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: Tue, 29 May 2012 11:03:52 -0000 --lE3gG894P96VuAc/ Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Tue, May 29, 2012 at 01:40:36PM +0300, Kustaa Nyholm wrote: > Hi, >=20 > this maybe wrong list but it was suggested I try my luck here. >=20 > MY feeling is that this NOT a Java issue per se but here goes. >=20 > I'm the developer of PureJavaComm (PJC) , a pure Java serial port access > library that runs on Mac OS X, Linux, Windows and soon I hope on > FreeBSD. I'm co-operating with someone to port the library to > FreeBSD but we have run into mysterious problem that has defeated > all our debugging efforts. >=20 > PJC can be found at: >=20 > https://github.com/nyholku/purejavacomm >=20 > Some background. PJC uses JNA which is a library to access C-code > APIs from Java by writing Java classes that JNA automatically > turns in to standard C calls. >=20 > The C functions we are using are very simple and few, here is the complete > list to put you into the picture (btw, this is Java): >=20 > int errno(); > int fcntl(int fd, int cmd, int arg); int cfgetispeed(Termios termios); > int cfgetospeed(Termios termios); > int setspeed(int fd, int speed); > int cfsetispeed(Termios termios, int speed); > int cfsetospeed(Termios termios, int speed) > int tcflush(int fd, int b); > int tcdrain(int fd); > void cfmakeraw(Termios termios); > int tcgetattr(int fd, Termios termios); > int tcsetattr(int fd, int cmd, Termios termios); int tcsendbreak(int fd, > int duration); > int open(String s, int t); int close(int fd); > int write(int fd, byte[] buffer, int len); > int read(int fd, byte[] buffer, int len); > int ioctl(int fd, int cmd, int[] data); > int select(int n, FDSet read, FDSet write, FDSet error, TimeVal timeout); >=20 >=20 >=20 > So far we have been able to run PJC testsuite in FreeBSD 32 bit Intel with > no problems. >=20 > Now however, on FreeBSD 64 bit AMD our test set hangs in a call to > tcgetattr() > in the third test case in our test suite. >=20 > The first test opens a port and wiggles some control lines, then closes > the port. > The second test sends and receives a some hundreds of messages using a > background > thread and select(). This is the test that is causing problem further down > the line. > After this test the next test (regardless what it is) hangs in a call to > tcgetattr() > after successfully opening the port. >=20 > So how can tcgetattr() hang??? >=20 > I found one reference to a similar problem but no solution: >=20 > http://freebsd.1045724.n5.nabble.com/Re-cups-bugs-tcgetattr-causes-lockup= -i > n-USB-backend-on-FreeBSD6-STABLE-td3950285.html >=20 > Here is a piece of our debug log that shows the calls from Java to the > native > API showing the end of the successful Test2 and the hang at the beginning > of Test3: >=20 > log: > select(9,[8],[],[],jtermios.TimeVal@6f507fb2) > .................................. OK average speed log: < > select(9,[],[],[],jtermios.TimeVal@6f507fb2) =3D> 0 > log: > select(9,[8],[],[],jtermios.TimeVal@6f507fb2) > 18241 b/sec at baud rate 19200 > log: > fcntl(8, 3, 0) > log: < fcntl(8, 3, 0) =3D> 2 > log: > fcntl(8, 4, 6) > log: < fcntl(8, 4, 6) =3D> 0 > log: > close(8) > log: < close(8) =3D> 0 > Test3 - transmit all characters log: < > select(9,[8],[],[],jtermios.TimeVal@6f507fb2) =3D> -1 > log: > open('cuau0',00008006) > log: < open('cuau0',00008006) =3D> 8 > log: > close(8) > log: < close(8) =3D> 0 > log: > open('cuau0',00008006) > log: < open('cuau0',00008006) =3D> 8 > log: > fcntl(8, 3, 0) > log: < fcntl(8, 3, 0) =3D> 6 > log: > fcntl(8, 4, 2) > log: < fcntl(8, 4, 2) =3D> 0 > log: > tcgetattr(8,jtermios.Termios@5a77a7f9) >=20 >=20 > All comments welcome. Verify that the thread indeed hang in ioctl, executed on the right file descriptor and TIOCGETA ioctl command. You may use ktrace(1) or truss(1) for this. If ioctl(TIOCGETA) is indeed what was called, then look at the in-kernel backtrace of the hung thread with procstat -kk command. --lE3gG894P96VuAc/ Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.12 (FreeBSD) iEYEARECAAYFAk/ErLwACgkQC3+MBN1Mb4jwqgCgr3FBoSULFVhfdctM6w8pl2+D LSsAoJJJnd0kOLQmn0jgEaQcNGMAhgdD =3nNE -----END PGP SIGNATURE----- --lE3gG894P96VuAc/-- From owner-freebsd-java@FreeBSD.ORG Tue May 29 12:05:10 2012 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 B0F031065813 for ; Tue, 29 May 2012 12:05:10 +0000 (UTC) (envelope-from Kustaa.Nyholm@planmeca.com) Received: from fsmsg.planmeca.com (fsmsg.planmeca.com [193.94.173.206]) by mx1.freebsd.org (Postfix) with ESMTP id 037538FC1B for ; Tue, 29 May 2012 12:05:09 +0000 (UTC) Received: from srvfihkiexh01.pmgroup.local ([172.26.0.107]) by fsmsg.planmeca.com (8.14.5/8.14.5) with ESMTP id q4TC58OL005589 for ; Tue, 29 May 2012 15:05:08 +0300 Received: from SRVFIHKIEXB01.pmgroup.local ([172.26.0.201]) by srvfihkiexh01.pmgroup.local ([172.26.0.107]) with mapi; Tue, 29 May 2012 15:05:07 +0300 From: Kustaa Nyholm To: "freebsd-java@freebsd.org" Date: Tue, 29 May 2012 15:05:05 +0300 Thread-Topic: tcgetattr hangs Thread-Index: Ac09k0miVQ1dONPGRGKNRnSJqPCdGg== Message-ID: In-Reply-To: <20120529110220.GI2358@deviant.kiev.zoral.com.ua> Accept-Language: en-US, fi-FI Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: user-agent: Microsoft-MacOutlook/14.0.0.100825 acceptlanguage: en-US, fi-FI Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10432:5.6.7580, 1.0.260, 0.0.0000 definitions=2012-05-29_03:2012-05-21, 2012-05-29, 1970-01-01 signatures=0 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 spamscore=0 ipscore=0 suspectscore=0 phishscore=0 bulkscore=0 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=7.0.1-1112030000 definitions=main-1205290093 Subject: Re: tcgetattr hangs 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: Tue, 29 May 2012 12:05:11 -0000 On 5/29/12 14:02, "Konstantin Belousov" wrote: > >Verify that the thread indeed hang in ioctl, executed on the right >file descriptor and TIOCGETA ioctl command. You may use ktrace(1) >or truss(1) for this. > >If ioctl(TIOCGETA) is indeed what was called, then look at the in-kernel >backtrace of the hung thread with procstat -kk command. > Thanks, have not tried those yet, we will try that. br Kusti From owner-freebsd-java@FreeBSD.ORG Wed May 30 21:53:44 2012 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 5EBF01065672 for ; Wed, 30 May 2012 21:53:44 +0000 (UTC) (envelope-from bsd-src@helfman.org) Received: from mail-pb0-f54.google.com (mail-pb0-f54.google.com [209.85.160.54]) by mx1.freebsd.org (Postfix) with ESMTP id 26C928FC16 for ; Wed, 30 May 2012 21:53:43 +0000 (UTC) Received: by pbbro2 with SMTP id ro2so588063pbb.13 for ; Wed, 30 May 2012 14:53:43 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=sender:date:from:to:cc:subject:message-id:references:mime-version :content-type:content-disposition:in-reply-to:x-operating-system :organization:x-living-the-dream:x-pgp-fingerprint:x-pgp-key :user-agent:x-gm-message-state; bh=K5R5/Pa3Bg49rhwbr0eIqFZIS4GjsutrQ0cP5pLlh40=; b=Fp7zmt+KHSSz2cUneIplhxir9uWqdbZCuxW8NUavB8o6j5wY21iIxX+4rgjNvcs1MT iKwoM3biK4Wk+wOR938kMwhftKAAhZBE+f6qWrBj2EVAGWSiS3CYuvwMYeadP5XxqBBI ObxA5q9QWKai8a2MDoBcXNZrlOMPV4CKQx6JxE/AdQeWdWcTEqQnw25C915JBda3R5ut Eg7H/y5bvog2DG5tEiywRUqay7AUUGw18lICc5BaRu2NhH7DTahxBDODWNgspf2xa+9L FJf1eRE1p3AWP/fcgwcGnY8SB/f+djkwlk7ppCBhi1+XvrRfriZIrM23rd3E40Qa097H dkxA== Received: by 10.68.218.7 with SMTP id pc7mr7849pbc.88.1338414823792; Wed, 30 May 2012 14:53:43 -0700 (PDT) Received: from dormouse.experts-exchange.com ([72.29.164.238]) by mx.google.com with ESMTPS id ny10sm1758139pbb.38.2012.05.30.14.53.42 (version=TLSv1/SSLv3 cipher=OTHER); Wed, 30 May 2012 14:53:42 -0700 (PDT) Sender: Jason Helfman Date: Wed, 30 May 2012 14:52:17 -0700 From: Jason Helfman To: glewis@FreeBSD.org Message-ID: <20120530215217.GF47837@dormouse.experts-exchange.com> References: <201205270353.q4R3reEF061458@freefall.freebsd.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii; format=flowed Content-Disposition: inline In-Reply-To: <201205270353.q4R3reEF061458@freefall.freebsd.org> X-Operating-System: FreeBSD 8.3-RELEASE amd64 Organization: The FreeBSD Project, http://www.freebsd.org X-Living-The-Dream: I love the SLO Life! X-PGP-FingerPrint: 8E0D C457 9A0F C91C 23F3 0454 2059 9A63 4150 D3DC X-PGP-Key: http://people.freebsd.org/~jgh/jgh.asc User-Agent: Mutt/1.5.21 (2010-09-15) X-Gm-Message-State: ALoCoQkJOF8HC6BWmNugzVXB35vD+K2tssR+C3sNObWiKVUChVgNpJsCgrt3DXWzW3Oom70UbOVS Cc: bas@kompasmedia.nl, bug-followup@freebsd.org, freebsd-java@FreeBSD.org Subject: Re: ports/166996: java/openjdk6 should depend on archivers/unzip 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: Wed, 30 May 2012 21:53:44 -0000 I've confirmed that this issue is now fixed by building on a clean system. -jgh -- Jason Helfman FreeBSD Committer | http://people.freebsd.org/~jgh | The Power To Serve From owner-freebsd-java@FreeBSD.ORG Wed May 30 22:00:17 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 9705E1065675 for ; Wed, 30 May 2012 22:00:17 +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 597768FC0C for ; Wed, 30 May 2012 22:00:17 +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 q4UM0HJt064557 for ; Wed, 30 May 2012 22:00:17 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.14.5/8.14.5/Submit) id q4UM0Hfp064556; Wed, 30 May 2012 22:00:17 GMT (envelope-from gnats) Date: Wed, 30 May 2012 22:00:17 GMT Message-Id: <201205302200.q4UM0Hfp064556@freefall.freebsd.org> To: freebsd-java@FreeBSD.org From: Jason Helfman Cc: Subject: Re: ports/166996: java/openjdk6 should depend on archivers/unzip X-BeenThere: freebsd-java@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: Jason Helfman List-Id: Porting Java to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 30 May 2012 22:00:17 -0000 The following reply was made to PR ports/166996; it has been noted by GNATS. From: Jason Helfman To: glewis@FreeBSD.org Cc: bas@kompasmedia.nl, freebsd-java@FreeBSD.org, bug-followup@freebsd.org Subject: Re: ports/166996: java/openjdk6 should depend on archivers/unzip Date: Wed, 30 May 2012 14:52:17 -0700 I've confirmed that this issue is now fixed by building on a clean system. -jgh -- Jason Helfman FreeBSD Committer | http://people.freebsd.org/~jgh | The Power To Serve From owner-freebsd-java@FreeBSD.ORG Fri Jun 1 18:03:18 2012 Return-Path: Delivered-To: freebsd-java@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id DD8B2106566C for ; Fri, 1 Jun 2012 18:03:18 +0000 (UTC) (envelope-from Kustaa.Nyholm@planmeca.com) Received: from fsmsg.planmeca.com (fsmsg.planmeca.com [193.94.173.206]) by mx1.freebsd.org (Postfix) with ESMTP id 39DC38FC18 for ; Fri, 1 Jun 2012 18:03:18 +0000 (UTC) Received: from srvfihkiexh01.pmgroup.local ([172.26.0.107]) by fsmsg.planmeca.com (8.14.5/8.14.5) with ESMTP id q51I33MO017055 for ; Fri, 1 Jun 2012 21:03:10 +0300 Received: from SRVFIHKIEXB01.pmgroup.local ([172.26.0.201]) by srvfihkiexh01.pmgroup.local ([172.26.0.107]) with mapi; Fri, 1 Jun 2012 21:03:03 +0300 From: Kustaa Nyholm To: "freebsd-java@freebsd.org" Date: Fri, 1 Jun 2012 21:03:00 +0300 Thread-Topic: tcgetattr hangs Thread-Index: Ac1AIMnxcobL2aSgQzeUCTdzbfdtFw== Message-ID: In-Reply-To: <20120529110220.GI2358@deviant.kiev.zoral.com.ua> Accept-Language: en-US, fi-FI Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: user-agent: Microsoft-MacOutlook/14.0.0.100825 acceptlanguage: en-US, fi-FI Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10432:5.6.7580, 1.0.260, 0.0.0000 definitions=2012-06-01_05:2012-05-21, 2012-06-01, 1970-01-01 signatures=0 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 spamscore=0 ipscore=0 suspectscore=0 phishscore=0 bulkscore=0 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=7.0.1-1112030000 definitions=main-1206010193 Subject: Re: tcgetattr hangs 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: Fri, 01 Jun 2012 18:03:18 -0000 On 5/29/12 14:02, "Konstantin Belousov" wrote: >>Here is a piece of our debug log that shows the calls from Java to the >>native >>API showing the end of the successful Test2 and the hang at the >>beginning >>of Test3: >>log: > select(9,[8],[],[],jtermios.TimeVal@6f507fb2) >>.................................. OK average speed log: < >>select(9,[],[],[],jtermios.TimeVal@6f507fb2) =3D> 0 >>log: > select(9,[8],[],[],jtermios.TimeVal@6f507fb2) >>18241 b/sec at baud rate 19200 >>log: > fcntl(8, 3, 0) >>log: < fcntl(8, 3, 0) =3D> 2 >>log: > fcntl(8, 4, 6) >>log: < fcntl(8, 4, 6) =3D> 0 >>log: > close(8) >>log: < close(8) =3D> 0 >>Test3 - transmit all characters log: < >>select(9,[8],[],[],jtermios.TimeVal@6f507fb2) =3D> -1 >>log: > open('cuau0',00008006) >>log: < open('cuau0',00008006) =3D> 8 >>log: > close(8) >>log: < close(8) =3D> 0 >>log: > open('cuau0',00008006) >>log: < open('cuau0',00008006) =3D> 8 >>log: > fcntl(8, 3, 0) >>log: < fcntl(8, 3, 0) =3D> 6 >>log: > fcntl(8, 4, 2) >>log: < fcntl(8, 4, 2) =3D> 0 >>log: > tcgetattr(8,jtermios.Termios@5a77a7f9) >>All comments welcome. > >Verify that the thread indeed hang in ioctl, executed on the right >file descriptor and TIOCGETA ioctl command. You may use ktrace(1) >or truss(1) for this. > >If ioctl(TIOCGETA) is indeed what was called, then look at the in-kernel >backtrace of the hung thread with procstat -kk command. > Ok, we managed to do a ktrace and below is the relevant part of the log. It looks like the ioctl(TIOCGETA)/tcgetattr was indeed succesfully completed but the Java code then hangs (or atleast we are not able to see anything on the Java side of things, evidently something keeps causing entries in the log. Can anyone hazard an opinion on what the log is showing? br Kusti 22683 100350 java RET F64 sigaction 0 22683 100350 java CALL F64 sigaction(SIGSEGV,0x7fffffbfe030,0x7fffffbfe010) 22683 100350 java RET F64 sigaction 0 22683 100350 java CALL F64 sigaction(SIGBUS,0x7fffffbfe030,0x7fffffbfe010) 22683 100350 java RET F64 sigaction 0 22683 100350 java CALL F64 sigprocmask(SIG_BLOCK,0,0x80fb60228) 22683 100350 java RET F64 sigprocmask 0 22683 100350 java CALL F64 sigaction(SIGSEGV,0x7fffffbfe030,0x7fffffbfe010) 22683 100350 java RET F64 sigaction 0 22683 100350 java CALL F64 sigaction(SIGBUS,0x7fffffbfe030,0x7fffffbfe010) 22683 100350 java RET F64 sigaction 0 22683 100350 java CALL F64 sigaction(SIGSEGV,0x7fffffbfe100,0x7fffffbfe0e0) 22683 100350 java RET F64 sigaction 0 22683 100350 java CALL F64 sigaction(SIGBUS,0x7fffffbfe100,0x7fffffbfe0e0) 22683 100350 java RET F64 sigaction 0 22683 100350 java CALL F64 sigprocmask(SIG_BLOCK,0,0x80fb60228) 22683 100350 java RET F64 sigprocmask 0 22683 100350 java CALL F64 ioctl(0x8,TIOCGETA,0x80fe4f940) 22683 100350 java RET F64 ioctl 0 22683 100350 java CALL F64 sigaction(SIGSEGV,0x7fffffbfe100,0x7fffffbfe0e0) 22683 100350 java RET F64 sigaction 0 22683 100350 java CALL F64 sigaction(SIGBUS,0x7fffffbfe100,0x7fffffbfe0e0) 22683 100350 java RET F64 sigaction 0 after which following keeps repeating endlessly: 22683 100350 java PSIG F64 SIGSEGV caught handler=3D0x80fa4f9f0 mask=3D0x4 code=3D0x1 22683 100350 java CALL F64 sigprocmask(SIG_SETMASK,0x7fffffbfde30,0) 22683 100350 java RET F64 sigprocmask 0 22683 100350 java CALL F64 sigaction(SIGSEGV,0x7fffffbfe100,0x7fffffbfe0e0) 22683 100350 java RET F64 sigaction 0 22683 100350 java CALL F64 sigaction(SIGBUS,0x7fffffbfe100,0x7fffffbfe0e0) 22683 100350 java RET F64 sigaction 0 22683 100350 java PSIG F64 SIGSEGV caught handler=3D0x80fa4f9f0 mask=3D0x4 code=3D0x1 22683 100350 java CALL F64 sigprocmask(SIG_SETMASK,0x7fffffbfdca0,0) 22683 100350 java RET F64 sigprocmask 0 22683 100350 java CALL F64 sigaction(SIGSEGV,0x7fffffbfe100,0x7fffffbfe0e0) 22683 100350 java RET F64 sigaction 0 22683 100350 java CALL F64 sigaction(SIGBUS,0x7fffffbfe100,0x7fffffbfe0e0) 22683 100350 java RET F64 sigaction 0 22683 100350 java PSIG F64 SIGSEGV caught handler=3D0x80fa4f9f0 mask=3D0x4 code=3D0x1 So acting on this suggestion: >"If ioctl(TIOCGETA) is indeed what was called, then look at the in-kernel >backtrace of the hung thread with procstat -kk command." =20 This is from an different hang, though: procstat -kk 19315 PID TID COMM TDNAME KSTACK 19315 100112 java - 19315 100443 java - mi_switch+0x186 sleepq_catch_signals+0x31c sleepq_timedwait_sig+0x19 _sleep+0x2d1 do_cv_wait+0x630 __umtx_op_cv_wait+0x66 amd64_syscall+0x24f Xfast_syscall+0xfc 19315 100519 java - mi_switch+0x186 sleepq_catch_signals+0x31c sleepq_wait_sig+0x16 _sleep+0x29a do_cv_wait+0x861 __umtx_op_cv_wait+0x66 amd64_syscall+0x24f Xfast_syscall+0xfc 19315 100622 java - mi_switch+0x186 sleepq_catch_signals+0x31c sleepq_wait_sig+0x16 _sleep+0x29a do_cv_wait+0x861 __umtx_op_cv_wait+0x66 amd64_syscall+0x24f Xfast_syscall+0xfc 19315 100645 java - mi_switch+0x186 sleepq_catch_signals+0x31c sleepq_wait_sig+0x16 _sleep+0x29a do_wait+0x71a __umtx_op_wait_uint_private+0x6e amd64_syscall+0x24f Xfast_syscall+0xfc 19315 100708 java initial thread mi_switch+0x186 sleepq_catch_signals+0x31c sleepq_wait_sig+0x16 _sleep+0x29a do_wait+0x71a __umtx_op_wait+0x68 amd64_syscall+0x24f Xfast_syscall+0xfc 19315 100763 java - mi_switch+0x186 sleepq_catch_signals+0x31c sleepq_wait_sig+0x16 _sleep+0x29a do_cv_wait+0x861 __umtx_op_cv_wait+0x66 amd64_syscall+0x24f Xfast_syscall+0xfc 19315 100769 java - mi_switch+0x186 sleepq_catch_signals+0x31c sleepq_wait_sig+0x16 _sleep+0x29a do_cv_wait+0x861 __umtx_op_cv_wait+0x66 amd64_syscall+0x24f Xfast_syscall+0xfc 19315 100775 java - mi_switch+0x186 sleepq_catch_signals+0x31c sleepq_wait_sig+0x16 _sleep+0x29a do_cv_wait+0x861 __umtx_op_cv_wait+0x66 amd64_syscall+0x24f Xfast_syscall+0xfc 19315 100789 java - mi_switch+0x186 sleepq_catch_signals+0x31c sleepq_timedwait_sig+0x19 _sleep+0x2d1 do_cv_wait+0x630 __umtx_op_cv_wait+0x66 amd64_syscall+0x24f Xfast_syscall+0xfc