Intellij IDEA - 解决程序运行一段时间后报“Failed to write core dump. Minidumps are...”错误
作者:hangge | 2022-12-16 08:40
1,问题描述
最近在 Intellij IDEA 中运行一个 Java 程序,开始时都正常,但运行一段时间后就会报如下错误然后自动退出程序:
# EXCEPTION_ACCESS_VIOLATION (0xc0000005) at pc=0x000007fed806074c, pid=9912, tid=0x0000000000001150
#
# JRE version: Java(TM) SE Runtime Environment (8.0_101-b13) (build 1.8.0_101-b13)
# Java VM: Java HotSpot(TM) 64-Bit Server VM (25.101-b13 mixed mode windows-amd64 compressed oops)
# Problematic frame:
# C [avformat-58.dll+0x5074c]
#
# Failed to write core dump. Minidumps are not enabled by default on client versions of Windows
#
# An error report file with more information is saved as:
# G:\workspace_java\VideoCapture\VideoCapture\hs_err_pid9912.log
#
# If you would like to submit a bug report, please visit:
# http://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.
2,解决办法
(1)打开项目的 Configurations 配置页面,然后在 VM options 栏目中添加如下虚拟机启动参数:
- 对于 JDK8 及以下版本:-XX:+CreateMinidumpOnCrash
- 对于 JDK9 及以上版本:-XX:CreateCoredumpOnCrash
(2)确定后重新运行程序即可。
全部评论(0)