Uploaded image for project: 'Java Couchbase JVM Core'
  1. Java Couchbase JVM Core
  2. JVMCBC-942

Shaded native Netty libraries segfault on Alpine

    XMLWordPrintable

Details

    • Improvement
    • Status: Resolved
    • Major
    • Resolution: Won't Fix
    • 2.1.0
    • None
    • None
    • None
    • 1

    Description

      Something in Netty 4.1.54.FINAL broke native shading on alpine.

      The unshaded versions work fine.

      The shaded versions work fine on debian.

      Attachments

        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

        Activity

          the segmentation fault looks like this:

          #

          1. A fatal error has been detected by the Java Runtime Environment:
            #
            # SIGSEGV (0xb) at pc=0x0000000000003efe, pid=12, tid=13
            #
          2. JRE version: OpenJDK Runtime Environment Corretto-11.0.9.12.1 (11.0.9+12) (build 11.0.9+12-LTS)
          3. Java VM: OpenJDK 64-Bit Server VM Corretto-11.0.9.12.1 (11.0.9+12-LTS, mixed mode, tiered, compressed oops, g1 gc, linux-amd64)
          4. Problematic frame:
          5. C 0x0000000000003efe
            #
          6. Core dump will be written. Default location: //core.12
            #
          7. An error report file with more information is saved as:
          8. //hs_err_pid12.log
            #
          9. If you would like to submit a bug report, please visit:
            #   https://bugreport.java.com/bugreport/crash.jsp
          10. The crash happened outside the Java Virtual Machine in native code.
          11. See problematic frame for where to report the bug.
            #
            Aborted (core dumped)Contents of the crash log --------------- S U M M A R Y ------------Command Line: /usr/local/digitsOrchestratorService.warHost: Intel(R) Xeon(R) CPU E5-2698 v3 @ 2.30GHz, 4 cores, 7G, Alpine Linux v3.12
            Time: Tue Jun 29 19:49:04 2021 UTC elapsed time: 9.457770 seconds (0d 0h 0m 9s)-------------- T H R E A D --------------Current thread (0x000055e769dad800): JavaThread "main" [_thread_in_native, id=13, stack(0x00007fc3d92a7000,0x00007fc3d93a7ac0)]Stack: [0x00007fc3d92a7000,0x00007fc3d93a7ac0], sp=0x00007fc3d939c6f8, free space=981k
            Native frames: (J=compiled Java code, A=aot compiled Java code, j=interpreted, Vv=VM code, C=native code)
            C 0x0000000000003efe
            [libcom_couchbase_client_core_deps_netty_transport_native_epoll_x86_647054874928080640492.so+0xb487] netty_jni_util_JNI_OnLoad+0x67
            [libjava.so+0xfc2a] Java_java_lang_ClassLoader_00024NativeLibrary_load0+0xba
            j java.lang.ClassLoader$NativeLibrary.load0(Ljava/lang/String;Z)Z+0 java.base@11.0.9
            j java.lang.ClassLoader$NativeLibrary.load()Z+53 java.base@11.0.9
            j java.lang.ClassLoader$NativeLibrary.loadLibrary(Ljava/lang/Class;Ljava/lang/String;Z)Z+216 java.base@11.0.9
            j java.lang.ClassLoader.loadLibrary0(Ljava/lang/Class;Ljava/io/File;)Z+46 java.base@11.0.9
            j java.lang.ClassLoader.loadLibrary(Ljava/lang/Class;Ljava/lang/String;Z)V+70 java.base@11.0.9
            j java.lang.Runtime.load0(Ljava/lang/Class;Ljava/lang/String;)V+57 java.base@11.0.9
            j java.lang.System.load(Ljava/lang/String;)V+7 java.base@11.0.9
            com.couchbase.client.core.deps.io.netty.util.internal.NativeLibraryUtil.loadLibrary(Ljava/lang/String;Z)V+5
            v ~StubRoutines::call_stub
            [libjvm.so+0x8671c9]
            [libjvm.so+0xc7cb71]
            [libjvm.so+0xc7d460]
            [libjvm.so+0x91ea6c] JVM_InvokeMethod+0x13c
            J 3539 jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Ljava/lang/reflect/Method;Ljava/lang/Object;[Ljava/lang/Object;)Ljava/lang/Object; java.base@11.0.9 (0 bytes) @ 0x00007fc3c9710fb0 [0x00007fc3c9710ec0+0x00000000000000f0]
            J 3538 c1 jdk.internal.reflect.NativeMethodAccessorImpl.invoke(Ljava/lang/Object;[Ljava/lang/Object;)Ljava/lang/Object; java.base@11.0.9 (104 bytes) @ 0x00007fc3c26e2c0c [0x00007fc3c26e2040+0x0000000000000bcc]
            J 2997 c1 jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(Ljava/lang/Object;[Ljava/lang/Object;)Ljava/lang/Object; java.base@11.0.9 (10 bytes) @ 0x00007fc3c255c4bc [0x00007fc3c255c3c0+0x00000000000000fc]
            J 2794 c1 java.lang.reflect.Method.invoke(Ljava/lang/Object;[Ljava/lang/Object;)Ljava/lang/Object; java.base@11.0.9 (65 bytes) @ 0x00007fc3c24df14c [0x00007fc3c24dee20+0x000000000000032c]
            com.couchbase.client.core.deps.io.netty.util.internal.NativeLibraryLoader$1.run()Ljava/lang/Object;+53
          michael.reiche Michael Reiche added a comment - the segmentation fault looks like this: # A fatal error has been detected by the Java Runtime Environment: # # SIGSEGV (0xb) at pc=0x0000000000003efe, pid=12, tid=13 # JRE version: OpenJDK Runtime Environment Corretto-11.0.9.12.1 (11.0.9+12) (build 11.0.9+12-LTS) Java VM: OpenJDK 64-Bit Server VM Corretto-11.0.9.12.1 (11.0.9+12-LTS, mixed mode, tiered, compressed oops, g1 gc, linux-amd64) Problematic frame: C 0x0000000000003efe # Core dump will be written. Default location: //core.12 # An error report file with more information is saved as: //hs_err_pid12.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. # Aborted (core dumped)Contents of the crash log --------------- S U M M A R Y ------------Command Line: /usr/local/digitsOrchestratorService.warHost: Intel(R) Xeon(R) CPU E5-2698 v3 @ 2.30GHz, 4 cores, 7G, Alpine Linux v3.12 Time: Tue Jun 29 19:49:04 2021 UTC elapsed time: 9.457770 seconds (0d 0h 0m 9s)--------------  T H R E A D  --------------Current thread (0x000055e769dad800): JavaThread "main" [_thread_in_native, id=13, stack(0x00007fc3d92a7000,0x00007fc3d93a7ac0)] Stack: [0x00007fc3d92a7000,0x00007fc3d93a7ac0] , sp=0x00007fc3d939c6f8, free space=981k Native frames: (J=compiled Java code, A=aot compiled Java code, j=interpreted, Vv=VM code, C=native code) C 0x0000000000003efe C  [libcom_couchbase_client_core_deps_netty_transport_native_epoll_x86_647054874928080640492.so+0xb487]  netty_jni_util_JNI_OnLoad+0x67 C  [libjava.so+0xfc2a]  Java_java_lang_ClassLoader_00024NativeLibrary_load0+0xba j java.lang.ClassLoader$NativeLibrary.load0(Ljava/lang/String;Z)Z+0  java.base@11.0.9 j java.lang.ClassLoader$NativeLibrary.load()Z+53  java.base@11.0.9 j java.lang.ClassLoader$NativeLibrary.loadLibrary(Ljava/lang/Class;Ljava/lang/String;Z)Z+216  java.base@11.0.9 j java.lang.ClassLoader.loadLibrary0(Ljava/lang/Class;Ljava/io/File;)Z+46  java.base@11.0.9 j java.lang.ClassLoader.loadLibrary(Ljava/lang/Class;Ljava/lang/String;Z)V+70  java.base@11.0.9 j java.lang.Runtime.load0(Ljava/lang/Class;Ljava/lang/String;)V+57  java.base@11.0.9 j java.lang.System.load(Ljava/lang/String;)V+7  java.base@11.0.9 j  com.couchbase.client.core.deps.io .netty.util.internal.NativeLibraryUtil.loadLibrary(Ljava/lang/String;Z)V+5 v ~StubRoutines::call_stub V  [libjvm.so+0x8671c9] V  [libjvm.so+0xc7cb71] V  [libjvm.so+0xc7d460] V  [libjvm.so+0x91ea6c]  JVM_InvokeMethod+0x13c J 3539 jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Ljava/lang/reflect/Method;Ljava/lang/Object;[Ljava/lang/Object;)Ljava/lang/Object;  java.base@11.0.9  (0 bytes) @ 0x00007fc3c9710fb0 [0x00007fc3c9710ec0+0x00000000000000f0] J 3538 c1 jdk.internal.reflect.NativeMethodAccessorImpl.invoke(Ljava/lang/Object;[Ljava/lang/Object;)Ljava/lang/Object;  java.base@11.0.9  (104 bytes) @ 0x00007fc3c26e2c0c [0x00007fc3c26e2040+0x0000000000000bcc] J 2997 c1 jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(Ljava/lang/Object;[Ljava/lang/Object;)Ljava/lang/Object;  java.base@11.0.9  (10 bytes) @ 0x00007fc3c255c4bc [0x00007fc3c255c3c0+0x00000000000000fc] J 2794 c1 java.lang.reflect.Method.invoke(Ljava/lang/Object;[Ljava/lang/Object;)Ljava/lang/Object;  java.base@11.0.9  (65 bytes) @ 0x00007fc3c24df14c [0x00007fc3c24dee20+0x000000000000032c] j  com.couchbase.client.core.deps.io .netty.util.internal.NativeLibraryLoader$1.run()Ljava/lang/Object;+53
          daschl Michael Nitschinger added a comment - Please see https://docs.couchbase.com/java-sdk/current/project-docs/compatibility.html#alpine-linux-compatibility
          daschl Michael Nitschinger added a comment - https://docs.couchbase.com/java-sdk/current/project-docs/compatibility.html#alpine-linux-compatibility

          People

            daschl Michael Nitschinger
            david.nault David Nault
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes

                PagerDuty