To capture resource monitoring
data from Apache Tomcat, you must configure the data source.
Before you begin
The Java™ Management
Extensions must be configured on the server that is running Apache
Tomcat. After installing Apache Tomcat on Microsoft Windows,
run the Configure Tomcat shortcut. Click the Java tab,
and then edit the Java Options. Following are
sample Java options:
-Dcom.sun.management.jmxremote
-Dcom.sun.management.jmxremote.port=8880
-Dcom.sun.management.jmxremote.ssl=false
-Dcom.sun.management.jmxremote.authenticate=false
On Linux, set the environment variable
CATALINA_OPTS in
either
TOMCAT_HOME/bin/setenv.sh or
TOMCAT_HOME/bin/catalina.sh file.
For example,
export CATALINA_OPTS="-Dcom.sun.management.jmxremote=true
-Dcom.sun.management.jmxremote.port=8686
-Dcom.sun.management.jmxremote.ssl=false
-Dcom.sun.management.jmxremote.authenticate=false
-Djava.rmi.server.hostname=your.server.domain.com"
Then, restart Apache Tomcat.
Procedure
- On the Location page, specify the
connection and authentication information for the server that runs
Apache Tomcat. If you need to change the port that is used to communicate
with the server, change the information in Connection.
Typically, your Tomcat system administrator specifies this information.
The port number must match the port that you specified when configuring Java Management Extensions on the
server.
- If administrative security is enabled on the server, select Administrative
security enabled.
- Type the user ID and password for Apache Tomcat in Authentication.
- Select Save Password to save
your password locally. If you do not save your password, you might
be prompted for it (depending on the host system configuration) when
you edit the configured location or when you run test schedules that
use the location.
- On the Resource page, select the type
of data to capture. The tree view shows the counter groups and counters
that are available from the application server. Be selective; monitoring
all possible resource data requires substantial amounts of memory.
Hold your mouse pointer over a counter to see details about what that
counter measures.
- Configure the options on the Options page.
- In Polling Interval specify in
seconds the interval for collecting resource data. For example, if
you accept the default of 5 seconds, counter information is collected
at 5-second intervals from the specified host during the schedule
run.
- In Timeout Interval specify in
seconds the time to wait for a response. If the resource monitoring
host does not respond within this amount of time during a schedule
run, an error is logged.
- To collect the resource monitoring data for the system under test that is in the cloud, in the
Cloud Options tab, click the Location in Public Cloud
check box.
- Click Next.
- Specify a location and name and click Finish.