A fatal error has been detected by the Java Runtime Enviro

Myeclipse中启动一个项目(项目过大、架构不合理,加载其他项目都正常)会报如下错误:

An unrecoverable stack overflow has occurred.

#

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

#

#  EXCEPTION_STACK_OVERFLOW (0xc00000fd) at pc=0x62d5bd47, pid=6172, tid=3452

#

# JRE version: 6.0_45-b06

# Java VM: Java HotSpot(TM) Client VM (20.45-b01 mixed mode windows-x86 )

# Problematic frame:

# C  [winhadnt.dll+0x9bd47]

#

# An error report file with more information is saved as:

# D:\Program Files\apache-tomcat-6.0.37\bin\hs_err_pid6172.log

#

# If you would like to submit a bug report, please visit:

#   http://java.sun.com/webapps/bugreport/crash.jsp

# The crash happened outside the Java Virtual Machine in native code.

# See problematic frame for where to report the bug.

#

 

报错环境

   MyEclipse7

   JDK1.6

   Tomcat6.0

   电脑内存4G

   JVM内存256m-512m

报错频率

之前可以正常运行项目,后面也没改配置就出现如下问题

报错原因

      据网上了解,JIT在做编译优化的时候处理时出错,可能是触发了JVM的编译器的BUG导致的。SUN提供了相关的文档说明,文档地址:http://www.oracle.com/technetwork/java/javase/crashes-137240.html#gbyzu

解决办法

1.  把开发环境换成Eclipse(最可靠的方法);

2.  如果是MyEclipse启动,myeclipse-preference-java-installed jres 里面设置, defalt vm arguments 填入:

-XX:CompileCommand=exclude,org/hibernate/cfg/annotations/SimpleValueBinder,setType 

3.  如果是直接通过startup 启动tomcat,则需要修改以下文件 Windows下,在文件/bin/catalina.batUnix下,在文件/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% 

你可能感兴趣的:(Runtime)