[debian-armhf] JAVA JDK 11 runtime error

Hi Robert,

I installed JDK11 and jetty9. When I start (start.jar is under /opt/jetty):
java -jar start.jar

I got run time error. The log file i attached.
I am aware that java is out of the scope of your support. Certainly I would greatly appreciate your help.

David
hs_err_pid13472.log (30.9 KB)

Hi Robert,

From the error message on the console:

Could not load hsdis-arm.so; library not loadable; PrintAssembly is disabled
Aborted

it seems related to the hsdis-arm.so lib file;

Thank you,
David

Hi Robert,

I started java with command option -XX:-AssumeMP, the run-time crash disappeared.

$ java -XX:-AssumeMP -jar …/start.jar

Best Regards,

David

It looks like in JAVA 12, this will not be required anymore…

https://bugs.openjdk.java.net/browse/JDK-8188079

Regards,

Hi Robert,

I guess it was in JDK8, then deprecated in JDK11, then fixed in JDK12.

I still have installation issues with JRE. I am going to re-flash the board, then install it from fresh, and send you the error messages for you to take a look. Thank you for your help!

Best Regards,

David

What base image are you using?

debian@bbb-pwr01-ser09:~$ sudo apt install default-jdk

Requires:

0 upgraded, 133 newly installed, 0 to remove and 1 not upgraded.
Need to get 273 MB of archives.
After this operation, 812 MB of additional disk space will be used.
Do you want to continue? [Y/n] 

So almost 1GB of free space…

Regards,

Hi Robert,

Debian 10, Buster Release (2019-07-07). It is pre-built image from BBB web site. I did exactly that way. Give me sometime, as I said I will install it from fresh, so it will make you easier to spot the problem.

Best Regards,

David

and how much free space is available in the that old image?

and just triggered the same error:

Adding debian:ePKI_Root_Certification_Authority.pem
Adding debian:XRamp_Global_CA_Root.pem
#
# A fatal error has been detected by the Java Runtime Environment:
#
#  SIGILL (0x4) at pc=0xb40c6760, pid=2739, tid=2747
#
# JRE version: OpenJDK Runtime Environment (11.0.9+11) (build 11.0.9+11-post-Debian-1deb10u1)
# Java VM: OpenJDK Server VM (11.0.9+11-post-Debian-1deb10u1, mixed mode, serial gc, linux-)
# Problematic frame:
# J 46 c2 sun.security.provider.X509Factory.readOneBlock(Ljava/io/InputStream;)[B java.base@11.0.9 (447 bytes) @ 0xb40c6760 [0
xb40c66e0+0x00000080]
#
# No core dump will be written. Core dumps have been disabled. To enable core dumping, try "ulimit -c unlimited" before starti
ng Java again
#
# An error report file with more information is saved as:
# //hs_err_pid2739.log
Could not load hsdis-arm.so; library not loadable; PrintAssembly is disabled
#
# If you would like to submit a bug report, please visit:
#   https://bugs.debian.org/openjdk-11
#
/var/lib/dpkg/info/ca-certificates-java.postinst: line 88:  2737 Done                    find /etc/ssl/certs -name \*.pem
      2738                       | while read filename; do
    alias=$(basename $filename .pem | tr A-Z a-z | tr -cs a-z0-9 _); alias=${alias%*_}; if [ -n "$FIXOLD" ]; then
        echo "-${alias}"; echo "-${alias}_pem";
    fi; echo "+${filename}";
done
      2739 Aborted                 | java -Xmx64m -jar $JAR -storepass "$storepass"
dpkg: error processing package ca-certificates-java (--configure):
 installed ca-certificates-java package post-installation script subprocess returned error exit status 134
Setting up default-jdk (2:1.11-71) ...
Processing triggers for systemd (241-7~deb10u4rcnee0~buster+20200509) ...
Processing triggers for man-db (2.8.5-2) ...
Processing triggers for ca-certificates (20200601~deb10u1) ...
Updating certificates in /etc/ssl/certs...
0 added, 0 removed; done.
Running hooks in /etc/ca-certificates/update.d...

