fredsa / gwt-dnd

Library providing easy to use mouse or touch based drag-and-drop capabilities to GWT
43 stars 40 forks source link

JVM crashes on running the dnd demo on linux in hosted mode (on x86_64, JVM 32 bit) #48

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago

What version of GWT are you using? 1.3.3? 1.4.60? Other?
1.5.1-linux

What version of the gwt-dnd jar file or library file are you using? 
gwt-dnd-2.5.4.jar

What operating system(s) are you using? Windows? Linux? Mac?
Linux x86_64, using a JVM 32 bit:
[antonio@gipserver3 DragDrop]$ java -version
java version "1.6.0_10-rc"
Java(TM) SE Runtime Environment (build 1.6.0_10-rc-b28)
Java HotSpot(TM) Server VM (build 11.0-b15, mixed mode)
Please note that I tried different jvms, 1.5.last, 1.6.last, 1.6.rc, but
all showed the same behaviour.

Does the issue occur in web mode, hosted mode, both or don't know?
Hosted mode

What steps will reproduce the problem?
1. I downloaded (also the latest) the gwt jar, the gwt-dnd jar, and svn sources
2. I recompiled com.allen_sauer.gwt.dnd.demo.DragDropDemo and it compiled
ok, I used a self-modified version of the DragDropDemo-compile.cmd for linux
3. I run the shell file, it starts the hosted mode, I can see the images
loaded, but soon after the jvm crashes.

What is the expected output? What do you see instead?
I would like to see the demo recompiled, but the JVM crashes on the
running, after the body has loaded.

Do you have a workaround?
No, sigh.

Please provide any additional information below.
I could attach the log for the SIGSEGV core dump file of the JVM. I'm just
attaching the header.
It always stops at the same point in libpthread.
I submitted a report to Sun, but I doubt it's a jvm problem.

#
# An unexpected error has been detected by Java Runtime Environment:
#
#  SIGSEGV (0xb) at pc=0x008d03b0, pid=19121, tid=2927197072
#
# Java VM: Java HotSpot(TM) Server VM (11.0-b15 mixed mode linux-x86)
# Problematic frame:
# C  [libpthread.so.0+0x73b0]  pthread_mutex_lock+0x20
#
# An error report file with more information is saved as:
#
/home/antonio/documenti/gwt-linux-1.5.1/src.dnd/gwt-dnd-read-only/DragDrop/hs_er
r_pid19121.log
#
# If you would like to submit a bug report, please visit:
#   http://java.sun.com/webapps/bugreport/crash.jsp
#

Original issue reported on code.google.com by antonio....@gmail.com on 28 Aug 2008 at 3:50

GoogleCodeExporter commented 9 years ago
I forgot to mention that I tried also on a Ubuntu 32 bit, with jdk 1.5 and 1.6, 
and
I get the same SIGSEGV on the JVM.

-Antonio

Original comment by antonio....@gmail.com on 28 Aug 2008 at 4:07

GoogleCodeExporter commented 9 years ago
I'm currently using 1.6.0_07 32 bit (downloaded directly from Sun) on Ubuntu 
x86_64
for hosted mode. However, in Eclipse and regular Java compiles I use 1.6.0_06 
64 bit
(from the Ubuntu package) successfully. I definitely had issues with 32 bit 
1.5.0
JVMs and hosted mode, although different from yours.

If you like, you can check out the DragDrop project from 'trunk' @ r816 and run 
the
command line compile script to compare results

Original comment by fredsa on 29 Aug 2008 at 6:06

GoogleCodeExporter commented 9 years ago
Hello Fred,
thank you for your answer, but I was not able to make it work. I tried also the 
rev
816, but the jvm crashes in the same way.
Anyway, I am using apache to serve the pages, eclipse to see the code, and the 
.cmd
script (modified for Linux) to compile the demo.
I hope I will understand how it works!
Thanks again,

-Antonio

Original comment by antonio....@gmail.com on 29 Aug 2008 at 10:27

GoogleCodeExporter commented 9 years ago
Antonio,

I'd search for this particular flavor of SIGSEGV. Also, check the contents of 
your
hs_err_pid*.log. I don't think this is anythink gwt-dnd specific. You may just 
look
at issues with your Linux (libraries) patch levels. I'm currently using Ubuntu 
8.04
x86_64 if that helps.

Original comment by fredsa on 31 Aug 2008 at 11:19

GoogleCodeExporter commented 9 years ago
Fred,

as I told you in the second message, I tried also an Ubuntu 8.04, 32 bit.
I re-installed it fresh on a virtual machine on my CentOS x86_64, using 
qemu-kvm.
The Ubuntu 8.04 installed normally and is working fine, but running the dnd-demo
shell file makes the JVM die. So I think there must be something wrong in what 
I am
doing, 'cause the Ubuntu is 32 bit, and there are no 64 bit libraries around.

