Java Application Crash

JoeC picture JoeC · Jul 3, 2012 · Viewed 8.1k times · Source

I have been working on a large java application. It is quite parallel, and uses several fixedThreadPools (each with 8 threads). I am running it on a computer with 2 cores, each with 4 processors. My program is analyzing large sets of data, and the analysis is saved (serialized) after every set, though it works across data sets, and so is re-loaded every time I run a new one (and then saved). My problem is this: after running 4-5 data sets (takes about 2 days, and I'm pretty happy with my coding efficiency) it will crash, after exactly the same amount of time on the 5th set (no matter which data set I use). The program is repetitive, and so there is nothing new in the code going on at this time. It is reproducible, and I am not sure what to do. I can post the full error log if that would help... I understand that this problem is ambiguous without a lot more detailed information, but if there are any go-to suggestions, it would be greatly appreciated.

I have been testing different settings to see if anything helps, and right now I am running with the following arguments.

-Xmx6g -Xmx12g -XX:+UnlockExperimentalVMOptions -XX:+UseG1GC

Thanks, Joe

#
# A fatal error has been detected by the Java Runtime Environment:
#
#  SIGSEGV (0xb) at pc=0x0000000000000000, pid=18454, tid=140120548144896
#
# JRE version: 7.0_03-b147
# Java VM: OpenJDK 64-Bit Server VM (22.0-b10 mixed mode linux-amd64 compressed oops)
# Derivative: IcedTea7 2.1.1pre
# Distribution: Ubuntu precise (development branch), package 7~u3-2.1.1~pre1-1ubuntu2
# Problematic frame:
# C  0x0000000000000000
#
# Failed to write core dump. Core dumps have been disabled. To enable core dumping, try "ulimit -c unlimited" before starting Java again
#
# If you would like to submit a bug report, please include
# instructions on how to reproduce the bug and visit:
#   https://bugs.launchpad.net/ubuntu/+source/openjdk-7/
#

Answer

Ponraj Suthanthiramani picture Ponraj Suthanthiramani · Jul 3, 2012

Just a hard guess...

Might be it is not able to create more files

if you are running this in linux Try running

ulimit -c unlimited

Before you run your java program... This should help in two ways

  1. It should increase the file creation limit
  2. If any error occurs it will create the Core dump.

See how many file IO it is using while the program is running.