done.
done.
Processing triggers for mime-support (3.62) ...
Processing triggers for libglib2.0-0:armhf (2.58.3-2+deb10u2) ...
Processing triggers for libc-bin (2.28-10) ...
Setting up glib-networking:armhf (2.58.0-2+deb10u2) ...
Setting up libsoup2.4-1:armhf (2.64.2-2) ...
Setting up libsoup-gnome2.4-1:armhf (2.64.2-2) ...
Setting up librest-0.7-0:armhf (0.8.1-1) ...
Setting up libgtk-3-0:armhf (3.24.5-1) ...
Setting up libgtk-3-bin (3.24.5-1) ...
Setting up libatk-wrapper-java-jni:armhf (0.33.3-22) ...
Processing triggers for libgdk-pixbuf2.0-0:armhf (2.38.1+dfsg-1) ...
Processing triggers for libc-bin (2.28-10) ...
Errors were encountered while processing:
 ca-certificates-java
E: Sub-process /usr/bin/dpkg returned an error code (1)
debian@bbb-pwr01-ser09:~$

Looks like ca-certificates-java needs the "XX:-AssumeMP " fix…

Bug report here: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=960153

Regards,

Hi Rebort,

I am installing into our board with 16G total flash space.
That’s the almost exact error I got.
But the question is how to set XX:-AssumeMP into the installation script?

Best Regards,

David

i posted a response on : https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=960153 not sure how long it’ll take to show up…

Regards,

Probally here… debian/postinst.in · stretch · Debian Java Maintainers / ca-certificates-java · GitLab

The Bug report you posted doesn’t include a resolution.

I found a work-around in my previous thread to mv out the configuration file ( couldn’t remember exact wording).
I am not sure that has no “side-effect”.
The script you posted ( postinst.in) , I don’t know how run it during installation.

Thank you,

David

This is the work-around:

sudo mv /var/lib/dpkg/info/ca-certificates-java.postinst /var/lib/dpkg/info/ca-certificates-java.postinst.bac
sudo apt-get purge ca-certificate-java
sudo apt-get install -f

I don’t know it IS a solution. But it will install.

David

Yeap, that’s an active bug report…

Getting Closer:

