Can I set the output location of a JVM crash minidump?

400 Views Asked by At

We are currently experiencing a JVM crash with Java 8u60 32-bit that we are attempting to debug. In order to do this I need to create a minidump using the JVM command line argument -XX:+CreateMinidumpOnCrash. Our operating system is write protected so as to avoid corruptions. I won't go into detail there but this causes any minidumps to get deleted any time the system reboots.

I want to change the output directory and naming scheme of the dump to a location on a non-write protected SSD with drive letter D:. This will greatly improve the likelyhood of getting a crash dump I can use.

Is it possible to do this with JVM arguments? I know its possible to do with general crash reports using the -XX:ErrorFile argument (I am already doing this) so I am wondering if its possible to do the same with a minidump. I've checked some documentation but haven't been able to find anything about it there or online.

At this point I am assuming its not possible but maybe someone here can shed some light on the concrete facts? Any links to documentation I may have missed would be helpful.

Thanks

1

There are 1 best solutions below

0
vaibhavsahu On

To change the destination of the jvm crash log run java with this option:

java -XX:ErrorFile=/path/to/file.log -jar myapp.jar