The information in this document is subject to change without notice.
Hewlett-Packard makes no warranty of any kind with regard to this manual, including, but not limited to, the implied warranties of merchantability and fitness
for a particular purpose. Hewlett-Packard shall not be held liable for errors contained herein or direct, indirect, special, incidental, or consequential
damages in connection with the furnishing, performance, or use of this material.
Warranty
A copy of the specific warranty terms applicable to your Hewlett-Packard product and replacement parts can be obtained from your local Sales
and Service Office.
U.S. Government License
Proprietary computer software. Valid license fromHP required for possession, use or copying.Consistent with FAR 12.211 and 12.212,Commercial
Computer Software, Computer Software Documentation, and Technical Data for Commercial Items are licensed to the U.S. Government under
vendor's standard commercial license.
You can find printable PDF versions of this user's guide and the release notes in the installation directory (doc subdirectory).
Viewing Monitoring Data in HPjmeter...............................................................................................103
Using Alerts........................................................................................................................................103
Using the Alert Controller.............................................................................................................105
Viewing a Log of the Alert History..........................................................................................107
This document provides updated information about product features, known problems, and
workarounds for the 4.2 release of HPjmeter.
Intended Audience
This document is intended for application administrators and software developers responsible
for monitoring Java application performance and operation on HP-UX. Users are expected to
have some knowledge of concepts and/or commands for the HP-UX operating system, usage of
the Java Virtual Machine on HP-UX, and Java application performance. When running the
HPjmeter console on a Microsoft® Windows® platform, the user is expected to be familiar with
installing executables and navigating the Windows file system.
Typographic Conventions
This document uses the following typographical conventions.
audit(5)A man page. The man page name is audit, and it is located in Section 5.
Command
ComputerOut
ENVIRONVARThe name of an environment variable, for example, PATH.
[ERRORNAME]
A command name or qualified command phrase.
Text displayed by the computer.
The name of an error, usually returned in the errno variable.
KeyThe name of a keyboard key. Return and Enter both refer to the same key.
UserInput
Variable
...The preceding element can be repeated an arbitrary number of times. A vertical
|Separates items in a list of choices.
Commands and other text that you type.
The name of a placeholder in a command, function, or other syntax display
that you replace with an actual value.
ellipsis indicates the continuation of a code example.
Additional HPjmeter Documents
•HPjmeter 4.2.00.00 Release Notes and Installation Guide: http://www.hp.com/go/
hpux-hpjmeter-docs.
•HPjmeter overview and access to software: https://h20392.www2.hp.com/portal/swdepot/
displayProductInfo.do?productNumber=HPJMETER .
Related Information
•JSR 174: Monitoring and Management Specification for the Java™ Virtual Machine at Java
Community Process web site: http://www.jcp.org/en/jsr/detail?id=174
•Java™ Troubleshooting Guide for HP-UX Systems: http://www.hp.com/go/hpux-java-docs
•Patch Information for Java on HP-UX: http://ftp.hp.com/pub/softlib/hpuxjava-patchinfo/
index.html
•HP-UX Secure Shell Getting Started Guide: http://www.hp.com/go/hpux-security-docs
•HP-UX System Administrator's Guide: Security Management, “Securing Remote Sessions Using
HP-UX Secure Shell” : http://www.hp.com/go/hpux-core-docs-11iv3
•Memory Management in the Java HotSpot™ Virtual Machine (Sun Developer Network): http://
The document publication date and part number indicate this document's current edition. The
publication date changes when a new edition is printed. Document updates may be issued
between editions to correct errors or document product changes. To ensure that you receive the
updated or new editions, subscribe to the appropriate product support service. See your HP
sales representative for details. You can find the latest version of this document on the HP Business
Support Center at http://www.hp.com/go/hpux-hpjmeter-docs.
Publication DateEdition NumberSoftware Version NumberHP Part Number
December 201114.2.00.005900-2022
September 201014.1.00.005900-1025
May 200914.0.00.005992-5899
June 200813.1.0.005992-0757
November 200613.0.0.005991-6757
September 200622.15991-6686
July 200612.15991-5846
February 200612.05991-5437
HP Encourages Your Comments
We encourage your comments concerning this document. We are committed to providing
documentation that meets your needs.
Please send your comments via the Customer Feedback web page: http://www.hp.com/bizsupport/
feedback/ww/webfeedback.html. Include the document title, HP part number, and any comment,
error found, or suggestion for improvement you have concerning this document. Also, please
let us know what we did right so we can incorporate it into other documents.
1 Introducing HPjmeter 4.2.00.00
HPjmeter is a performance analysis tool for deployed Java applications. It will help you identify
performance problems in your production environment as well as during development.
NOTE:You cannot use HPjmeter to monitor Java applets in a production environment.
HPjmeter helps you diagnose many types of Java application problems that occur only after a
product is deployed. The types of problems you can identify include:
•Memory-retention problems
•Performance bottlenecks in Java code
•Improper JVM heap settings
•Certain application logic errors, such as deadlocks
•Ineffective or problematic garbage collection
These problems may not be apparent or reproducible before you deploy your application because
they depend on unique conditions present only in deployment.
With HPjmeter you can also gain a comprehensive overview of certain states of a running JVM
and running applications, including details on memory usage, garbage collection, runtime, and
class loading, for example. Using HPjmeter's ability to interact with the Java Management
Extensions (JMX) component in the JVM, you can also manipulate operations during a monitoring
session to control the state of some logging mechanisms, to gather snapshots of stack traces and
memory details, and to force a garbage collection.
Features
With its application and JVM metrics, HPjmeter helps close the loop between developers and
operations staff.
HPjmeter has two modes of operation: you can use it to monitor live applications, and you can
analyze data collected from applications that have been run using profiling or garbage collection
options.
Specifically, HPjmeter provides these monitoring capabilities:
•Dynamic display of heap size and live objects in the heap
•Dynamic display of garbage collection events and percentage time spent ingarbage collection
•Memory leak detection alerts with leak rate
•Java Method HotSpots, which represent CPU usage per method
•Thread views displaying thread states over time
•Object allocation percentage by method and by object type
•Method compilation count in the JVM dynamic compiler
•Number of classes loaded by the JVM over time
•Thrown exception statistics
•Thread deadlock detection
•Visibility into standard MBean attributes, operations, and notifications (JSR 174) within the
•Visibility into user-defined MBeans, with the ability to modify attributes and trigger
•Multi-application, multi-node monitoring from a single console
HPjmeter provides these profiling capabilities:
•Graphic display of profiling data
•Heuristics on inlining, thrown exceptions, and memory leaks
Java Virtual Machine, with the ability to trigger operations from HPjmeter and enable or
disable notifications.
operations in real time, then monitor the resulting application behavior.
12Introducing HPjmeter 4.2.00.00
•Interactive call graph with call count, or with CPU or clock time, if available
•Per thread, per thread group, or per process display
•Allocated and residual objects with object reference graph
•Comparison capability for performance improvement tracking
HPjmeter provides these metrics for garbage collection (GC) analysis:
•Details and graphical display of object creation rate, changes in cumulative memory allocation
•Detailed summaries of GC activity and system resource allocation, along with other system
HPjmeter also provides these notification functions:
•Set notification thresholds for abnormal thread termination, excessive compilation, expected
•Set notification thresholds for levels of heap usage, process CPU, and system CPU.
•Enable or disable notifications.
•Change notification thresholds in real time to efficiently monitor targeted events
Concepts
HPjmeter contains these major components:
•The console – the primary control window where monitoring sessions are initiated and
•The monitoring agent – represents HPjmeter on each managed node. The agent has two
and in heap usage as related to GC events and types, and duration of GC events in the
recorded time period.
and JVM runtime and version data.
out-of-memory error, and memory leak rates.
controlled and where data files are opened and listed for access. The console presents data
in viewing windows that contain controls and functions specific to the data type and the
activity of the user.
subcomponents:
—The JVM agent: Each running JVM has an associated JVM agent that collects data and
sends it to a node agent, which sends it to the console.
—The HPjmeter node agent: Each managed node has a node agent that communicates
between the console and JVM agents.
JVM Agent
The JVM agent uses standard Java profiling interfaces (JVMTI and JVMPI) and a standard
monitoring and management interface (JSR174) to collect data from a running application and
to provide metrics to help detect and fix problems in that deployed application.
The JVM agent shares a process with a running JVM and forwards data through the node agent
to a console. Multiple consoles can connect to each of the multiple node agents on a managed
node. However, only one console and node agent can maintain an active session with a specific
JVM agent at any given time.
Node Agent
Node agents manage communication between JVM agents and consoles. The preferred way of
using node agents is to start the node agent as a daemon as root on each managed node.
Related Topics
•Managing Node Agents On HP-UX (page 37)
Concepts13
2 Completing Installation of HPjmeter
NOTE:This chapter assumes that you have installed the HPjmeter components on the
appropriate server(s) and are ready to configure the agents. For information on initial installation,
see HPjmeter Release Notes and Installation Guide.
Platform Support and System Requirements
Although the agents and console can execute on the same system, this document assumes they
are installed on separate systems—the recommended configuration.
Agent Requirements
These are the requirements for systems running JVM agents and node agents.
Table 2-1 Agent Requirements
HP-UX on HP 9000 PA-RISC serversOperating system and
architecture
11.11 (11i v1),
11.23 (11i v2),
11.31 (11i v3)
HP-UX on Itanium®-based HP Integrity servers
11.23 (11i v2),
11.31 (11i v3)
Java• HP 1.4.2.02 or later 1.4.x, 5.x and 6.x versions on PA 2.0 for HP-UX (HP 9000
Patches and updates
Processor and memory
Zero Preparation Data Collection:
If you are running the HP JDK/JRE 5.0.04 or later, you can send a signal to the running JVM to
start and stop an eprof profiling data collection period with zero preparation and no interruption
of your application. See Profiling with Zero Preparation (page 62).
If you are running the HP JDK/JRE 5.0.14 (or later) or the 6.0.02 version (or later), you can send
a signal to the running JVM to start and stop a verbose GC data collection period with zero
preparation and no interruption of your application. See Collecting GC Data with Zero Preparation
• HP 1.4.2.02 or later 1.4.x , 5.x , 6.x, and 7.x versions on HP-UX (HP Integrity)
11.23 (11i v2), 11.31 (11i v3)
HPjconfig canhelp you determine which Java patches are recommended or required
for best operation of the HPjmeter agent on HP-UX.
The agent is designed to be lightweight and low overhead, and does not require
any additionalprocessing power or memory beyond that requiredby the application
being monitored.
10 MBDisk space
These are the requirements for systems running the console.
Table 2-2 Console Requirements
Operating system and
architecture
14Completing Installation of HPjmeter
The console is a pure Java application, so it should execute on any platform that
supports Java.
Java 5.x, Java 6.x, and 7.x versions.Java
Table 2-2 Console Requirements (continued)
Patches and updates
Processor and memory• Minimum 500 MHz processor is recommended.
Completing the installation
After installation, the HPjmeter console is available as a standalone tool or through Java Web
Start from a server of your choice, such as the HP Systems Insight Manager central management
server.
To complete installation, you need to configure the HPjmeter JVM agent by modifying the
command line for each application for which you want to monitor or collect data. Then you need
to start the HPjmeter node agent. The following sections will help you complete the installation.
•Platform Support and System Requirements (page 14)
•File Locations (page 15)
•Configuring your Application to Use HPjmeter Command Line Options (page 15)
•Working with Firewalls (page 21)
•For additional information on agents: Managing Node Agents (page 37)
File Locations
HPjconfig canhelp you determine which Java patches are recommended or required
for best operation of the HPjmeter agent on HP-UX.
• Minimum 256 MB memory is required.
10 MBDisk space
The default installation paths by operating system are as follow:
•On HP-UX and Linux: /opt/hpjmeter
•On Microsoft® Windows: C:\Program Files\HPjmeter
Attaching to the JVM Agent of a Running Application
For applications running with Java 6.0.03 or later, HPjmeter 4.2.00.00 can automatically identify
the JVMs running on the server and display them symbolically in the console for attachment
and monitoring. This includes JVMs for which no HPjmeter switches were used in the java
command that started the applications. With few exceptions (discussed elsewhere in this guide),
HPjmeter monitoring functionality is the same whetherthe JVM agent is loaded from the console
(through dynamic attachment) or from the command line when starting the application.
Configuring your Application to Use HPjmeter Command Line Options
For most supported versions of Java, it is still necessary to start the application using HPjmeter
options on the java command and to modify two environment variables. Or, you may want to
use command line options to control the bytecode instrumentation.
Preparing to run Java
For most installations, linkage to the appropriate libraries is completed automatically as part of
the installation process. Go to step 2 if you have a standard installation of the Java Runtime
Environment.
Completing the installation15
To Take Advantage of Dynamic Attach:
Check that JM_JAVA_HOME in $JMETER_HOME/config/hpjmeter.conf is set to a Java 6
directory (6.0.03 or later) to be able to later dynamically attach to a running JVM from the HPjmeter
console without first setting HPjmeter options on the command line.
When HPjmeter is installed on a system that has Java 6 installed in the usual location, the
installation procedurewill automatically store the JDK location in hpjmeter.conf configuration
file. If the Java 6.x JDK is installed in a non-standard location, or Java 6.x is installed after HPjmeter
is installed, then it is necessary to update the hpjmeter.conf file manually. The typical contents
of the file are:
JM_JAVA_HOME=/opt/java6
1.The HPjmeter installation process will configure JDKs that are installed in the standard
location. Some systems have JDKs installed in nonstandard locations, and some applications
run with an embedded Java Runtime Environment. In these situations, it is necessary to
explicitly indicate the location of HPjmeter libraries.
Assuming that JMETER_HOME represents your installation directory, modify the shared
library path in your environment as follows:
•On HP-UX running on HP Precision Architecture systems, add
$JMETER_HOME/lib/$ARCH to SHLIB_PATH where $ARCH is PA_RISC2.0 or
PA_RISC2.0W.
•On HP-UX running on Itanium-based systems with Java 5.x or later, add
$JMETER_HOME/lib/$ARCH to LD_LIBRARY_PATH where $ARCH is IA64N or IA64W.
•On HP-UX running on Itanium-based systems, for JDK 1.4.x versions, use the
SHLIB_PATH environment variable to specify the shared library path.
2.On HP-UX and running Java 1.4.x, specify the Xbootclasspath in your java command:
NOTE:If you use the 64-bit version of the JVM (using the -d64 option), then you will need
to use the 64-bit version of the JVM agent. For example, type
$ java -d64 HelloWorld
when SHLIB_PATH is $JMETER_HOME/lib/$ARCH and
where $ARCH equals PA_RISC2.0W or IA64W.
See JVM Agent Options (page 17) for the list of available options and their descriptions.
Example Usage
•Using -agentlib on Java 5.x to run the JVM agent:
With the addition of JVMTI in JDK 5.0, you should use the -agentlib switch to take
advantage of improvements in JDK 5.0 and reduce the impact of data sampling on application
performance. While -Xrunjmeter can 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, -agentlib is 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 –V2
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.
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 Options17
Creates a colon-separated list of classes to specify which classes or packages are instrumented.
Method-level filtering is not supported.
•If a class is not instrumented, the JVM agent metrics that use bytecode instrumentation
(BCI) do not provide any output related to the class methods. To see the list of filters in
effect while the data was collected, including default agent filters, click theicon when
you see it in the console.
•Class filtering minimizes the overhead and focuses attention on user-produced code.
•By default, the JVM agent instruments bytecode of all loaded classes to implement some
of the metrics, except those classes that belong to one of these:
—Application servers, for performance reasons.
—HPjmeter management tools, in order to focus on user-created code.
—A set of implementation-dependent classes that HPjmeter cannot instrument. These
cannot be overridden.
•Some metrics display results for all classes regardless of filters, because class filters apply
only to those metrics that use bytecode instrumentation.
NOTE:JVM agent filters are distinct from console monitoring filters. For more
information, see Setting Monitoring Session Preferences (page 100).
JVM agent filters are configured when you start the JVM, and cannot be dynamically
changed.
Console filters are configured when you open a session with a JVM agent, and can be
changed from session to session. With HPjmeter 4.0 and later, these filters can also be
changed during a session.
If the JVM agent has filtered out a class, the console will be unable to see metrics from
that class even if you try to remove the console filter for the class.
This effect is similar to the previous example, except that the classes belonging to the
com.ibm.ws.io package, and its sub-packages if any, will be excluded from the
instrumentation. Otherclasses belonging to the com.ibm.ws package or its sub-packages
other than io will be instrumented. Classes belonging to sub-packages other than ws of
the com.ibm package will be still excluded by the default rule.
•In general, you can specify multiple package or class names with the include or exclude
option. The behavior with respect to any loaded class will be as defined by the most
specific rule (filter) that applies to the fully qualified class name.
•An include filter rule will override an exclude filter rule when the same package name
is provided on both options, even if one of the options is an implicit default. For example:
Sets a log level for the JVM agent, which allows you to collect varying amounts of information
about the node agent and JVM agent. Available log levels in order of impact on performance
are:
FINEST (Most impact on performance)
FINER
FINE
CONFIG
INFO
WARNING (Default setting)
SEVERE (Least impact on performance)
OFF (Turn off logging)
monitor_batch[:file=filename]
Enables all metrics and sends the collected data to a file. The default name for the file is
javapid.hpjmeter. Use the optional monitor_batch:file=your_file_name to
override the default.
•Once data has been collected and saved to a file on the managed node, you can view the
file from the console using the Open File button or using drag and drop. You may need
to copy the file to a file system visible from the console. For more information, see Saving
Configuring your Application to Use HPjmeter Command Line Options19
noalloc
Reduces dormant overhead by skipping bytecode instrumentation that applies to object
allocation metrics: Allocated Object Statistics by Class and Allocating Method Statistics. The
noalloc option makes those metrics unavailable.
Example usage: -agentlib:jmeter=noalloc
nohotspots
Reduces dormant overhead by skipping the bytecode instrumentation that supports Java
Method HotSpots. Any console connecting to an application initially started with this agent
flag does not enable Java Method HotSpots, and this metric is not listed in the Session
Preferences dialog.
Example usage: -agentlib:jmeter=nohotspots
noexception
Reduces dormant overhead by skipping bytecode instrumentation that applies to the Thrown
Exception metrics. Any console connecting to an application initially started with this attribute
does not enable Thrown Exception metrics, and these metrics are not listed in the Session
Preferences dialog.
Example usage: -agentlib:jmeter=noexception
nomemleak
Reduces dormant overhead by skipping bytecode instrumentation that applies to memory
leak location events. When you specify this option, the memory leak location alert is
unavailable in the console for the lifetime of this application.
Example usage: -agentlib:jmeter=nomemleak
noarrayleak
Reduces dormant overhead by skipping bytecode instrumentation that applies to array leak
location events. When you specify this option, the array leak location alert is unavailable in
the console for the lifetime of this application.
Example usage: -agentlib:jmeter=noarrayleak
owner_private
Specifies that the JVM is visible only to the node agents run with the same effective user ID;
that is, run by the same user as the one who runs the JVM. This limitation does not apply to
node agents run as root (the installation default).
•You can specify only one of the options owner_private, group_private, or public.
•Example usage: -agentlib:jmeter=owner_private
public
Specifies that the JVM is visible to all node agents run on the same host as the JVM.
•You can specify only one of the options owner_private, group_private, or public.
•Example usage: -agentlib:jmeter=public
verbose[:file=filename]
Prints information about the bytecode instrumentation rules in effect, such as include or
exclude settings, and about the individual instrumentation decisions made for all loaded
classes. By default, the information is printed on stdout. You can overridethis by specifying
a file name, for example verbose:file=bci.txt.
Example usage: -agentlib:jmeter=verbose
version
Displays the JVM agent version and quits immediately without running any Java applications
at all. You cannot use this option with any other options.
Securing Communication Between the HPjmeter Node Agent and the Console
IMPORTANT:The data stream between the HPjmeter console and agents is not protected from
tampering by a network attacker. You can help ensure that the data you view in HPjmeter
visualizers is an accurate reflection of your application's operation and that data confidentiality
is protected where needed.
Ensuring the Integrity of HPjmeter Console/Node Agent Data Transfer
For key applications in production, you may want increase your confidence that the data has
not been tampered with en route between the agents and console before you take action based
on HPjmeter metrics. Where you deem it necessary, confirm that the HPjmeter data looks
reasonable according to the usual behavior of your application. You can also pursue using secure
socket layer (SSL) tunneling to protect the integrity of data packets and to enhance the reliability
of the data reaching the HPjmeter console.
Want to Know More About Secure Socket Layer Tunneling?:
HP-UX IPSec and HP-UX Secure Shell are two HP products that provide secure socket layer
tunneling. To learn more:
•HP-UX IPSec technical documentation
•HP-UX Secure Shell overview and download
•HP-UX Secure Shell technical documentation
See also Connecting to the HPjmeter Node Agent (page 197).
Protecting Data Confidentiality During HPjmeter Console/Node Agent Communication
Data sent to the console is not encrypted by HPjmeter. If you are concerned about confidentiality
of this data, you can protect confidentiality by using SSL tunneling to encrypt the header and
data portion of each packet during transfer.
Working with Firewalls
NOTE:The console first attempts to use a port between 9505 and 9515 when arranging a port
for its server socket. If it is unable to successfully use a port from this range, it will use an ephemeral
port number.
The node agent has an open socket. Any HPjmeter console on any machine on the network (that
is not blocked by a firewall) can communicate with this node agent. If you want to have a console
contact a node agent through a firewall, you must provide a tunneling port so that the console
can contact the node agent.
Security Awareness21
IMPORTANT:If youchoose to open a port through a firewall to enable communication between
a node agent and a console, secure the tunneling port using HP-UX Secure Shell or HP-UX IPSec.
Configuring User Access
The node agent must be started by either the same user or group as the running JVM
(recommended) or root to establish contact.
IMPORTANT:Setting access for owner or group should not be considered a security solution
because node agent to JVM communications are not secured by default—see below.
Securing Communication Between the JVM and the HPjmeter Node Agent
IMPORTANT:The data stream between the JVM and the node agent is not protected from
tampering by a user loggedinto the system runningthe JVM. For keyapplications in production,
you may want to increase your confidence that the data has not been tampered with en route
between the JVM and agent before you take action based on HPjmeter metrics.
Where you deem it necessary, either secure the communication mechanism between the JVM
and node agent (HP-UX 11i v2 or later only), or confirm that the HPjmeter data looks reasonable
according to the usual behavior of your application by independently validating its output.
To secure the communication mechanism between the JVM and node agent on HP-UX 11i v2 or
later operating systems, set the umask of the JVM process to 77 (no access except for the owner)
by executing the command
% umask 77
before running the JVM.
Related Topics
•Managing Node Agents On HP-UX (page 37)
•Node Agent Access Restrictions (page 38)
•Connecting to the HPjmeter Node Agent (page 197)
22Completing Installation of HPjmeter
3 Getting Started
Are You Monitoring an Application or Analyzing Collected Data?
HPjmeter helps you to monitor a live run of your application. You can also view saved data
captured using HPjmeter during a live session, by using profiling or garbage collection options
when you start your application, or if you are running HP JDK/JRE 5.0.04 (or higher), by starting
and stopping profiling data collection from the command line.
Choose the get started information appropriate for your activity:
•Using HPjmeter to Monitor Applications (page 23)
•Using HPjmeter to Analyze Profiling Data (page 29)
•Using HPjmeter to Analyze Garbage Collection Data (page 31)
•Profiling with Zero Preparation (page 62)
Need a jumpstart?:
To aid in starting your use of HPjmeter, the console can display a beginning console guide
containing hints for getting started. The guide provides hints according to data set selected in
the console main pane.
To enable or disable the console guide, click Edit→ Window Preferences and toggle to the
desired option.
Using HPjmeter to Monitor Applications
The following sections summarize how to use HPjmeter to monitor applications. Detailed
descriptions of the behavior of HPjmeter are linked to from each section.
Configure and Start Your Application
1.Set the command line of your Java application to use the JVM agent and any desired agent
options.
2.Start your application with the JVM agent.
For details, see:
•Configuring your Application to Use HPjmeter Command Line Options (page 15)
•JVM Agent Options (page 17)
Confirm that the Node Agent is Running
With a standard installation, the node agent should be running on the systems where it was
installed.
For details about the node agent, see:
•Managing Node Agents On HP-UX (page 37)
Start the Console
Start the console from a local installation on your client workstation.
For starting instructions by platform, see Starting the Console.
Connect to the Node Agent from the Console
Procedure 3-2 Connection to Server (Default Mode)
To connect to a node agent:
Are You Monitoring an Application or Analyzing Collected Data?23
1.Choose Connect from the File menu or click Connect to server []
2.In the Connect to Server dialog box, type the complete host name (server.domain.com)
on which a Java application and a corresponding node agent are running.
3.Optionally, in the Optional Port box, specify the same port number that was used when the
node agent was started.
4.Click Connect.
After a few moments, the running JVM for each application identified should appear in the
console main window pane marked with one of the following symbols:
•— A JVM that has already loaded an HPjmeter JVM agent
•— A JVM that has not yet loaded an HPjmeter JVM agent
5.Repeat the previous steps if you want to connect to several node agents on several servers
at once.
Procedure 3-3 Secured Connection to Server
To connect to a node agent via a SecureShell (SSH) tunnel:
24Getting Started
1.Choose Connect from the File Menu or click Connect to server []
2.In the Connect to Server dialog box,type the complete host name (server.domain.com)
of the system that is the designated host for the SSH tunnel (the SSH delegate machine).
3.Optionally, in the Optional Port box, specify a port number through which information can
pass from the SSH delegate to the node agent.
4.Check the box labeled Use SSH Options.
The Connect to Server dialog expands to reveal required SSH attributes.
5.Type the IP address External IP) of the SSH delegate.
6.Type the port number (External Port) on the SSH delegate through which information can
pass from the SSH delegate machine to the console.
7.Type the port number (Internal Port) listened to on the console side that can accept
information from the SSH delegate machine.
8.Click Connect.
After a few moments, the running JVM for each application identified should appear in the
console main window pane marked with one of the following symbols:or.
Using HPjmeter to Monitor Applications25
9.Repeat the previous steps if you want to connect to several node agents.
Set Session Preferences
1.Double-click on the JVM icon in the data pane for the application that you want to monitor.
This opens the Session Preferences dialog box.
26Getting Started
NOTE:
When the Optional Port Box Is Not Used
The console automatically attempts to use a port on the remote system between 9505 and
9515 when arranging a port for its server socket. If it is unable to successfully use a port
from this range, it will use an ephemeral port number.
2.By clicking the tabs in this dialog, you can see the default settings for metrics, filters, and
alerts. Enable or disable the settings as desired.
Interdependencies Exist Among Some Metrics and Between Some Metrics and Alerts:
Some metrics are obtained together and do not display independently from one another.
When this occurs, checking one metric may activate others, as shown in the following image.
Using HPjmeter to Monitor Applications27
Some alerts require collection of specific metrics such that even if a metric is de-selected, it
may be activated by selection of a related alert.
3.Once all selections are made, click OK. The preferences window will close and the new Open
Session will be visible, marked by this icon:
Though it is possible to begin viewing application activity immediately in the monitoring
visualizers, you may want to wait for a short period of time before viewing some of the
metrics. The length of time needed to collect sufficient data depends on the application size,
the load imposed on the application, and on the selected preferences. Typically, a wait of 5
to 30 minutes provides sufficient data to begin seeing significant clues to the application
28Getting Started
behavior and performance. A longer collection time gives you greater accuracy in the results.
For details, see: Setting Monitoring Session Preferences (page 100) .
Changing Session Preferences During a Session
With HPjmeter 4.0 and later, it is possible to change session preferences during a session.
1.Double-click the “Open Session” line in the console for the session that you want to change.
The Session Preferences window opens.
2.Alternately, selecting the “Open Session” line on the console enables the Session Preferences
iconon the console tool bar. Click the icon to open the Session Preferences window.
View Monitoring Metrics During Your Open Session
1.Click on the open session or time slice to highlight the data that you would like to view.
2.Use the Monitor menu on the console main window to select the metrics that you want to
see. Mousing over each category in the cascading menu will reveal the relevant metrics for
that category.
3.Click a metric to open a metric visualizer displaying the chosen data.
For details on individual metrics and how to interpret the data display, see:
•Using Monitoring Displays (page 117)
•Monitoring Applications (page 36)
See also:
•Saving Monitoring Metrics Information (page 38)
•Using Visualizer Functions (page 116)
Using HPjmeter to Analyze Profiling Data
The following steps summarize how to use HPjmeter to view profiling information from your
applications.
Using HPjmeter to Analyze Profiling Data29
NOTE:If you are running the HP JDK/JRE 5.0.04 or later, you can send a signal to the running
JVM to start and stop a profiling data collection period with zero preparation and no interruptionof your application. See Profiling with Zero Preparation (page 62).
1.Configure your application.
Change the command line of your Java application to collect the desired type of data: -Xeprof
to collect execution profiling information, -agentlib:hprof to generate heap dump at program
exit, or -XX:+HeapDump to enable generation of heap dumps using the SIGQUIT signal.
There are additional heap dump options. For more details, see the Java™ Troubleshooting
Guide for HP-UX Systems .
2.Run the application to create a data file.
3.Start the console from a local installation on your client workstation.
4.Click File→Open File to browse for and open the data file, or drag and drop the file onto
the console.
5.For all profiling data types, a viewer window opens and displays a set of tabs containing
summary and graphical metric data. You will also see the Metrics and Estimate menus
containing additional metric display choices, and a control menu for changingthread scope.
30Getting Started
Loading...
+ 184 hidden pages
You need points to download manuals.
1 point = 1 manual.
You can buy points or you can get point for every manual you upload.