Java Runtime Environment getting "fatal error SIGSEGV" for program using JOGL

2

I am trying to run a Java program through Eclipse. Whenever I try and run the thing, this is what I get:

Info: XInitThreads() called for concurrent Thread support
#
# A fatal error has been detected by the Java Runtime Environment:
#
#  SIGSEGV (0xb) at pc=0x000010f1, pid=2750, tid=1923033968
#
# JRE version: 6.0_22-b04
# Java VM: Java HotSpot(TM) Server VM (17.1-b03 mixed mode linux-x86 )
# Problematic frame:
# C  0x000010f1
#
# An error report file with more information is saved as:
# /home/anjruu/ragamuffin/trunk/pipeline/hs_err_pid2750.log
#
# If you would like to submit a bug report, please visit:
#   http://java.sun.com/webapps/bugreport/crash.jsp

I am not getting any build errors, and have tried it using both the Java 6 OpenJDK, as well as Sun's jdk1.6.0_22, both behave the same. I am running an Ubuntu 10.10 system. The program uses JOGL (Java OpenGL), is that relevant?

The log file is about 400 lines long, so I figure that maybe posting the entire thing isn't so useful, and I'm not sure what sections would be, but if someone can let me know what I should include, I can do so.

java
jogl
segmentation-fault
jvm-crash
asked on Stack Overflow Nov 9, 2010 by (unknown user) • edited Mar 28, 2019 by Raedwald

3 Answers

1

This looks like a bug in some C code somewhere. Given that it happened on two different JVMs I'd tend to suspect native extensions, perhaps JOGL.

Have you checked the file the report points you too: hs_err_pid2750.log? Looking at that and then searching for some of those contents can often point you to others with the same problem and sometimes a fix.

answered on Stack Overflow Nov 9, 2010 by Paul Rubel
0

If you are using JOGL on a Linux system then it is almost certain that the problem lies there. 3D graphics is not very robust on most Linux systems, and JOGL stresses 3D graphics systems a lot because it does unusual things with them, mostly to do with multithreading.

Most of the time the problem lies with out-of-date or non-conforming display drivers. Make sure your system has the latest drivers, and use the proprietary ones, not the ones that come with the installation and not any open source ones - sorry but this is one case where knowing the hardware backwards (like the graphics card providers do) really improves quality and performance. This will usually fix the problem.

If that doesn't help you are going to have to do something drastic. Often disabling hardware graphics acceleration will fix it, but with loss of performance of course. The log file should give you the full stack trace, which may be useful if you are comfortable with device driver coding and have the source of the drivers. Alternatively try using a different graphics card - new ones are cheap if you haven't upgraded yours recently.

I spent months of my life trying to track down bugs like this on a JOGL app running on Linux in the general case, and I still found installations where the window would draw blank. Good luck.

answered on Stack Overflow Nov 9, 2010 by DJClayworth • edited Nov 11, 2010 by DJClayworth
0

As other posters have said, HotSpot errors in JOGL programs can often be fixed by updating your graphics card drivers to the latest version.

However, if you're using the new JOGL 2.0 beta, the problem might be that you're either not calling GLProfile.initSingleton(), or you're not calling it early enough (it has to be before any X Windows calls).

I've got a tutorial at http://wadeawalker.wordpress.com/2010/10/09/tutorial-a-cross-platform-workbench-program-using-java-opengl-and-eclipse/ that shows how to create a simple JOGL 2.0 program. I've tested this program on CentOS 5.4 and it works correctly. Back before I had GLProfile.initSingleton() in the right place in this tutorial, I saw the same SIGSEGV error as you.

answered on Stack Overflow Nov 9, 2010 by Wade Walker

User contributions licensed under CC BY-SA 3.0