Using the Dr. Watson tool to enable and collect system dumps on Windows.
About this task
In some scenarios, you might want to disable the Java™ runtime signal handler so that any signals
received are handled by the operating system. The -Xrs and
-Xrs:sync command-line options stop the Java runtime environment from handling
exception signals. For some exception signals, a system dump is produced.
On
versions of Windows before Windows Vista and Windows 2008 server, use the Dr Watson tool
to enable system dumps.
Windows Vista
and Windows 2008 Server
do not provide the Dr. Watson tool. The replacement is the Problem
Reports and Solutions Control Panel applet. This tool cannot
be used to take a full system dump without first uploading the problem
report data to Microsoft.
On Windows 7
you can use the Task Manager to create a system dump.
To enable
system dumps using the Dr. Watson tool:
Procedure
- Open the Dr Watson configuration window by clicking Start,
selecting Run, and typing drwtsn32 in
the Open field. Click OK.
- Complete the fields in the configuration window as follows.
- Set the Log File Path field to
a location with several hundred MB of free space.
- Set the Crash Dump field to point
to a file called user.dmp in the Log
File Path.
When an error occurs in JNI code
or the Java runtime environment, the dump
is stored in this file.
- Set the Number of Instructions field
to 20.
- Set the Number of Errors To Save field
to 20.
- Set the Crash Dump Type field
to NT4 compatible Full or Full,
depending on which option is available.
The available options
vary depending on the version of Windows in
use.
- Select the remaining option boxes as shown in the screen
capture.
- Click OK to save the settings.
- Install Dr Watson as the default application debugger by
clicking Start, selecting Run,
and typing drwtsn32 -i in the Open field.
Click OK.
A window opens,
reporting that Dr. Watson has been installed as the default application
debugger.
- To use Dr. Watson for collecting system dumps, run your
application and reproduce the error.
When the error
occurs, a dialog opens reporting that Java encountered
a problem and had to close. Click OK to continue.
- (Optional) If you set the Visual Notification option
in the screen capture, a window opens, reporting that an error log
is being created. Wait until the Cancel button
changes to OK. Click OK to
continue.
-
The system dump is stored in the location specified in the Crash Dump
field. For information about analyzing the system dump file, see Dump viewer.
Results
Dr. Watson has been installed as the default application debugger
and used when a system dump is created.