AIX, Monitoring, System Admin↑ NMON recordings

One can set up NMON recordings from smit via:

# smitty topas -> Start New Recording -> Start local recording -> nmon

However, the smit panel doesn't list the option needed to get disk IO service times. Specifically, the -d option to collect disk IO service and wait times. Thus, it's better to use the command line with the nmon command to collect and report these statistics. Here's one set of options for collecting the data:

# nmon -AdfKLMNOPVY^ -w 4 -s 300 -c 288 -m /var/adm/nmon

The key options here include:

  • -d Collect and report IO service time and wait time statistics.
  • -f Specifies that the output is in spreadsheet format. By default, the command takes 288 snapshots of system data with an interval of 300 seconds between each snapshot. The name of the output file is in the format of hostname_YYMMDD_HHMM.nmon.
  • -O Includes the Shared Ethernet adapter (SEA) VIOS sections in the recording file.
  • -V Includes the disk volume group section.
  • -^ Includes the FC adapter section (which also measures NPIV traffic on VIOS FC adapters).
  • -s Specifies the interval in seconds between 2 consecutive recording snapshots.
  • -c Specifies the number snapshots that must be taken by the command.

Running nmon using this command will ensure it runs for a full day. And it is therefore useful to start nmon daily using a crontab entry in the root crontab file. For example, using the following script:

# cat /usr/local/collect_nmon.ksh
#!/bin/ksh

LOGDIR="/var/adm/nmon"
PARAMS="-fTNAdKLMOPVY^ -w 4 -s 300 -c 288 -m $LOGDIR"

# LOGRET determines the number of days to retain nmon logs.
LOGRET=365

# Create the nmon folder.
if [ ! -d /var/adm/nmon ] ; then
        mkdir -p $LOGDIR
fi

# Compress previous daily log.
find $LOGDIR -name *.nmon -type f -mtime +1 -exec gzip '{}' \;

# Clean up old logs.
find $LOGDIR -name *nmon.gz -type f -mtime +$LOGRET -exec rm '{}' \;

# Start nmon.
/usr/bin/nmon $PARAMS

Then add the following crontab entry to the root crontab file:

0 0 * * * /usr/local/collect_nmon.ksh >/tmp/collect_nmon.ksh.log 2>&1

To get the recordings thru the NMON Analyser tool (a spreadsheet tool that runs on PCs and generates performance graphs, other output, and is available here), it's recommended to keep the number of intervals less than 300.

0 (0)
Article Rating (No Votes)
Rate this article
Attachments
There are no attachments for this article.
Comments
There are no comments for this article. Be the first to post a comment.
Full Name
Email Address
Security Code Security Code
Related Articles RSS Feed
AIX How to Investigate a System Reboot
Viewed 6866 times since Tue, Aug 14, 2018
SSH Essentials: Working with SSH Servers, Clients, and Keys
Viewed 4571 times since Wed, Jun 27, 2018
IBM AIX multipath I/O (MPIO) resiliency and problem determination
Viewed 13830 times since Wed, May 30, 2018
Unlock User ID in IBM AIX
Viewed 15510 times since Mon, May 28, 2018
Part 1, Memory overview and tuning memory parameters AIX7
Viewed 4419 times since Wed, Jun 19, 2019
How to Backup and Upgrade a Virtual I/O Server Part I
Viewed 4754 times since Wed, Jun 5, 2019
AIX, Storage, System Admin Allocating shared storage to VIOS clients
Viewed 2455 times since Fri, Apr 19, 2019
SSH-COPY-ID on AIX. SSH remote AIX’s box without password
Viewed 17478 times since Thu, Feb 21, 2019
AIX Booting
Viewed 10544 times since Tue, Apr 16, 2019
My LPAR always boots into SMS. Why?
Viewed 3930 times since Tue, Apr 16, 2019