Tomcat启动报A fatal error has been detected by the Java Runtime Environment
#
# A fatal error has been detected by the Java Runtime Environment:
#
# SIGSEGV (0xb) at pc=0x00002ba9d88e02da, pid=17844, tid=1076017472
#
# JRE version: 6.0_29-b11
# Java VM: Java HotSpot(TM) 64-Bit Server VM (20.4-b02 mixed mode linux-amd64 compressed oops)
# Problematic frame:
# C [libc.so.6+0x732da] short+0x3a
#
# An error report file with more information is saved as:
# /home/iptv/bss/apache-tomcat-6.0.26/bin/hs_err_pid17844.log
#
# If you would like to submit a bug report, please visit:
# http://java.sun.com/webapps/bugreport/crash.jsp
#
问题的原因就在于 显示JIT在做编译优化的时候处理 某个方法时出错。
本利的错误是这个方法
- org.hibernate.cfg.annotations.SimpleValueBinder.setType
解决办法:让jvm跳过该方法的编译优化
在jvm启动参数中添加启动参数
- -XX:CompileCommand=exclude,org/hibernate/cfg/annotations/SimpleValueBinder,setType
如果是
eclipse下启动服务,则在eclipse-preference-java-installed jres 里面设置,
在 defalt vm arguments 填入上面的代码就可以了。
如果是
直接通过startup 启动tomcat,则需要修改以下文件
Windows下,在文件/bin/catalina.bat,Unix下,在文件/bin/catalina.sh
找到
- set JAVA_OPTS=%JAVA_OPTS% %LOGGING_CONFIG%
修改为
- set JAVA_OPTS=%JAVA_OPTS% -XX:CompileCommand=exclude,org/hibernate/cfg/annotations/SimpleValueBinder,setType %LOGGING_CONFIG%

在Default VM Arguments中加入:
-XX:CompileCommand=exclude,org/hibernate/cfg/annotations/SimpleValueBinder,setType
这句就可以了,确实加入就可以了,但是怎么感觉有点莫名其妙呢,也没说出错的原因,哪位碰到过,这个问题到底是由什么原因造成的呢?
补充:
加上这句话后,启动tomcat的时候,控制台输出了这样的字样:

Tomcat启动报A fatal error has been detected by the Java Runtime Environment的更多相关文章
- A fatal error has been detected by the Java Runtime Environment(jdk 1.6的一个BUG)
几天做项目,生成一堆注解的实体,当实体数超过86个时,jvm报错: # # A fatal error has been detected by the Java Runtime Environmen ...
- Java服务突然失败:A fatal error has been detected by the Java Runtime Environment的总结
服务启动以后过段时间自动失败:A fatal error has been detected by the Java Runtime Environment 控制台中的错误信息 A fatal err ...
- eplise中运行提示 A fatal error has been detected by the java runtime environment
今天一同事出现运行项目时,提示 A fatal error has been detected by the java runtime environment,具体表现是使用我们框架,不能正常的打印日 ...
- A fatal error has been detected by the Java Runtime Environment:
在Eclipse中运行项目 遇到如下错误: ## A fatal error has been detected by the Java Runtime Environment:## EXCEPTIO ...
- centos6的kibana7.1无法启动报错 FATAL Error: /lib64/libc.so.6: version `GLIBC_2.14' not found 升级glibc的问题处理
centos6的kibana7.1无法启动报错 FATAL Error: /lib64/libc.so.6: version `GLIBC_2.14' not found 升级glibc的问题处理 ...
- 启动eclipse出现“Error opening registry key 'software\Javasoft\Java Runtime Environment'”
启动eclipse出现“Error opening registry key 'software\Javasoft\Java Runtime Environment'”,“java was start ...
- Error: opening registry key 'Software\JavaSoft\Java Runtime Environment' Error: could not find java.dll
java -jar yxCollector-1.1.0.jarError: opening registry key 'Software\JavaSoft\Java Runtime Environme ...
- java command line error opening registry key 'Software\JavaSoft\Java Runtime Environment' java.dll
C:\Users\huxxxxchan>javaError: opening registry key 'Software\JavaSoft\Java Runtime Environment'E ...
- 安装JDK出现问题 Error opening registry key'software\Javasoft\Java Runtime Environment'
第一次安装JDK测试是否安装成功,打开cmd输入java -version 回车的时候出现如下错误: Error opening registry key'software\Javasoft\Java ...
- Error: opening registry key 'Software\JavaSoft\Java Runtime Environment' could not find java.dll
Error: opening registry key 'Software\JavaSoft\Java Runtime Environment'Error: could not find java.d ...
随机推荐
- 关于C#中async/await的用法
一直对c#中async/await的用法模模糊糊,不太清晰,今天写了一下Demo彻底明确一下async/await的用法,以免因为对其不了解而对后期的业务产生影响(比如事务导致的锁表等等). 1. 首 ...
- docker命令之docker build
docker命令之docker build 明天要讲docker file的公开课,正好借此机会,整理下docker 命令的专题 语法 docker build [OPTIONS] PATH | UR ...
- java 金额计算
package com.example.test; import android.util.Log; import java.math.BigDecimal; import java.text.Dec ...
- 【Oculus Interaction SDK】(六)实体按钮 && 按压交互
前言 这篇文章是[Oculus Interaction SDK]系列的一部分,如果发现有对不上的对方,可以回去翻看我之前发布的文章,或在评论区留言.如果文章的内容已经不适用于新版本了,也可以直接联系我 ...
- idea2022.2.3安装破解
转:https://www.quanxiaoha.com/article/idea-pojie.html 1 注意事项 如果是卸载了旧版本安装的本版本,安装完成后打不开,可能是旧版本的影响 找到:C: ...
- rt-thread模糊到清晰系列: irq.c
#include <rthw.h> #include <rtthread.h> // 进入离开中断的钩子函数 #ifdef RT_USING_HOOK static void ...
- 2021级《JAVA语言程序设计》上机考试试题6
首先管理员页面 代码: <%@ page language="java" contentType="text/html; charset=UTF-8" p ...
- aop中的名词解释
aop中的名词解释 aop spring Joinpoint(连接点) 目标对象中所有可以增强的方法叫做连接点 Pointcut(切入点) 目标对象中要增强的的方法 Advice(通知/增强) 增强的 ...
- 前端开发工具VsCode官网下载太慢?直接失败?
我有个朋友来到公司以后,在搭建基本开发环境时,什么nodejs安装包,vscode包等等都是由同事直接分享,然后一键安装,从来没去过官网下载,以至于想更新新版本的时候首次进入官网有点懵逼,相信很多同学 ...
- OpenSCAD:一款用于创建实体3D CAD对象的软件
推荐:使用 NSDT场景设计器 快速搭建 3D场景. 原文链接:https://www.mvrlink.com/openscad/ OpenSCAD是一个用于创建实体3D CAD对象的软件.它是免费软 ...