Tools Used for Performance Monitoring

on August 31, 2009

HP-UX has a number of tools that are bundled with the operating system. Additional sophisticated. Tools can be purchased separately. The bundled tools usually work in text mode. Some of these utilities are listed here.

The iostat command is used to monitor I/O activity for disk drives.

# iostat

device bps sps msps
c0t6d0 105 10.8 1.0
c0t5d0 0 0.0 1.0

device
Shows the actual disk device for which the report is given.
bps Shows kilobytes transferred per second to/from the device.
sps Lists the number of seeks per second.
msps The time in milliseconds per average seek.

The vmstat command is used to monitor activity of virtual memory.

Virtual memory statistics are displayed using the vmstat command. It displays information about processes, page faults, memory, and CPU as shown here. (The output is formatted to fit onto the page.)

# vmstat -n


VM

memory page faults
avm free re at pi po fr de sr in sy cs
2275 44047 2 0 0 0 1 0 0 106 88 33
CPU
cpu procs
us sy id r b w
0 0 99 0 0 0

The -n option is used with the command to improve the format of the output.

avm
Active virtual memory. These are the pages that have been assigned to some processes.
free Free pages. A number of columns are present under the page subheading.

re
Page reclaims. A large number shows a memory shortage.
at Address translation faults.
pi Pages paged in.
po Pages paged out.
fr Pages freed per second.
de Anticipated short term memory shortfall.
sr Pages scanned by clock algorithm, per second.
The faults subheading shows trap and interrupt rate averages per second over the least 5 seconds.

in
Device interrupts per second.
sy System calls per second.
cs CPU context switch rate.
The CPU part of the output has been divided into two subparts, cpu and procs. The columns under the cpu subheading show CPU utilization.

us
User time for normal and low-priority processes.
sy System time.
id CPU idle time.
An explanation of the different fields under the procs subheading is as given here.

r
The process is in run queue.
b Number of processes blocked for some resource.
w It shows runable but swapped out from the main memory.

The netstat and lanadmin commands are used to monitor network activity such as incoming and outgoing network traffic, use of protocols, IP addresses assigned to interface adapters.

The top utility is used to monitor processes that are utilizing more CPU time. Processes are listed in a sorted form. Percentage of CPU idle time is also displayed. This utility also shows some
information about real and virtual memory.

#top -s1


System: apmbdb01 Mon Aug 31 22:23:21 2009
Load averages: 0.13, 0.17, 0.23
206 processes: 184 sleeping, 21 running, 1 zombie
Cpu states:
CPU LOAD USER NICE SYS IDLE BLOCK SWAIT INTR SSYS
0 0.10 2.0% 0.0% 3.2% 94.8% 0.0% 0.0% 0.0% 0.0%
1 0.15 9.2% 0.0% 9.6% 81.2% 0.0% 0.0% 0.0% 0.0%
--- ---- ----- ----- ----- ----- ----- ----- ----- -----
avg 0.13 5.6% 0.0% 6.4% 88.0% 0.0% 0.0% 0.0% 0.0%

Memory: 4406476K (2952932K) real, 4761636K (3231796K) virtual, 1736900K free Page# 1/18

CPU TTY PID USERNAME PRI NI SIZE RES STATE TIME %WCPU %CPU COMMAND
1 ? 4296 oracle 148 20 3418M 23828K sleep 0:17 10.40 10.38 oracleAPMBPROD
1 ? 5238 root 154 20 11980K 1408K sleep 0:24 9.23 9.22 bma
0 ? 5237 root 154 20 14032K 1752K sleep 0:04 2.14 2.13 bma
1 ? 4286 oracle 154 20 105M 37992K sleep 0:06 1.16 1.16 rman
1 ? 52 root 152 20 3744K 3328K run 13:25 0.61 0.61 vxfsd
1 ? 1409 root 152 20 174M 67656K run 3:57 0.30 0.30 cimserver
1 ? 12683 root -27 20 47412K 39592K run 16:44 0.29 0.29 cmcld
0 ? 1782 root 152 20 112M 17004K run 0:59 0.14 0.14 vxsvc
0 ? 5318 oracle 154 20 3445M 52140K sleep 0:00 0.17 0.13 ora_lns2_APMBPROD
0 ? 453 root 152 20 8068K 2832K run 1:05 0.12 0.12 utmpd
0 ? 1402 root 152 20 25416K 5548K run 0:06 0.12 0.12 rpcd

A brief explanation of the columns in the process area is given below.
CPU This is the first column, which is not shown in Figure 25-1. It is present on systems with multiple

CPU
s. This represents a CPU number on which the process is being executed.
TTY The terminal used by the process.
PID Process ID.
USERNAME Name of the owner of the process.
PRI Process priority.
NI Nice value.
SIZE Total size of the process in memory.
RES Resident size of the process. This is an approximation.
STATE Current state of the process.
TIME CPU time consumed by the process.
%WCPU Weighted CPU percentage utilization by the process.
%CPU Raw CPU percentage utilization by the process.
COMMAND Name of the command that started the process.

The System Activity Reporter (sar) shows a number of kernel parameters and CPU utilization.

# sar -u 1 5


HP-UX hp0 B.11.00 A 9000/839 11/29/99
12:27:53 %usr %sys %wio %idle
12:27:54 1 1 0 98
12:27:55 0 0 0 100
12:27:56 0 0 0 100
12:27:57 0 0 0 100
12:27:58 0 0 0 100

Average 0 0 0 100

#sar -Mu 2 10
#sar -d 2 10
#sar -v 2 10
#sar -b 2 10
#sar -u 2 10
#sar -w 2 10
#vmstat 2 10
#iostat 2 10


b Monitor buffer cache
-d Monitor disk activity
-q Monitor queue length
-u Monitor CPU activity
-w Monitor swap space activity
-o Save data into a file
-f Read previously saved data from a file

1 Post a Comment:

shiva said...

Good One,
Mr.Professional


http://www.blogcatalog.com/directory/technology/computers/