Do you want to continue? [Y/n] y
Get:1 http://repos.rcn-ee.com/debian buster/main armhf ca-certificates-java all 20190405rcnee0~buster+20201118 [15.8 kB]
Fetched 15.8 kB in 0s (71.2 kB/s)         
(Reading database ... 85872 files and directories currently installed.)
Preparing to unpack .../ca-certificates-java_20190405rcnee0~buster+20201118_all.deb ...
Unpacking ca-certificates-java (20190405rcnee0~buster+20201118) over (20190405) ...
Setting up ca-certificates-java (20190405rcnee0~buster+20201118) ...
OpenJDK Server VM warning: Option AssumeMP was deprecated in version 10.0 and will likely be removed in a future release.
OpenJDK Server VM warning: Option AssumeMP was deprecated in version 10.0 and will likely be removed in a future release.
Adding debian:ISRG_Root_X1.pem
Adding debian:EC-ACC.pem
Adding debian:GTS_Root_R4.pem
Adding debian:Entrust_Root_Certification_Authority_-_G4.pem
Adding debian:Staat_der_Nederlanden_EV_Root_CA.pem
Adding debian:GeoTrust_Universal_CA_2.pem
Adding debian:Sonera_Class_2_Root_CA.pem
Adding debian:emSign_ECC_Root_CA_-_G3.pem
Adding debian:IdenTrust_Commercial_Root_CA_1.pem
Adding debian:SSL.com_Root_Certification_Authority_RSA.pem
Adding debian:ePKI_Root_Certification_Authority.pem
Adding debian:XRamp_Global_CA_Root.pem
Adding debian:Security_Communication_RootCA2.pem
Adding debian:Entrust.net_Premium_2048_Secure_Server_CA.pem
Adding debian:DigiCert_Global_Root_CA.pem
Adding debian:Staat_der_Nederlanden_Root_CA_-_G2.pem
Adding debian:Certigna.pem
Adding debian:Chambers_of_Commerce_Root_-_2008.pem
Adding debian:TWCA_Root_Certification_Authority.pem
Adding debian:Network_Solutions_Certificate_Authority.pem
Adding debian:Izenpe.com.pem
Adding debian:DigiCert_Global_Root_G3.pem
Adding debian:AffirmTrust_Premium.pem
Adding debian:D-TRUST_Root_Class_3_CA_2_2009.pem
Adding debian:SSL.com_EV_Root_Certification_Authority_ECC.pem
Adding debian:Secure_Global_CA.pem
Adding debian:Cybertrust_Global_Root.pem
Adding debian:OISTE_WISeKey_Global_Root_GC_CA.pem
Adding debian:GlobalSign_ECC_Root_CA_-_R4.pem
Adding debian:CFCA_EV_ROOT.pem
Adding debian:QuoVadis_Root_CA_2.pem
Adding debian:Entrust_Root_Certification_Authority_-_EC1.pem
Adding debian:Global_Chambersign_Root_-_2008.pem
Adding debian:GlobalSign_Root_CA_-_R2.pem
Adding debian:QuoVadis_Root_CA_1_G3.pem
Adding debian:SecureSign_RootCA11.pem
Adding debian:Autoridad_de_Certificacion_Firmaprofesional_CIF_A62634068.pem
Adding debian:Certum_Trusted_Network_CA.pem
Adding debian:GlobalSign_Root_CA.pem
Adding debian:Comodo_AAA_Services_root.pem
Adding debian:GDCA_TrustAUTH_R5_ROOT.pem
Adding debian:DST_Root_CA_X3.pem
Adding debian:GlobalSign_ECC_Root_CA_-_R5.pem
Adding debian:GTS_Root_R2.pem
Adding debian:GlobalSign_Root_CA_-_R6.pem
Adding debian:Baltimore_CyberTrust_Root.pem
Adding debian:QuoVadis_Root_CA.pem
Adding debian:Go_Daddy_Root_Certificate_Authority_-_G2.pem
Adding debian:Entrust_Root_Certification_Authority_-_G2.pem
Adding debian:DigiCert_Trusted_Root_G4.pem
Adding debian:AffirmTrust_Premium_ECC.pem
Adding debian:UCA_Global_G2_Root.pem
Adding debian:Starfield_Root_Certificate_Authority_-_G2.pem
Adding debian:COMODO_ECC_Certification_Authority.pem
Adding debian:SSL.com_EV_Root_Certification_Authority_RSA_R2.pem
Adding debian:SecureTrust_CA.pem
Adding debian:D-TRUST_Root_Class_3_CA_2_EV_2009.pem
Adding debian:T-TeleSec_GlobalRoot_Class_3.pem
Adding debian:COMODO_Certification_Authority.pem
Adding debian:TrustCor_RootCert_CA-1.pem
Adding debian:TrustCor_RootCert_CA-2.pem
Adding debian:Verisign_Class_3_Public_Primary_Certification_Authority_-_G3.pem
Adding debian:Hongkong_Post_Root_CA_3.pem
Adding debian:emSign_Root_CA_-_C1.pem
Adding debian:QuoVadis_Root_CA_3_G3.pem
Adding debian:TUBITAK_Kamu_SM_SSL_Kok_Sertifikasi_-_Surum_1.pem
Adding debian:LuxTrust_Global_Root_2.pem
Adding debian:Entrust_Root_Certification_Authority.pem
Adding debian:TWCA_Global_Root_CA.pem
Adding debian:NetLock_Arany_=Class_Gold=_Főtanúsítvány.pem
Adding debian:SwissSign_Gold_CA_-_G2.pem
Adding debian:GTS_Root_R3.pem
Adding debian:SZAFIR_ROOT_CA2.pem
Adding debian:TrustCor_ECA-1.pem
Adding debian:Hongkong_Post_Root_CA_1.pem
Adding debian:T-TeleSec_GlobalRoot_Class_2.pem
Adding debian:Buypass_Class_3_Root_CA.pem
Adding debian:DigiCert_Assured_ID_Root_G2.pem
Adding debian:SSL.com_Root_Certification_Authority_ECC.pem
Adding debian:Amazon_Root_CA_4.pem
Adding debian:certSIGN_ROOT_CA.pem
Adding debian:SwissSign_Silver_CA_-_G2.pem
Adding debian:OISTE_WISeKey_Global_Root_GA_CA.pem
Adding debian:GTS_Root_R1.pem
Adding debian:Microsec_e-Szigno_Root_CA_2009.pem
Adding debian:TeliaSonera_Root_CA_v1.pem
Adding debian:Hellenic_Academic_and_Research_Institutions_ECC_RootCA_2015.pem
Adding debian:USERTrust_ECC_Certification_Authority.pem
Adding debian:Amazon_Root_CA_3.pem
Adding debian:Security_Communication_Root_CA.pem
Adding debian:CA_Disig_Root_R2.pem
Adding debian:AC_RAIZ_FNMT-RCM.pem
Adding debian:Certum_Trusted_Network_CA_2.pem
Adding debian:Certigna_Root_CA.pem
Adding debian:QuoVadis_Root_CA_2_G3.pem
Adding debian:AffirmTrust_Networking.pem
Adding debian:Actalis_Authentication_Root_CA.pem
Adding debian:Atos_TrustedRoot_2011.pem
Adding debian:Starfield_Services_Root_Certificate_Authority_-_G2.pem
Adding debian:IdenTrust_Public_Sector_Root_CA_1.pem
Adding debian:Trustis_FPS_Root_CA.pem
Adding debian:Hellenic_Academic_and_Research_Institutions_RootCA_2011.pem
Adding debian:UCA_Extended_Validation_Root.pem
Adding debian:COMODO_RSA_Certification_Authority.pem
Adding debian:Buypass_Class_2_Root_CA.pem
Adding debian:emSign_ECC_Root_CA_-_C3.pem
Adding debian:Hellenic_Academic_and_Research_Institutions_RootCA_2015.pem
Adding debian:DigiCert_Assured_ID_Root_G3.pem
Adding debian:QuoVadis_Root_CA_3.pem
Adding debian:DigiCert_High_Assurance_EV_Root_CA.pem
Adding debian:DigiCert_Assured_ID_Root_CA.pem
Adding debian:DigiCert_Global_Root_G2.pem
Adding debian:Starfield_Class_2_CA.pem
Adding debian:Amazon_Root_CA_1.pem
Adding debian:emSign_Root_CA_-_G1.pem
Adding debian:OISTE_WISeKey_Global_Root_GB_CA.pem
Adding debian:Go_Daddy_Class_2_CA.pem
Adding debian:ssl-cert-snakeoil.pem
Adding debian:USERTrust_RSA_Certification_Authority.pem
Adding debian:GlobalSign_Root_CA_-_R3.pem
Adding debian:Amazon_Root_CA_2.pem
Adding debian:Staat_der_Nederlanden_Root_CA_-_G3.pem
Adding debian:EE_Certification_Centre_Root_CA.pem
Adding debian:AffirmTrust_Commercial.pem
Adding debian:E-Tugra_Certification_Authority.pem
Adding debian:ACCVRAIZ1.pem
Adding debian:Taiwan_GRCA.pem
done.
Processing triggers for ca-certificates (20200601~deb10u1) ...
Updating certificates in /etc/ssl/certs...
0 added, 0 removed; done.
Running hooks in /etc/ca-certificates/update.d...

