JVM Crash due to SIGSEGV

前端 未结 3 431
囚心锁ツ
囚心锁ツ 2021-01-11 16:50

Our server hung because of a SIGSEGV fault..

A fatal error has been detected by the Java Runtime Environment:

  SIGSEGV (0xb) at pc=0x00007ff5c7195aa         


        
3条回答
  •  陌清茗
    陌清茗 (楼主)
    2021-01-11 17:04

    There is one catchy situation in JNI code: when such a code blocks SIGSEGV signal e.g. because it blocks all signals (quite common approach in threaded C code how to ensure that only main thread will process signals) AND it calls 'back' Java VM (aka callback) then it can result in quite random SIGSEGV-triggered aborting of the process.
    And there is virtually nothing wrong - SIGSEGV is actually triggered by Java VM in order to detect certain conditions in memory (it acts as memory barrier … etc) and it expects that such a signal will be handled by Java VM. Unfortunately when SIGSEGV is blocked, then 'standard' SIGSEGV reaction is triggered => VM process crashes.

提交回复
热议问题