victor.herrera
victor.herrera

Reputation: 106

JVM Crashes on GCTaskThread

I'm facing a weird issue with the JVM, I deployed my Rest Service application on tomcat, but now sometimes the JVM crashes randomly, sometimes it crashes after 3 hours, sometimes after 20 hours, sometimes takes days. I was thinking something was wrong with the application about the memory heap, maybe the application is causing a "stop-the-world" several times till the GC fails or something. (Not an expert on this topic).

Do you think is a code issue related (performance issue maybe) or could be a potencial bug on the JVM, I've been read several blogs and oracle forums, some people just said to upgrade the JVM.

Thank you for your help.

JVM Args:

Machine: VM Intel(R) Xeon(R) CPU E5-2680 v3 @ 2.50GHz with 8 cores- 32gb RAM memory.

Here the hs_err log messages:

===================================================================

 A fatal error has been detected by the Java Runtime Environment:

 SIGSEGV (0xb) at pc=0x00007f8182e7c841, pid=24461, tid=140194202347264
 JRE version: Java(TM) SE Runtime Environment (7.0_55-b13) (build 1.7.0_55-b13)
 Java VM: Java HotSpot(TM) 64-Bit Server VM (24.55-b03 mixed mode linux-amd64 compressed oops)
 Problematic frame:
 V  [libjvm.so+0x46c841]  CMSParRemarkTask::do_work_steal(int,Par_MarkRefsIntoAndScanClosure*, int*)+0x101<br/>

 Failed to write core dump. Core dumps have been disabled. To enable core dumping, try "ulimit -c unlimited" before starting Java again<br/>

 If you would like to submit a bug report, please visit:<br/>
   http://bugreport.sun.com/bugreport/crash.jsp<br/>


---------------  T H R E A D  ---------------

Current thread (0x00007f817c021000):  GCTaskThread [stack: 0x00007f8181916000,0x00007f8181a17000] [id=24464]

siginfo:si_signo=SIGSEGV: si_errno=0, si_code=1 (SEGV_MAPERR), si_addr=0x00000000af4ea190

Memory: 4k page, physical 49426864k(32696640k free), swap 2093052k(2089664k free)

vm_info: Java HotSpot(TM) 64-Bit Server VM (24.55-b03) for linux-amd64 JRE (1.7.0_55-b13), built on Mar 17 2014 19:43:58 by "java_re" with gcc 4.3.0 20080428 (Red Hat 4.3.0-8)

Upvotes: 1

Views: 2109

Answers (1)

Nikem
Nikem

Reputation: 5786

Couple of advices:

  1. Upgrade your java to the latest version. They do fix a lot of bugs. If possible, upgrade to the latest jdk8, which is currently 8u92. If not, take the latest jdk7, 7u80
  2. CMSIncrementalMode was deprecated in recent java version. So you can try to remove this option as well.
  3. On CPU with 8 cores and with only 4G of heap you can try to use ParallelGC by removing -XX:+UseConcMarkSweepGC -XX:+CMSIncrementalMode -XX:MaxGCPauseMillis=1200 -XX:ParallelGCThreads=8 options. Parallel GC is simpler and more robust.

Upvotes: 1

Related Questions