This service will be undergoing maintenance at 00:00 UTC, 2016-08-01. It is expected to last about 1 hours
Bug 492018 - (futex, Java, wait) New java going to futex_wait when launching application that uses Swing [NEEDINFO]
New java going to futex_wait when launching application that uses Swing
Status: CLOSED WORKSFORME
Product: Fedora
Classification: Fedora
Component: java-1.6.0-openjdk (Show other bugs)
10
i686 Linux
low Severity urgent
: ---
: ---
Assigned To: Lillian Angel
Fedora Extras Quality Assurance
:
: 492335 (view as bug list)
Depends On:
Blocks: 713334
  Show dependency treegraph
 
Reported: 2009-03-24 19:48 EDT by Nathan Crubel
Modified: 2015-11-24 22:01 EST (History)
3 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2009-03-27 23:34:53 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
caipei.ccp.chen: needinfo?


Attachments (Terms of Use)

  None (edit)
Description Nathan Crubel 2009-03-24 19:48:52 EDT
Description of problem: When launching a Java application that has Swing.  Java apps goes to futex_wait state and is unusable.  


Version-Release number of selected component (if applicable):
java-1.6.0-openjdk-demo

How reproducible:
Open a Java application that uses Swing

Steps to Reproduce:
1. 
2.
3.
  
Actual results:
Program goes to futex_wait state.

Expected results:
Program is usable

Additional info:
This just started when Fedora 10 updated today to the new java-1.6.0-openjdk
Comment 1 Nathan Crubel 2009-03-24 21:35:08 EDT
This is also happening on x86_64 Fedora 10 installs.  

I am also seeing this with the new JDK from sun.
Comment 2 Nathan Crubel 2009-03-24 23:49:15 EDT
Java applications are working on a system that does not have the latest updates.
Comment 3 renke 2009-03-25 06:42:53 EDT
I can confirm this, neither Sun's JRE nor Fedora's OpenJDK works with my web start applications after I installed the updates
Comment 4 renke 2009-03-25 07:19:42 EDT
as an additional note: after dumping the cache-folder of java and reinstalling the sun rpms everything works again
Comment 5 Omair Majid 2009-03-25 10:19:56 EDT
I cant reproduce this on an i386 with f10 and the latest java packages using the Notepad.jar demo.

