top bar

Difference between revisions of "Viewing crash dumps on Windows"

(Viewing Micro-Manager crash dumps on Windows)
(Viewing Micro-Manager crash dumps on Windows)
Line 1: Line 1:
=== Viewing Micro-Manager crash dumps on Windows ===
+
=== Viewing Java Virtual Machine crash dumps ===
  
 
If you are running Micro-Manager in the normal way (with the GUI), the Java Virtual Machine will save a crash dump if the whole program crashes. Most of the time, such a crash means that something went wrong in one of the C++ components of Micro-Manager.
 
If you are running Micro-Manager in the normal way (with the GUI), the Java Virtual Machine will save a crash dump if the whole program crashes. Most of the time, such a crash means that something went wrong in one of the C++ components of Micro-Manager.
Line 6: Line 6:
  
 
Although the JVM normally can catch errors that cause the process to crash (such as access violations (= segmentation faults)), sometimes the memory corruption (or some other condition) resulting from the error is severe enough to cause the JVM's crash handler to fail or not be executed. In that case, the only way to see what happened (save for running Micro-Manager with a debugger attached) is to have Windows produce crash dumps.
 
Although the JVM normally can catch errors that cause the process to crash (such as access violations (= segmentation faults)), sometimes the memory corruption (or some other condition) resulting from the error is severe enough to cause the JVM's crash handler to fail or not be executed. In that case, the only way to see what happened (save for running Micro-Manager with a debugger attached) is to have Windows produce crash dumps.
 +
 +
=== Generating Windows application crash dumps ===
  
 
{{Note|The crash dumps saved by this method are binary files. You need a Microsoft debugger (e.g. windbg.exe) to view them.}}
 
{{Note|The crash dumps saved by this method are binary files. You need a Microsoft debugger (e.g. windbg.exe) to view them.}}
  
Windows crash dumps are disabled by default (to be precise, saving them locally is disabled by default - as I understand it there is some elaborate mechanism to send the dumps to Microsoft, but that is not helpful for our purpose). To enable local saving of crash dumps on Windows Vista or later, download [[Media:SaveJVMCrashDumps.zip|this file]], extract the .reg file, and open it as administrator, which will add the necessary settings to the Windows registry. (See [http://msdn.microsoft.com/en-us/library/windows/desktop/bb787181.aspx Microsoft's documentation] for details on this.)
+
Windows crash dumps are disabled by default (to be precise, saving them locally is disabled by default - as I understand it there is some elaborate mechanism to send the dumps to Microsoft, but that is not helpful for our purpose). To enable local saving of crash dumps on Windows Vista, 7, or later, download [[Media:SaveJVMCrashDumps.zip|this file]], extract the .reg file, and open it (administrator permission will be required), which will add the necessary settings to the Windows registry. (See [http://msdn.microsoft.com/en-us/library/windows/desktop/bb787181.aspx Microsoft's documentation] for details on this.)
  
 
Following this setup, when java.exe or javaw.exe crashes, a crash dump should be saved at
 
Following this setup, when java.exe or javaw.exe crashes, a crash dump should be saved at
  
   %LOCALAPPDATA%\CrashDumps\java.exe.*.dmp
+
   %LocalAppData%\CrashDumps\java.exe.*.dmp
  
 
or
 
or
  
   %LOCALAPPDATA%\CrashDumps\javaw.exe.*.dmp
+
   %LocalAppData%\CrashDumps\javaw.exe.*.dmp
 +
 
 +
where the location of <code>%LocalAppData%</code> can be checked by typing <code>echo %LocalAppData%</code> into the Command Prompt. The App Data directory is hidden by default; the easiest way to open the CrashDumps folder is to open a Command Prompt and type
 +
 
 +
  start %LocalAppData%\CrashDumps
 +
 
 +
Note that crash dump files can get quite large (especially if the application is using a lot of memory).
  
where the location of <code>%LOCALAPPDATA%</code> can be checked by typing <code>echo %LOCALAPPDATA%</code> into the Command Prompt. The App Data directory is normally hidden, so you will need to set Windows to display hidden files or access it from the Command Prompt.
+
[[Media:StopSavingAllCrashDumps.zip|This file]] will disable the saving of all Windows crash dumps.
  
 
If you are running Windows XP, the method described on [https://help.github.com/articles/getting-a-crash-dump this page] should work.
 
If you are running Windows XP, the method described on [https://help.github.com/articles/getting-a-crash-dump this page] should work.

Revision as of 21:44, 8 January 2014

Viewing Java Virtual Machine crash dumps

If you are running Micro-Manager in the normal way (with the GUI), the Java Virtual Machine will save a crash dump if the whole program crashes. Most of the time, such a crash means that something went wrong in one of the C++ components of Micro-Manager.

JVM crash dumps are named hs_err_pid*.log, with the process id of the JVM that crashed, and are placed in the Micro-Manager folder.

Although the JVM normally can catch errors that cause the process to crash (such as access violations (= segmentation faults)), sometimes the memory corruption (or some other condition) resulting from the error is severe enough to cause the JVM's crash handler to fail or not be executed. In that case, the only way to see what happened (save for running Micro-Manager with a debugger attached) is to have Windows produce crash dumps.

Generating Windows application crash dumps

Note
The crash dumps saved by this method are binary files. You need a Microsoft debugger (e.g. windbg.exe) to view them.

Windows crash dumps are disabled by default (to be precise, saving them locally is disabled by default - as I understand it there is some elaborate mechanism to send the dumps to Microsoft, but that is not helpful for our purpose). To enable local saving of crash dumps on Windows Vista, 7, or later, download this file, extract the .reg file, and open it (administrator permission will be required), which will add the necessary settings to the Windows registry. (See Microsoft's documentation for details on this.)

Following this setup, when java.exe or javaw.exe crashes, a crash dump should be saved at

 %LocalAppData%\CrashDumps\java.exe.*.dmp

or

 %LocalAppData%\CrashDumps\javaw.exe.*.dmp

where the location of %LocalAppData% can be checked by typing echo %LocalAppData% into the Command Prompt. The App Data directory is hidden by default; the easiest way to open the CrashDumps folder is to open a Command Prompt and type

 start %LocalAppData%\CrashDumps

Note that crash dump files can get quite large (especially if the application is using a lot of memory).

This file will disable the saving of all Windows crash dumps.

If you are running Windows XP, the method described on this page should work.

© Micro-Manager : Vale Lab, UCSF 2006-2011 | All Rights Reserved | Contact