![]() ![]() |
There are several ways to start a JRA recording:
Note: | If you are running Mission Control on a Windows system, you need to be a member of the Administrators or the Performance Logs user groups to be able to create a JRA recording. The typical error message, for not being part of either of these groups, can look like this: [perf ] Failed to init virtual size counter: |
-Xmanagement
option to the command line.If you run the application without load, the data captured from that application will not show where there is room for improvements.
The JRA Recording dialog box appears (Figure 3-1).
The file is created in the current directory of the BEA JRockit process, unless you specify a different path. If an old file already exists, it will be overwritten by the new recording.
Note: | If you set a time that is too short, e.g. shorter than 30 seconds, you will probably not get enough sample data for the recording to be meaningful. |
The JRA recording progress window appears. When the recording is finished, it loads in the JRA tool.
If you run the application without stress, the data captured from that application will not show where there is room for improvements.
bin\jrcmd.exe <pid> jrarecording time=<jrarecording time> filename=<filename>
bin/jrcmd <pid> jrarecording time=<jrarecording time> filename=<filename>
jrarecording time
-the duration of the recording in seconds (a good length is 300 seconds, i.e., five minutes).filename
-the name of the file you want to save the recording to (for example jrarecording.xml.zip
). The file will be created in the current directory of the JRockit process. It will be overwritten if it already exists.
For example:bin\jrcmd.exe <pid> jrarecording time=300 filename=c:\temp\jra.xml.zip
Starts a JRA recording of 300s and stores the result in the specified file.
After the recording is initiated, BEA JRockit prints a message indicating that the recording has started. When the recording is done, it will print another message; it is now safe to shut down your application.
Use the -XXjra
command in combination with an option listed in Table 3-1, for example, -XXjra:recordingtime
to specify the duration of the recording.
Note: | Setting methodtraces to false can still result in some stack traces being captured. These stack traces are captured as part of JRockit's dynamic optimizations and will have a depth of 3. If optimizations are turned off (-Xnoopt ) these traces will not be captured. |
You can view the startup options that you have set in the JRA recording, see Viewing VM Arguments Information. Listing 3-1 shows an example of how you can setup a JRA recording.
-XXjra:delay=10,recordingtime=100,filename=jrarecording2.xml
would result in a recording that:
The overhead while recording is very low-typically less than two percent. However, since JRA is forcing a full garbage collection at the beginning and at the end of the recording to generate the heap histogram data, there may be a spike at the beginning and at the end of a recording.
![]() ![]() |