How to Monitor and Analyze Linux System Performance - Nmon Tool

To Monitor and Analyze Linux System Performance by using Nmon Tool

The command Nmon is stands for Nigel’ s Monitor and it is a command-line tool used to monitor various system performance of the linux. Nmon has lots of options for monitoring different aspects of the system like system information, CPU status ,memory status ,disk information ,etc..This tutorial explains the installation of nmon tool.

Installing Nmon in CentOS 6

Use yum command to install nmon in CentOS 6.

[root@linuxhelp Desktop]# yum install nmon
Loaded plugins: aliases, changelog, fastestmirror, kabi, presto, refresh-packagekit,
              : security, tmprepo, verify, versionlock
Loading support for CentOS kernel ABI
Setting up Install Process
Loading mirror speeds from cached hostfile
 * base: centos.excellmedia.net
 * epel: mirrors.vinahost.vn
 * extras: centos.excellmedia.net
 * updates: centos.excellmedia.net
Resolving Dependencies
-->  Running transaction check
--->  Package nmon.x86_64 0:14i-8.el6 will be installed
-->  Finished Dependency Resolution

Dependencies Resolved

==========================================================================================
 Package            Arch                 Version                 Repository          Size
==========================================================================================
Installing:
 nmon               x86_64               14i-8.el6               epel                54 k

Transaction Summary
==========================================================================================
Install       1 Package(s)

Total download size: 54 k
Installed size: 120 k
Is this ok [y/N]: n
.
.
.
.
.
Running Transaction
  Installing : nmon-14i-8.el6.x86_64                                                  1/1
  Verifying  : nmon-14i-8.el6.x86_64                                                  1/1

Installed:
  nmon.x86_64 0:14i-8.el6                                                                 

Complete!

Now the installation has completed. After the installation of nmon package let see how to use the nmon tool in command-line. Now am going to open the nmon tool by using nmon command.

[root@linuxhelp Desktop]# nmon

The following options to show the performance status information on other system resources present in your system.

If you want to view the CPU performance press c option in the nmon terminal.

To get statistics on top processes that are running on your machine press the key ‘ t‘ and wait for the information to be displayed.

This option is similar to your top process if you have doubt means run top command and check the information.

To Check the Network Statistics information press ‘ n‘ now see the network status information.

To check disk I/O static information use ‘ d‘ key to get information on disks.

To check the Kernel Information press ‘ k‘ with this tool to display brief information about kernel of your system.

To check System Information in brief press ‘ r’ now it shows the information on different resources such as machine architecture, operating system version, Linux version and CPU.

To check the Checking File System Statistics by pressing the key ‘ j‘ on your keyboard.

To display the virtual memory statics by pressing option V.

To check the memory statistics information press option m.

To check the long term information about your CPU using option l.

If you want to display the default performance while using nmon command you should follow the below command.

[root@linuxhelp Desktop]# export NMON=mcdn

Using export command it will display what options are you entered that only displays by default. In the above command i have entered m,c,d,n stands for,
m memory
c CPU
d disk statics
n network statistics

You can choose any options available in nmon to display as default.

Now type nmon command it will display default process information.

[root@linuxhelp Desktop]# nmon

Tag : nmon
FAQ
Q
How to install "nmon" tool on Linux?
A
Use the following steps to install "nmon" on Linux. For syntax: In Ubuntu "apt-get install nmon"
In CentOS "yum install nmon"
Q
Can you give me the list of manipulation key to getting information of the system using the "nmon" tool in Linux?
A
Here I have to give the list of some manipulation keys. Such as,
1. m = Memory
2. j = Filesystems
3. d = Disks
4. n = Network
4. V = Virtual Memory
5. r = Resource
6. N = NFS
7. k = kernel
8. t = Top-processes
9. "." = only busy disks/procs
Q
How can I check the file system in Linux using the "nmon" tool?
A
You can press "j" while intermediate with "nmon" tool console, to check the file system in Linux using the "nmon" tool.
Q
How to check the version of the "nmon" tool has been installed on the system?
A
You can use the option of "-V" with "nmon" command to check the version of the "nmon" tool has been installed on the system. For syntax: "nmon -V".
Q
Whether there is any alternative tool is available for windows like "nmon"?
A
Yes, you can prefer the following application for "Windows" like "nmon" tool. Such as,

1. Glances

2. Resource Monitor

3. psutil

4. Kiwi application monitor