#
# A fatal error has been detected by the Java Runtime Environment:
#
#  SIGILL (0x4) at pc=0xb40d8a50, pid=10324, tid=10325
#
# JRE version: OpenJDK Runtime Environment (11.0.9+11) (build 11.0.9+11-post-Debian-1deb10u1)
# Java VM: OpenJDK Server VM (11.0.9+11-post-Debian-1deb10u1, mixed mode, serial gc, linux-)
# Problematic frame:
# J 44 c2 java.math.BigInteger.stripLeadingZeroBytes([BII)[I java.base@11.0.9 (141 bytes) @ 0xb40d8a50 [0xb40d8990+0x000000c0
]
#
# No core dump will be written. Core dumps have been disabled. To enable core dumping, try "ulimit -c unlimited" before start
ing Java again
#
# An error report file with more information is saved as:
# /etc/ssl/certs/hs_err_pid10324.log
Could not load hsdis-arm.so; library not loadable; PrintAssembly is disabled
#
# If you would like to submit a bug report, please visit:
#   https://bugs.debian.org/openjdk-11
#
Aborted
E: /etc/ca-certificates/update.d/jks-keystore exited with code 1.
done.

Regards,

It’s all fixed now…

sudo apt update
sudo apt upgrade
The following packages will be upgraded:
  ca-certificates-java