This is what I did:
1. I downloaded gwt-linux-1.5.1 and untarred, copied the gwt-dnd-2.5.4.jar in 
the
root directory of the gwt, downloaded again the sources of dnd using:
svn checkout http://gwt-dnd.googlecode.com/svn/trunk/ gwt-dnd-read-only
2. I downloaded and installed a fresh copy of the JDK 1.6.07 from the Sun site
3. used the attached file compile.antonio to compile the demo (worked)
4. used the attached file shell.antonio to run the shell mode, and it crashed 
in the
same way as on the CentOS x86_64

I am attaching the shell files so you can look at them to see if I am doing 
something
wrong, and the SIGSEGV generated log files from the JVM (2 files: one for the 
32bit
on Ubuntu and one for the CentOS 64 bit).

The Ubuntu is running in a virtual machine with 1 CPU, but also with n 
processors the
JVM crashes in the same way. My machine (the CentOS) is a 2 CPUs with 4 cores 
for CPU
(Dual Xeon E5410).

-Antonio

Original comment by antonio....@gmail.com on 1 Sep 2008 at 8:28

Attachments:

GoogleCodeExporter commented 9 years ago
Sorry. Works for me, after changing your script:
1. modify the gwt jar paths to where they are on my system
2. replacing 'java' with '$JAVA_HOME_32BIT/bin/java' (which equates to
/opt/jdk1.6.0_07/bin/java)

Here perhaps some pertinent information for my up to date Ubuntu 8.0.4 64-bit 
environment:

$ $JAVA_HOME_32BIT/bin/java -version
java version "1.6.0_07"
Java(TM) SE Runtime Environment (build 1.6.0_07-b06)
Java HotSpot(TM) Server VM (build 10.0-b23, mixed mode)

$ uname -a
Linux ubuntu 2.6.24-19-generic #1 SMP Wed Aug 20 17:53:40 UTC 2008 x86_64 
GNU/Linux

$ ldd $JAVA_HOME_32BIT/bin/java
    linux-gate.so.1 =>  (0xffffe000)
    libpthread.so.0 => /lib32/libpthread.so.0 (0xf7f2e000)
    libjli.so => /opt/jdk1.6.0_07/bin/../jre/lib/i386/jli/libjli.so (0xf7f24000)
    libdl.so.2 => /lib32/libdl.so.2 (0xf7f20000)
    libc.so.6 => /lib32/libc.so.6 (0xf7dd1000)
    /lib/ld-linux.so.2 (0xf7f5a000)

Original comment by fredsa on 12 Sep 2008 at 3:45

GoogleCodeExporter commented 9 years ago
Your best chances are using the hs_err*.log files to search for a similar 
issue. 

I do have this set in my environment (edit your ~/.profile and restart X with
ALT-CTRL-BACKSPACE):

   LIBXCB_ALLOW_SLOPPY_LOCK=true

Original comment by fredsa on 12 Sep 2008 at 3:50

GoogleCodeExporter commented 9 years ago
Hello!
I finally got it working!

The problem happens when I allow the application to access your
http://allen-sauer.com/ pages. When I start the shell script to run the demo, 
after a
while a dialog appears (please, look at the attached screenshot). I've always 
been
clicking "yes", and after a few seconds the application crashed.
Clicking "no", makes it stay running and working!
Of course it works also black-listing the site allen-sauer from the command 
line:
(so add the black list at the end of the shell.antonio file)

... com.allen_sauer.gwt.dnd.demo.DragDropDemo/DragDropDemo.html -style PRETTY
-whitelist ^http[:][/][/]google[.]com/* -blacklist 
^http[:][/][/]allen-sauer[.]com/*

This way it works. But why? 
Is it possible that nobody else is experiencing the same crash?

I looked for similar JVM SIGSEGV issues but the only one I found talks about 
using
external code only in one thread in their application:

google for "C  [libpthread.so.0+0x73b0]  pthread_mutex_lock+0x20" or go to

http://dev.aol.com/forum?c=showthread&ThreadID=253&page=0

Thanks for your time,

-Antonio

Original comment by antonio....@gmail.com on 13 Sep 2008 at 2:45

Attachments:

GoogleCodeExporter commented 9 years ago
Thanks for the update.

Original comment by fredsa on 21 Sep 2008 at 3:36

GoogleCodeExporter commented 9 years ago
Perhaps this issue helps:
  http://code.google.com/p/google-web-toolkit/issues/detail?id=2962

which refers to this thread:
  http://groups.google.com/group/Google-Web-
Toolkit/browse_thread/thread/e0373c36acf2dad6

Original comment by fredsa on 9 Oct 2008 at 4:12