java - Tomcat crashes due to native code in JDK for malloc_consolidate -


the tomcat server in production crashes while javathread "finalizer" runs in jvm hs_err_pid below.

also, error comes java native code malloc_consolidate inside libc.so.

# problematic frame: # c  [libc.so.6+0x75f85]  malloc_consolidate+0xf5 # ---------------  t h r e d  ---------------  current thread (0x00007f2c6018f000):  javathread "finalizer" daemon [_thread_in_native, id=11112, stack(0x00007f2c3f1f2000,0x00007f2c3f2f3000)]   stack: [0x00007f2c3f1f2000,0x00007f2c3f2f3000],  sp=0x00007f2c3f2f13e0,  free space=1020k native frames: (j=compiled java code, j=interpreted, vv=vm code, c=native code) c  [libc.so.6+0x75f85]  malloc_consolidate+0xf5  java frames: (j=compiled java code, j=interpreted, vv=vm code) j 2177  java.util.zip.inflater.end(j)v (0 bytes) @ 0x00007f2c50e3d301 [0x00007f2c50e3d2c0+0x41] j 3502 c2 java.util.zip.zipfile.close()v (223 bytes) @ 0x00007f2c514371c4 [0x00007f2c51436900+0x8c4] j 7022 c2 java.util.zip.zipfile.finalize()v (5 bytes) @ 0x00007f2c511b43e0 [0x00007f2c511b43a0+0x40] j 11603% c2 java.lang.ref.finalizer$finalizerthread.run()v (55 bytes) @ 0x00007f2c528d6f78 [0x00007f2c528d6cc0+0x2b8] v  ~stubroutines::call_stub  heap:  psyounggen      total 2318848k, used 222178k [0x0000000720000000, 0x00000007c0000000, 0x00000007c0000000)   eden space 2016256k, 5% used [0x0000000720000000,0x0000000726d4fbe0,0x000000079b100000)   space 302592k, 36% used [0x000000079b100000,0x00000007a1ca8fe0,0x00000007ad880000)     space 289792k, 0% used [0x00000007ae500000,0x00000007ae500000,0x00000007c0000000)  paroldgen       total 2586624k, used 522596k [0x00000005e0000000, 0x000000067de00000, 0x0000000720000000)   object space 2586624k, 20% used [0x00000005e0000000,0x00000005ffe59390,0x000000067de00000)  metaspace       used 148258k, capacity 154058k, committed 154200k, reserved 1183744k   class space    used 18157k, capacity 19308k, committed 19328k, reserved 1048576k  internal exceptions (10 events): event: 61.804 thread 0x00007f2c2c0c6800 exception <a 'java/io/ioexception'> (0x0000000798129018) thrown @ [/hudson3/workspace/8-2-build-linux-amd64/jdk8u121/8372/hotspot/src/share/vm/prims/jni.cpp, line 709] event: 61.816 thread 0x00007f2c2c0c6800 exception <a 'java/io/ioexception'> (0x0000000798304680) thrown @ [/hudson3/workspace/8-2-build-linux-amd64/jdk8u121/8372/hotspot/src/share/vm/prims/jni.cpp, line 709] event: 61.816 thread 0x00007f2c2c0c6800 exception <a 'java/io/ioexception'> (0x0000000798305b90) thrown @ [/hudson3/workspace/8-2-build-linux-amd64/jdk8u121/8372/hotspot/src/share/vm/prims/jni.cpp, line 709] event: 62.015 thread 0x00007f2c2c0bb800 exception <a 'java/io/ioexception'> (0x0000000720db4188) thrown @ [/hudson3/workspace/8-2-build-linux-amd64/jdk8u121/8372/hotspot/src/share/vm/prims/jni.cpp, line 709] event: 62.015 thread 0x00007f2c2c0bb800 exception <a 'java/io/ioexception'> (0x0000000720db47e0) thrown @ [/hudson3/workspace/8-2-build-linux-amd64/jdk8u121/8372/hotspot/src/share/vm/prims/jni.cpp, line 709] event: 62.046 thread 0x00007f2c2c0bb800 exception <a 'java/io/ioexception'> (0x0000000720dbc2f0) thrown @ [/hudson3/workspace/8-2-build-linux-amd64/jdk8u121/8372/hotspot/src/share/vm/prims/jni.cpp, line 709] event: 62.046 thread 0x00007f2c2c0bb800 exception <a 'java/io/ioexception'> (0x0000000720dbd800) thrown @ [/hudson3/workspace/8-2-build-linux-amd64/jdk8u121/8372/hotspot/src/share/vm/prims/jni.cpp, line 709] event: 62.082 thread 0x00007f2c606f8800 exception <a 'java/lang/internalerror'> (0x0000000721cfe9b8) thrown @ [/hudson3/workspace/8-2-build-linux-amd64/jdk8u121/8372/hotspot/src/share/vm/prims/jni.cpp, line 735] event: 62.082 thread 0x00007f2c606f8800 exception <a 'java/lang/internalerror'> (0x0000000721cfeda8) thrown @ [/hudson3/workspace/8-2-build-linux-amd64/jdk8u121/8372/hotspot/src/share/vm/prims/jni.cpp, line 735] event: 62.082 thread 0x00007f2c606f8800 exception <a 'java/lang/internalerror'> (0x0000000721cfeda8) thrown @ [/hudson3/workspace/8-2-build-linux-amd64/jdk8u121/8372/hotspot/src/share/vm/prims/jvm.cpp, line 1394]  vm arguments: jvm_args: -xx:+heapdumponoutofmemoryerror -xx:heapdumppath=/tmp/heap -djava.util.arrays.uselegacymergesort=true -xms3072m -xmx7680m -dsun.zip.disablememorymapping=true  

-dsun.zip.disablememorymapping=true should fix issue, zip implementation improved in jdk 9, crash suggest that, during finalizer tries close file handle, still not released. upgrading jdk9 should avoid issue - https://jdk9.java.net/download/


Comments

Popular posts from this blog

php - Permission denied. Laravel linux server -

google bigquery - Delta between query execution time and Java query call to finish -

python - Pandas two dataframes multiplication? -