Java Virtual Machine crashes Multiple times - java

This is the entire error message
http://pastebin.com/bDgye0rt
The error log is too big that I can't attach it here. I am not extremely familiar with how jvm works in the background and what registers it makes use of. I am hoping someone can look at this error log and explain to me what it means.
#
# A fatal error has been detected by the Java Runtime Environment:
#
# SIGSEGV (0xb) at pc=0x00007ffd18cbcafe, pid=29906, tid=140725158119168
#
# JRE version: 6.0_27-b27
# Java VM: OpenJDK 64-Bit Server VM (20.0-b12 mixed mode linux-amd64 compressed oops)
# Derivative: IcedTea6 1.12.6
# Distribution: Debian GNU/Linux 7.1 (wheezy), package 6b27-1.12.6-1~deb7u1
# Problematic frame:
# C [libresolv.so.2+0x7afe] __libc_res_nquery+0x19e
#
# If you would like to submit a bug report, please include
# instructions how to reproduce the bug and visit:
# http://icedtea.classpath.org/bugzilla
# The crash happened outside the Java Virtual Machine in native code.
# See problematic frame for where to report the bug.
#
I can't understand why and how it is created. It keeps happening all the time.
PS:
I have the error log of another 3 crashes that happened in my machine which I can share if you think its necessary.
EDIT
I have around 8 logs and out of the 8 logs it is made clear that the last call before the program crashes is
java.net.Inet6AddressImpl.lookupAllHostAddr
I do not believe the input is that much related because there is a static list of inputs that are parsed serially, and the error occurs at different time frames (Sometimes 1 hour after the program has been running and some other times 6 hours, it appears to be random).

It is an issue related to glibc and IPv6.
It would be safe to add -Djava.net.preferIPv4Stack=true to ask JVM use IPv4 first to avoid this issue.

Related

Set ulimit when debugging with Eclipse

Sometimes my code crashes leaving me with an error file but no core dump because the latter is disabled.
Now it is suggested to set ulimit -c unlimited to allow core dumps.
If I would be running the code from console, it would be no issue to set ulimit before starting the Java Application. But the error seems to be much more frequent when debugged in Eclipse as when running as a standalone. (Actually as a standalone it crashed this way only once in hundreds of running hours, in debugging it crashed 4 times in the last two months (and some times before)).
Is there a way to tell Eclipse to set ulimit before launching a Debug-Session in Eclipse ?
And will a Core-Dump help me to find what causes the crash ?
For completeness, I am working on macOS and my error files all start like this (only pidchanges between them):
# A fatal error has been detected by the Java Runtime Environment:
#
# SIGILL (0x4) at pc=0x00007fffa08c144e, pid=617, tid=0x0000000000000307
#
# JRE version: Java(TM) SE Runtime Environment (8.0_181-b13) (build 1.8.0_181-b13)
# Java VM: Java HotSpot(TM) 64-Bit Server VM (25.181-b13 mixed mode bsd-amd64 compressed oops)
# Problematic frame:
# C [AppKit+0x3a544e] -[NSApplication _crashOnException:]+0x6d
#
# 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 visit:
# http://bugreport.java.com/bugreport/crash.jsp
# The crash happened outside the Java Virtual Machine in native code.
# See problematic frame for where to report the bug.
#
I suspect (but have nothing to prove it except the "moment when it crashes") that the crashes are related with the handling of BufferedImage within the Java code, but then again, the Error-Log tells that the error happened outside the JVM.

JavaFX error on IntelliJ after running program SIGBUS (0xa) [duplicate]