1 upgraded, 0 newly installed, 0 to remove and 1 not upgraded.
Need to get 15.8 kB of archives.
After this operation, 0 B of additional disk space will be used.
Do you want to continue? [Y/n] y
Get:1 http://repos.rcn-ee.com/debian buster/main armhf ca-certificates-java all 20190405rcnee1~buster+20201118 [15.8 kB]
Fetched 15.8 kB in 0s (62.8 kB/s)         
(Reading database ... 85872 files and directories currently installed.)
Preparing to unpack .../ca-certificates-java_20190405rcnee1~buster+20201118_all.deb ...
Unpacking ca-certificates-java (20190405rcnee1~buster+20201118) over (20190405rcnee0~buster+20201118) ...
Setting up ca-certificates-java (20190405rcnee1~buster+20201118) ...
Installing new version of config file /etc/ca-certificates/update.d/jks-keystore ...
Processing triggers for ca-certificates (20200601~deb10u1) ...
Updating certificates in /etc/ssl/certs...
0 added, 0 removed; done.
Running hooks in /etc/ca-certificates/update.d...

OpenJDK Server VM warning: Option AssumeMP was deprecated in version 10.0 and will likely be removed in a future release.
done.
done.

With this fix:

diff --git a/debian/jks-keystore.hook.in b/debian/jks-keystore.hook.in
index d4a67d0..5bdc65b 100644
--- a/debian/jks-keystore.hook.in
+++ b/debian/jks-keystore.hook.in
@@ -79,7 +79,7 @@ do_cleanup()
     fi
 }
 
-if java -Xmx64m -jar $JAR -storepass "$storepass"; then
+if java -Xmx64m -XX:-AssumeMP -jar $JAR -storepass "$storepass"; then
     do_cleanup
 else
     do_cleanup
diff --git a/debian/postinst.in b/debian/postinst.in
index bc78c6e..30d0846 100644
--- a/debian/postinst.in
+++ b/debian/postinst.in
@@ -98,7 +98,7 @@ first_install()
     # Forcibly remove diginotar cert (LP: #920758)
     if [ -n "$FIXOLD" ]; then
         echo -e "-diginotar_root_ca\n-diginotar_root_ca_pem" | \
-        java -Xmx64m -jar $JAR -storepass "$storepass"
+        java -Xmx64m -XX:-AssumeMP -jar $JAR -storepass "$storepass"
     fi
 
     find /etc/ssl/certs -name \*.pem | \
@@ -111,7 +111,7 @@ first_install()
         fi
         echo "+${filename}"
     done | \
-    java -Xmx64m -jar $JAR -storepass "$storepass"
+    java -Xmx64m -XX:-AssumeMP -jar $JAR -storepass "$storepass"
     echo "done."
 }

Regards,

Hi Robert,

Thank you very much for the fixing. I have installed default-jre (11) without error.

Best Regards,

David

Tips to Fix a Runtime Error

Restart the computer.
Update the program to its latest version.
Fully delete the program, and then reinstall it.
Install the latest Microsoft Visual C++ Redistributable package.
Use SFC scannow to repair corrupted Windows files.
Run System Restore to return your computer to a previous state.

Greeting,
Rachel Gomez

Thanks for sharing, Rachel.

This issue was fixed in Debian’s java package. The device in question is a BeagleBone Black, running Debian.

Closing thread, if you are seeing a similar issue please create a new thread.