$ /opt/java1.4/bin/java -Xms256m -Xmx512m -Xbootclasspath/a:/opt/hpjmeter/lib/agent.jar -Xrunjmeter myapp

NOTE:

With the addition of JVMTI in JDK 5.0, you should use the -agentlibswitch to take advantage of improvements in JDK 5.0 and reduce the impact of data sampling on application performance. While -Xrunjmetercan still be used to specify the JVM agent with Java 5 versions, the impact on application performance is significantly greater than when using -agentlib.

Starting with Java 5.0, -agentlibis the standard way to specify the JVM agent. Therefore, this document will refer primarily to -agentlib.

Using an alternate HPjmeter library to work with applications that are run with the –V2option on PA systems:

$ /opt/java1.5/bin/java -V2 –agentlib:jmeter_v2 myapp

JVM Agent Options

This section provides the list of options for changing the JVM agent behavior and determining the Java version running on the system.

Showing Version InformationTo show the version information, use-agentlib:jmeter=version

OR

-Xrunjmeter:versionSelecting Other JVM Agent OptionsAdd other options using this syntax-agentlib:jmeter[[=version][=option[[,option]]...]]

OR

-Xrunjmeter[:[version][option[[,option]]...]]where option may be any of these:appserver_port=port

Associates a port number with a JVM process when it is displayed in the console. This port number is unrelated to the port number used by the node agent, and so it is also unrelated to the optional port number that can be specified in the console when attaching to a managed node.

It does not affect any communication, and is only part of the user interface. The appserver_port= usually corresponds to the port to which the application server listens.

Example usage: -agentlib:jmeter=appserver_port=7001group_private

Specifies that the JVM will be visible only to node agents run with the same group-id; that is, run by the user belonging to the same group, as the one who runs the JVM. This limitation does not apply to node agents run as root (the installation default). This is the default behavior on HP-UX systems.

You can specify only one of the options owner_private, group_private or public.

Example usage: -agentlib:jmeter=group_private

Configuring your Application to Use HPjmeter Command Line Options 17