This question already has answers here:
Why do I keep getting this SIGBUS error code on my MacOS when trying to run a JavaFx Project on Netbeans?
(2 answers)
Closed 1 year ago.
Hello everyone I receive and error when running a GUI application on JAVAFX on IntelliJ. I'm in my second semester with Java in college so now really sure what these errors mean but basically the program runs for a few seconds and then suddenly crashes on it's own. It's all random, can last 3 seconds or can last 15 seconds. I'm not sure what information is needed but I can provide for now what I'm using which is Java 17 and JAVAFX up to date. Mac mini M1. Intellij up to date.
#
# SIGBUS (0xa) at pc=0x000000010a0514f0, pid=8179, tid=28687
#
# JRE version: Java(TM) SE Runtime Environment (17.0.1+12) (build 17.0.1+12-LTS-39)
# Java VM: Java HotSpot(TM) 64-Bit Server VM (17.0.1+12-LTS-39, mixed mode, sharing, tiered, compressed oops, compressed class ptrs, g1 gc, bsd-aarch64)
# Problematic frame:
# v ~StubRoutines::SafeFetchN
#
# No core dump will be written. Core dumps have been disabled. To enable core dumping, try "ulimit -c unlimited" before starting Java again
#
# An error report file with more information is saved as:
# /Users/yayo/Documents/CSC 123/Projects/HeadsOrTails/hs_err_pid8179.log
#
# If you would like to submit a bug report, please visit:
# https://bugreport.java.com/bugreport/crash.jsp
# The crash happened outside the Java Virtual Machine in native code.
# See problematic frame for where to report the bug.
#
# The crash happened outside the Java Virtual Machine in native code.
This is a broken configuration - not your code. An external library is being called by the JVM which causes the crash. You might need to update that manually. The error file written contains more troubleshooting information.

Why JVM crashes with seg fault? [duplicate]

We are seeing the JVM getting crashed at times with segfault. The only error we see in logs is as below.
Anyone can suggest something by looking at the below error trace.
# A fatal error has been detected by the Java Runtime Environment:
#
# SIGSEGV (0xb) at pc=0x00007fef7f1d3eb0, pid=42623, tid=0x00007feea62c8700
#
# JRE version: OpenJDK Runtime Environment (8.0_222-b10) (build 1.8.0_222-b10)
# Java VM: OpenJDK 64-Bit Server VM (25.222-b10 mixed mode linux-amd64 compressed oops)
# Problematic frame:
# J 62683 C2 org.apache.ignite.internal.marshaller.optimized.OptimizedObjectOutputStream.writeObject0(Ljava/lang/Object;)V (331 bytes) # 0x00007fef7f1d3eb0 [0x00007fef7f1d3e00+0xb0]
#
# Failed to write core dump. Core dumps have been disabled. To enable core dumping, try "ulimit -c unlimited" before starting Java again
#
# An error report file with more information is saved as:
# /tmp/hsperfdata_pvappuser/hs_err_pid42623.log
#
# If you would like to submit a bug report, please visit:
# http://bugreport.java.com/bugreport/crash.jsp
While trying to understand the reason for this crash Oracle JVM docs https://docs.oracle.com/javase/8/docs/technotes/guides/troubleshoot/crashes001.html ,this looks to be the case of 5.1.2 Crash in Compiled Code as the problematic frame is java frame(has a "J")
Though could not get much further from it, we also not sure when it comes, the only probale pattern is it comes when JVM is running for 5-6 days so usually on Friday.
We are using openjdk-8 ("1.8.0_232") distribution provided by RedHat running on RHEL 6.10.
Looking forward to get any leading point in tracing this error.
The current stack frame has writeObject0 as the last called method. There is a naming convention that native method's names end with 0. Therefore check whether that method is indeed native.
If it is, it is probably written in C, an ancient unsafe language whose programs tend to crash in an uncontrolled way. This often leads to SIGSEGV.
In this case, that method is written in Java though.
As you were told in the error message, read hs_err_pid42623.log for further details. In that file you will find the registers and a few machine instructions around the code that crashed.

How to know the reason for JVM crashing with Segfault?

