Monitoring WebSphere Application Performance


So far within this chapter, you've explored some system and environment performance measurements. In previous chapters, I discussed in detail how to tune and optimize the core WebSphere product and deployed applications. What I haven't yet discussed is how you monitor and track WebSphere performance and fix performance problems. In Chapters 6 and 14, I discuss profiling and benchmarking.

Let's first ponder for a moment what I'm talking about when I say performance problems . As touched on during Chapters 1 and 2, performance is typically associated with fast application response times. Consider also that, at the most basic level, a performance issue will be caused by insufficient resources for a task. Although these insufficiencies may be caused by poorly written code that's suffocating system resources, the symptom is still a resource constraint.

Table 13-4 gives you an overview of some of the more common symptoms for poor performance within a WebSphere server. Following Table 13-4, you'll see how to understand and determine if these symptoms are occurring.

Table 13-4: Common Symptoms for Poor WebSphere Server Performance

Symptom

High-Level Possible Cause

High CPU utilization

Overutilization of objects, poorly written code, or high network or I/O activity.

High disk I/O utilization

Overuse of log files, lack of memory driving swap usage higher, persistence of objects to disk (serialization), or poor disk design.

High network utilization

Overuse of remote method invocations, undercapacity network topology, poorly designed data architecture (in other words, data and information transferred between multiple nodes could be broken down into more succinct packages).

You'll now take a closer look at some of these causes and symptoms and how to identify them. The next section lists some characteristics of poor performance, followed by what the possible causes may be, and then offers pointers to understand how to determine the root cause.

This list of performance problems isn't exhaustive. The problems are provided to give an example of common performance problems within WebSphere environments and encapsulate much of what I've discussed throughout the book. It also should help to summarize what tools to use to determine the possible root causes of the various issues.

High CPU Utilization of JVM

You've explored throughout the book a wide range of ways to decrease JVM overutilization of the CPU. However, in this section, you'll explore a number of "what if" scenarios, and I'll attempt to explain what to look for when there's a CPU overutilization problem, including what may be the cause.

Noticing whether a CPU is being heavily utilized is straightforward. You explored this earlier in this chapter. However, why would a JVM cause a CPU to be heavily used? There are many alternatives and possibilities. Table 13-5 describes some possible causes of high CPU use and lists several steps to explain how to determine the cause.

Table 13-5: High CPU Utilization: Cause and Effect

Effect

Possible Cause

Determination Path

Overuse of objects

Excessive object instantiation or poorly written code not closing object handles.

Resource Analyzer/Tivoli Performance tool, method and class invocation and usage rate, or Java profiler.

High usage of block I/O

CPU needs to manage I/O interrupts while they're called. If load of these requests is high, CPU usage will increase.

Check for block I/O requests through disk I/O activity and network I/O activity using system performance tools (see earlier sections).

Excessive garbage collection

Memory leaks caused by not dereferencing objects in memory.

Use the Resource Analyzer/Tivoli Performance console to monitor memory usage within JVM and garbage collection counters. Another option is to use verbose garbage collection and track the output in the standard out log file. You can graph all these outputs to model the frequency and duration of garbage collection.

Poor Database Transactional Performance

As discussed, your database is often a key component to your overall application environment in terms of performance. Several key components affect and make up a transaction within the database tier . These include areas such as Java Database Connectivity (JDBC) drivers, the database itself, the network, and the pool manager.

You'll now look at some possible causes, effects, and resolution paths for these problems. Table 13-6 gives an overview of database transactional performance.

Table 13-6: Poor Database Transactional Performance: Cause and Effect

Effect

Possible Cause

Determination Path

Poorly performing transactions

SQL code and JDBC configured incorrectly implemented

Use database vendor monitoring tools to determine if there are poorly written SQL statements or queries.

Poorly performing database

Misuse or nonuse of indexes, overly utilized CPUs, database server is swapping into swap or virtual memory, saturated network, or overly utilized disk subsystem

Use system monitoring tools discussed earlier in this chapter to track down the performance bottleneck.

Poorly performing persistence layer

CMP or BMP for high write environments, nonuse or poor implementation of Data Access Object (DAO) persistence layer.

Use database monitoring tools to monitor specific offending queries and database load, and use Resource Analyzer/Tivoli Performance management console to investigate database pool usage and utilization.

Poor Network Performance

The network is possibly the next most important aspect of your WebSphere environment. You can have ten high-end machines running your WebSphere cluster, but if they're connected or interconnected via a low capacity or poorly designed network infrastructure, then your overall application environment will run poorly.

You'll now look at two key areas of your environment that can be affected by network performance issues. Networking performance issues are fairly black and white ”the network is either performing or it's not; if it's not, it's either insufficient or has overloaded bandwidth.

Table 13-7 addresses two key areas of network performance with some possible methods to help identify where the problems are. Again, these are only examples, and they don't cover all aspects of network performance.

Table 13-7: Poor Network Performance: Cause and Effect

Effect

Possible Cause

Determination Path

Poor performance between tiers

Insufficient or overloaded bandwidth

Use system monitoring tools as discussed earlier in this chapter (for example, netstat and Windows Performance tool).

Poor performance between distributed components (for example, Enterprise JavaBeans)

Insufficient or overloaded bandwidth, or serialization of large amounts of Remote Method Invocation (RMI) encapsulated data

Use Resource Analyzer/Tivoli Performance management consoles to understand the time taken for your various methods and classes to run and return results.




Maximizing Performance and Scalability with IBM WebSphere
Maximizing Performance and Scalability with IBM WebSphere
ISBN: 1590591305
EAN: 2147483647
Year: 2003
Pages: 111
Authors: Adam G. Neat

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net