question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

JVM crash on Raspberry Pi 3

See original GitHub issue

Using provided Oracle JDK on my new π

pi@raspberrypi:~/Chronicle-Queue $ uname -a
Linux raspberrypi 4.1.19-v7+ #858 SMP Tue Mar 15 15:56:00 GMT 2016 armv7l GNU/Linux
pi@raspberrypi:~/Chronicle-Queue $ java -version
java version "1.8.0_65"
Java(TM) SE Runtime Environment (build 1.8.0_65-b17)
Java HotSpot(TM) Client VM (build 25.65-b01, mixed mode)
pi@raspberrypi:~/Chronicle-Queue $ mvn -version
Apache Maven 3.3.9 (bb52d8502b132ec0a5a3f4c09453c07478323dc5; 2015-11-10T16:41:47+00:00)
Maven home: /home/pi/apache-maven-3.3.9
Java version: 1.8.0_65, vendor: Oracle Corporation
Java home: /usr/lib/jvm/jdk-8-oracle-arm32-vfp-hflt/jre
Default locale: en_GB, platform encoding: UTF-8
OS name: "linux", version: "4.1.19-v7+", arch: "arm", family: "unix"

Cloned using

git clone https://github.com/OpenHFT/Chronicle-Queue.git

Output :

pi@raspberrypi:~/Chronicle-Queue $ mvn clean install
[INFO] Scanning for projects...
[INFO]
[INFO] ------------------------------------------------------------------------
[INFO] Building OpenHFT/Chronicle-Queue 4.4.0-SNAPSHOT
[INFO] ------------------------------------------------------------------------
[INFO]
[INFO] --- maven-clean-plugin:2.5:clean (default-clean) @ chronicle-queue ---
[INFO] Deleting /home/pi/Chronicle-Queue/target
[INFO]
[INFO] --- maven-enforcer-plugin:1.4.1:enforce (enforce-no-snapshots) @ chronicle-queue ---
[INFO]
[INFO] --- maven-resources-plugin:2.7:resources (default-resources) @ chronicle-queue ---
[INFO] Using 'UTF-8' encoding to copy filtered resources.
[INFO] skip non existing resourceDirectory /home/pi/Chronicle-Queue/src/main/resources
[INFO]
[INFO] --- maven-compiler-plugin:3.3:compile (default-compile) @ chronicle-queue ---
[INFO] Changes detected - recompiling the module!
[INFO] Compiling 34 source files to /home/pi/Chronicle-Queue/target/classes
[INFO] /home/pi/Chronicle-Queue/src/main/java/net/openhft/chronicle/queue/impl/AbstractChronicleQueueBuilder.java: /home/pi/Chronicle-Queue/src/main/java/net/openhft/chronicle/queue/impl/AbstractChronicleQueueBuilder.java uses unchecked or unsafe operations.
[INFO] /home/pi/Chronicle-Queue/src/main/java/net/openhft/chronicle/queue/impl/AbstractChronicleQueueBuilder.java: Recompile with -Xlint:unchecked for details.
[INFO]
[INFO] --- maven-bundle-plugin:3.0.0:manifest (default) @ chronicle-queue ---
[INFO]
[INFO] --- maven-resources-plugin:2.7:testResources (default-testResources) @ chronicle-queue ---
[INFO] Using 'UTF-8' encoding to copy filtered resources.
[INFO] skip non existing resourceDirectory /home/pi/Chronicle-Queue/src/test/resources
[INFO]
[INFO] --- maven-compiler-plugin:3.3:testCompile (default-testCompile) @ chronicle-queue ---
[INFO] Changes detected - recompiling the module!
[INFO] Compiling 36 source files to /home/pi/Chronicle-Queue/target/test-classes
[INFO] /home/pi/Chronicle-Queue/src/test/java/net/openhft/chronicle/queue/impl/single/ToEndTest.java: /home/pi/Chronicle-Queue/src/test/java/net/openhft/chronicle/queue/impl/single/ToEndTest.java uses or overrides a deprecated API.
[INFO] /home/pi/Chronicle-Queue/src/test/java/net/openhft/chronicle/queue/impl/single/ToEndTest.java: Recompile with -Xlint:deprecation for details.
[INFO]
[INFO] --- maven-surefire-plugin:2.19:test (default-test) @ chronicle-queue ---

-------------------------------------------------------
 T E S T S