We are seeing the JVM getting crashed at times with segfault. The only error we see in logs is as below.
Anyone can suggest something by looking at the below error trace.
# A fatal error has been detected by the Java Runtime Environment:
#
# SIGSEGV (0xb) at pc=0x00007fef7f1d3eb0, pid=42623, tid=0x00007feea62c8700
#
# JRE version: OpenJDK Runtime Environment (8.0_222-b10) (build 1.8.0_222-b10)
# Java VM: OpenJDK 64-Bit Server VM (25.222-b10 mixed mode linux-amd64 compressed oops)
# Problematic frame:
# J 62683 C2 org.apache.ignite.internal.marshaller.optimized.OptimizedObjectOutputStream.writeObject0(Ljava/lang/Object;)V (331 bytes) # 0x00007fef7f1d3eb0 [0x00007fef7f1d3e00+0xb0]
#
# Failed to write core dump. Core dumps have been disabled. To enable core dumping, try "ulimit -c unlimited" before starting Java again
#
# An error report file with more information is saved as:
# /tmp/hsperfdata_pvappuser/hs_err_pid42623.log
#
# If you would like to submit a bug report, please visit:
# http://bugreport.java.com/bugreport/crash.jsp
While trying to understand the reason for this crash Oracle JVM docs https://docs.oracle.com/javase/8/docs/technotes/guides/troubleshoot/crashes001.html ,this looks to be the case of 5.1.2 Crash in Compiled Code as the problematic frame is java frame(has a "J")
Though could not get much further from it, we also not sure when it comes, the only probale pattern is it comes when JVM is running for 5-6 days so usually on Friday.
We are using openjdk-8 ("1.8.0_232") distribution provided by RedHat running on RHEL 6.10.
Looking forward to get any leading point in tracing this error.
The current stack frame has writeObject0 as the last called method. There is a naming convention that native method's names end with 0. Therefore check whether that method is indeed native.
If it is, it is probably written in C, an ancient unsafe language whose programs tend to crash in an uncontrolled way. This often leads to SIGSEGV.
In this case, that method is written in Java though.
As you were told in the error message, read hs_err_pid42623.log for further details. In that file you will find the registers and a few machine instructions around the code that crashed.

Java Hotspot Error - V [libjvm.so+0x5c3a84]

I am having real problems getting to the bottom of the java hotspot errors we are experiencing. The errors are seemingly random and the problematic frame varies. An example error is shown below:
#
# A fatal error has been detected by the Java Runtime Environment:
#
# SIGSEGV (0xb) at pc=0x00007f65ce3c3a84, pid=26082, tid=0x00007f65bc2ab700
#
# JRE version: Java(TM) SE Runtime Environment (8.0_101-b13) (build 1.8.0_101-b13)
# Java VM: Java HotSpot(TM) 64-Bit Server VM (25.101-b13 mixed mode linux-amd64 )
# Problematic frame:
# V [libjvm.so+0x5c3a84] G1ParScanThreadState::copy_to_survivor_space(InCSetState, oopDesc*, markOopDesc*)+0x174
#
# Core dump written. Default location: /opt/dap/domains/tc0419/prod1/tomcat/bin/core or core.26082 (max size 1 kB). To ensure a full core dump, try "ulimit -c unlimited" before starting Java again
#
# If you would like to submit a bug report, please visit:
# http://bugreport.java.com/bugreport/crash.jsp
#
The java application is a relatively simple, it is just a war file running in a tomcat on a server.
Please let me know if any additional information would be helpful to access, I'm a bit new to this. The current thinking is that this is a hardware issue but any further information would be much appreciated.
Thanks,
Adam
The problematic frame "G1ParScanThreadState::copy_to_survivor_space(InCSetState, oopDesc*, markOopDesc*)+0x174" represents it is an gc crash. It is bug in JVM. There are couple of issues reported before
1. https://bugs.openjdk.java.net/browse/JDK-8170451
2. https://bugs.openjdk.java.net/browse/JDK-8143310
As we don't have way to reproduce or they occured once in a while. As you can see both the issues are closed either as Incomplete or cannot reproduce.
If you have a strong reproduce kindly file a bug through http://bugreport.java.com/submit_intro.do along with steps/test case to reproduce the issue.
It will be addressed... :)
You are using JDK 8 update 101, Kindly upgrade to latest build JDK8 update 121 from here - http://www.oracle.com/technetwork/java/javase/downloads/index.html

Categories