$ java -version
java version "1.6.0_0"
IcedTea6 1.4 (fedora-13.b14.fc10-i386) Runtime Environment (build 1.6.0_0-b14)
OpenJDK Client VM (build 14.0-b08, mixed mode)
$ rpm -q java-1.6.0-openjdk
java-1.6.0-openjdk-1.6.0.0-13.b14.fc10.i386
Comment 6 Omair Majid 2009-03-25 10:47:45 EDT
Unable to reproduce with java-1.6.0-openjdk-1.6.0.0-11.b14.fc10.i386.
Comment 7 Nathan Crubel 2009-03-25 11:19:18 EDT
Ok, starting work this morning, I see that it is not Java, but it looks that an imsettings is going to futex wait. Once I killed that process, java applications worked.  This morning I had a lot of applications not work including citrix, VirutalBox and my Java applications.  Once I killed the imsettings that was in futex wait, everything started fine.
Comment 8 Mauri Sahlberg 2009-03-25 15:14:08 EDT
(In reply to comment #7)
> Ok, starting work this morning, I see that it is not Java, but it looks that an
> imsettings is going to futex wait. Once I killed that process, java
> applications worked.  This morning I had a lot of applications not work
> including citrix, VirutalBox and my Java applications.  Once I killed the
> imsettings that was in futex wait, everything started fine.  

Easiest way to reproduce at least in my case is with Sun's JDK and jcontrol. 
[mos@fault ~]$ ps xauw|grep imsettings
mos       3374  0.0  0.6  21480  7180 ?        S    20:59   0:00 imsettings-applet --disable-xsettings
mos       3798  0.0  0.0   5156   708 pts/0    S+   21:05   0:00 grep imsettings
[mos@fault ~]$ strace -p 3374
Process 3374 attached - interrupt to quit
restart_syscall(<... resuming interrupted call ...>^C <unfinished ...>
Process 3374 detached
[mos@fault ~]$ cd /usr/java/latest/bin/

And running jcontrol with strace produces dialog window that is frozen and strace shows:
mprotect(0xb7f1c000, 4096, PROT_NONE)   = 0
clone(child_stack=0xb7f6c4b4, flags=CLONE_VM|CLONE_FS|CLONE_FILES|CLONE_SIGHAND|CLONE_THREAD|CLONE_SYSVSEM|CLONE_SETTLS|CLONE_PARENT_SETTID|CLONE_CHILD_CLEARTID, parent_tidptr=0xb7f6cbd8, {entry_number:6, base_addr:0xb7f6cb90, limit:1048575, seg_32bit:1, contents:0, read_exec_only:0, limit_in_pages:1, seg_not_present:0, useable:1}, child_tidptr=0xb7f6cbd8) = 3812
futex(0xb7f6cbd8, FUTEX_WAIT, 3812, NULL

And strace on the imsettings is now:
[mos@fault ~]$ strace -p 3374
Process 3374 attached - interrupt to quit
futex(0xf01140, FUTEX_WAIT_PRIVATE, 2, NULL

Killing both jcontrol and imsettings and then restarting jcontrol produces running jcontrol. 

I think this is very critical issue, as it makes me also unable to play Ticket To Ride or Asobrain Explores without killing imsettings-applet. Both very addictive applet-based web games!
Comment 9 Omair Majid 2009-03-26 11:03:08 EDT
(In reply to comment #8)
> 
> Easiest way to reproduce at least in my case is with Sun's JDK and jcontrol. 
> [mos@fault ~]$ ps xauw|grep imsettings
> mos       3374  0.0  0.6  21480  7180 ?        S    20:59   0:00
> imsettings-applet --disable-xsettings
> mos       3798  0.0  0.0   5156   708 pts/0    S+   21:05   0:00 grep
> imsettings
> [mos@fault ~]$ strace -p 3374
> Process 3374 attached - interrupt to quit
> restart_syscall(<... resuming interrupted call ...>^C <unfinished ...>
> Process 3374 detached
> [mos@fault ~]$ cd /usr/java/latest/bin/

Unfortunately, I have never used SCIM before. I am going to need a little help reproducing this. I used System->Preferences->Personal->Input Method to turn on SCIM. I logged out and back in.
$ ps aux | grep [i]msettings
omajid   20887  0.0  1.0  32072 10452 ?        S    10:01   0:01 imsettings-applet --disable-xsettings
$ /usr/java/latest/bin/jcontrol 
This works without any issues. I tried changing the input language through the gnome applet but it didnt seem to have any effect.
Comment 10 Ken Lee 2009-03-26 11:32:10 EDT
This bug just started happening with the latest GTK update.  Java applets and web applications that use 2d rendering are affected under Gnome.  When I switched to KDE, everything works just fine as a work around.

This may also be a duplicate of bug #491813
Comment 11 Ben Konrath 2009-03-26 11:50:10 EDT
*** Bug 492335 has been marked as a duplicate of this bug. ***
Comment 12 Mauri Sahlberg 2009-03-27 13:54:03 EDT
(In reply to comment #9)
> 
> Unfortunately, I have never used SCIM before. I am going to need a little help
> reproducing this. I used System->Preferences->Personal->Input Method to turn on
> SCIM. I logged out and back in.
> $ ps aux | grep [i]msettings
> omajid   20887  0.0  1.0  32072 10452 ?        S    10:01   0:01
> imsettings-applet --disable-xsettings
> $ /usr/java/latest/bin/jcontrol 
> This works without any issues. I tried changing the input language through the
> gnome applet but it didnt seem to have any effect.  

I had not enabled SCIM or did not even know what it was. But as I enabled it, logged in and logged out the jcontrol started working without hanging.
Comment 13 Omair Majid 2009-03-27 16:02:34 EDT
New updates have been released for both libX11 and imsettings. Does this problem still persist even after installing the updates?
Comment 14 Nathan Crubel 2009-03-27 23:34:53 EDT
With the new LibX11 and imsettings, that fixed the problem.  Java no longer hangs.
Comment 15 Jerry Mabin 2009-07-23 14:34:55 EDT
When loading up applet in Java game cribbage, it loads up but not abel to play.
Comment 16 Jerry Mabin 2009-07-23 14:55:06 EDT
(In reply to comment #15)
> When loading up applet in Java game cribbage, it loads up but not abel to play.
Comment 17 Jerry Mabin 2009-07-23 14:57:43 EDT
(In reply to comment #15)
> When loading up applet in Java game cribbage, it loads up but not abel to play.
Comment 18 Rene Sugar 2011-01-24 12:00:30 EST
This is currently reproducable by building the Scala language compiler from SVN in VirtualBox (www.virtualbox.org).

Scala's build uses Java (1.6.0_20).
Comment 19 LeoChen_ca 2015-11-24 22:01:14 EST
Hi, 
Good to find/read/know this, what's the solution for this? Thanks.

Note You need to log in before you can comment on or make changes to this bug.