-------------------------------------------------------
Running net.openhft.chronicle.queue.LastIndexAppendedTest
#
# A fatal error has been detected by the Java Runtime Environment:
#
#  SIGBUS (0x7) at pc=0x740ab5dc, pid=6450, tid=1982784608
#
# JRE version: Java(TM) SE Runtime Environment (8.0_65-b17) (build 1.8.0_65-b17)
# Java VM: Java HotSpot(TM) Client VM (25.65-b01 mixed mode linux-arm )
# Problematic frame:
# v  ~StubRoutines::atomic_store_long
#
# 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:
# /home/pi/Chronicle-Queue/hs_err_pid6450.log
#
# If you would like to submit a bug report, please visit:
#   http://bugreport.java.com/bugreport/crash.jsp
#
Aborted

Results :

Tests run: 0, Failures: 0, Errors: 0, Skipped: 0

[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 20.233 s
[INFO] Finished at: 2016-05-12T09:48:21+00:00
[INFO] Final Memory: 19M/51M
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-surefire-plugin:2.19:test (default-test) on project chronicle-queue: Execution default-test of goal org.apache.maven.plugins:maven-surefire-plugin:2.19:test failed: The forked VM terminated without properly saying goodbye. VM crash or System.exit called?
[ERROR] Command was /bin/sh -c cd /home/pi/Chronicle-Queue && /usr/lib/jvm/jdk-8-oracle-arm32-vfp-hflt/jre/bin/java -jar /home/pi/Chronicle-Queue/target/surefire/surefirebooter8772016599844544191.jar /home/pi/Chronicle-Queue/target/surefire/surefire8678532781266343868tmp /home/pi/Chronicle-Queue/target/surefire/surefire_02798566282531128178tmp
[ERROR] -> [Help 1]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR]
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/PluginExecutionException

The report : hs_err_pid6450.zip

May be an issue with the JVM…

Issue Analytics

  • State:closed
  • Created 7 years ago
  • Comments:14 (6 by maintainers)

github_iconTop GitHub Comments

4reactions
peter-lawreycommented, May 12, 2016

I have changed the alignment for atomic long operations for queue in the latest snapshot. Changing it for int values would be much harder, but at least you shouldn’t get this error for atomic longs in future.

Peter.

On 12 May 2016 at 13:57, franz1981 notifications@github.com wrote:

@peter-lawrey https://github.com/peter-lawrey In theory every memory operation with address on primitive type is eligible for this kind of issue, thus adding a proper check on Memory with a configuration flag could rise an exception during the tests (putXXX,getXXX,cas and wait-free getAndAdd etc etc)…

@glandais https://github.com/glandais ARMs are a NightARMare 😛 MMM…generally i do not encounter that issue because i perform on the rasp only aligned accesses…but “maybe”: http://lxr.free-electrons.com/source/arch/arm/mm/alignment.c http://url

/* 104 * ARMv6 and later CPUs can perform unaligned accesses for 105 * most single load and store instructions up to word size. 106 * LDM, STM, LDRD and STRD still need to be handled. 107 * 108 * Ignoring the alignment fault is not an option on these 109 * CPUs since we spin re-faulting the instruction without 110 * making any progress. 111 */

there are a lot of possibilities:

Anyway, here: http://psy-lob-saw.blogspot.it/2013/01/direct-memory-alignment-in-java.html http://url you could find tests and info to understand the issue…

— You are receiving this because you were mentioned. Reply to this email directly or view it on GitHub https://github.com/OpenHFT/Chronicle-Queue/issues/253#issuecomment-218748904

1reaction
glandaiscommented, May 12, 2016

Thank for you responses

I’m getting the same problem on bytes (not in core but I guess atomic_store_long is never called).

Thanks franz1981 for your answer, I’m a bit disappointed, I don’t really like to recompile a kernel 😃

Read more comments on GitHub >

github_iconTop Results From Across the Web

Reason for Pi crashing? [SOLVED] - Raspberry Pi Forums
Hey, I have a Raspberry Pi 3B+ which I host a webserver on. Reliability is important to me, but my Pi keeps crashing...
Read more >
Java is crashing my Pi - Raspberry Pi Stack Exchange
I am running ScreenConnect on some Rasp Pis and the Pi eventually hangs up and then it will crash and require a reboot...
Read more >
[JDK-8222824] Raspberry Pi crash during System.loadLibrary()
Issue reported on Raspberry Pi 3 on OpenJDK build. Issue found during "System.loadLibrary(Core.NATIVE_LIBRARY_NAME);". fmatte Fairoz ...
Read more >
Raspberry PI 2 Java 8 JVM error - Stack Overflow
When app start, it is consuming only 250 Mb ram and after 3 day is crashing the app beacause it's reaching the maximum...
Read more >
Raspberry Pi and Unifi | Ubiquiti Community
Can you send me the hs_err_pidxxx.log file? I assume the crash is about jvm crash, and if jvm crash jvm will dump error...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found