Sun GlassFish Enterprise Server v3 Administration Guide

Administering the Profiler

A profiler generates information used to analyze server performance. The following topics are addressed here:

ProcedureTo Create a Profiler

A server instance is tied to a particular profiler by the profiler element in the Java configuration. If JVM options are created for a profiler, the options are used to record the settings needed to activate a particular profiler. Use the create-profiler subcommand in remote mode to create the profiler element in the Java configuration.

Only one profiler can exist. If a profiler already exists, you receive an error message that directs you to delete the existing profiler before creating a new one.

  1. Ensure that the server is running.

    Remote subcommands require a running server.

  2. Create a profiler by using the create-profiler(1) subcommand.

    Information about properties for the subcommand is included in this help page.

  3. To apply your changes, restart Enterprise Server.

    See To Restart a Domain.


Example 4–6 Creating a Profiler

This example creates a profiler named sample_profiler.


asadmin> create-profiler --classpath=/home/appserver/ --nativelibrarypath=/u/home/lib
--enabled=false --property=defaultuser=admin:password=adminadmin sample_profiler
Command create-profiler executed successfully.

See Also

You can also view the full syntax and options of the subcommand by typing asadmin help create-profiler at the command line.

ProcedureTo Delete a Profiler

Use the delete-profiler subcommand in remote mode to delete the profiler element from the Java configuration. You can then create a new profiler.

  1. Ensure that the server is running.

    Remote subcommands require a running server.

  2. Delete the profiler by using the delete-profiler(1) subcommand.

  3. To apply your changes, restart Enterprise Server.

    See To Restart a Domain.


Example 4–7 Deleting a Profiler

This example deletes the profiler named sample_profiler.


asadmin> delete-profiler sample_profiler
Command delete-profiler executed successfully.

See Also

You can also view the full syntax and options of the subcommand by typing asadmin help delete-profiler at the command line.