Application hangs on futex_wait_queue_me () every couple of minutes

I am running a simple script in Groovy on an Ubuntu 11.10 machine that takes key / value pairs and adds them to a JDBM map in a loop.
Every ~ 3 minutes the script hangs for a few minutes and then resumes.
When I look at the resource monitor, I see that there is no cpu or memory activity and the process is in futex_wait_queue_me()

Please suggest a means to overcome this, on a Windows machine, how the application works without hangs.
Could this be an OS issue? (found many similar topics about similar issues futex_wait_queue_me()

in Ubuntu0


source to share

2 answers

For everyone else concerned, I used these options when starting java:

-Xms16384M -Xmx16384M


You can find more GC optimization tips at



Please check your kernel version. I faced a similar issue (java and other multi-threaded applications) on Centos6 and updated the kernel to 2.6.32-504.16.2.el6.x86_64, resolving the issue.

See the bug report on centos: which contains this pointer to explain the problem: [ ^]

My stack was:

cat /proc/23199/stack
[<ffffffff810b226a>] futex_wait_queue_me+0xba/0xf0
[<ffffffff810b33a0>] futex_wait+0x1c0/0x310
[<ffffffff810b4c91>] do_futex+0x121/0xae0
[<ffffffff810b56cb>] sys_futex+0x7b/0x170
[<ffffffff8100b072>] system_call_fastpath+0x16/0x1b
[<ffffffffffffffff>] 0xffffffffffffffff




All Articles