Nmon

{{Short description|System monitor tool for the AIX and Linux operating systems}}

{{Lowercase title}}

{{Infobox Software

| name = nmon

| logo =

| caption = nmon showing CPU, memory, and disk read and write

| screenshot = Nmon 16m-2 screenshot.png

| screenshot size = 250px

| author = Nigel Griffiths

| developer = IBM

| latest release version = {{wikidata|property|preferred|references|edit|P348|P548=Q2804309}} | latest release date = {{Start date and age|{{wikidata|qualifier|preferred|single|P348|P548=Q2804309|P577}}|df=yes}}

| operating_system = AIX, Linux

| genre = System monitor

| license = GNU GPL (Linux),

Proprietary software (AIX)

| website = {{Official URL}}

}}

nmon (Nigel's Monitor{{Cite web |last=Layton |first=Jeff |title=Monitoring with Nmon » ADMIN Magazine |url=http://www.admin-magazine.com/HPC/Articles/Nmon-All-Purpose-Admin-Tool |access-date=September 10, 2017 |website=ADMIN Magazine |language=en-US}}) is a computer performance system monitor tool for the AIX and Linux operating systems.{{Cite web|last=Wallen|first=Jack|date=2017-03-14|title=How to monitor your Linux servers with nmon|url=https://www.techrepublic.com/article/how-to-monitor-your-linux-servers-with-nmon/|archive-url=|archive-date=|access-date=2020-12-07|website=TechRepublic|language=en}}{{Cite web|last=Terpollari|first=Oltjano|title=Nmon: Analyze and Monitor Linux System Performance|url=https://www.tecmint.com/nmon-analyze-and-monitor-linux-system-performance/|access-date=2020-12-07|website=www.tecmint.com|language=en-US}} The nmon tool has two modes a) displays the performance stats on-screen in a condensed format or b) the same stats are saved to a comma-separated values (CSV) data file for later graphing and analysis to aid the understanding of computer resource use, tuning options and bottlenecks.

nmon for Linux is open source and available under GNU General Public License while the nmon for AIX is a proprietary software integrated into AIX.

Description

nmon collects the following operating system statistics:

  • CPU and CPU threads Utilisation
  • CPU frequency for servers or virtual machines that can alter their clock rate
  • GPU stats including utilisation, MHz and temperatures
  • Physical and Virtual Memory use
  • Disk read & write and transfers plus service time and wait times
  • Disk Groups - decided by the user
  • Swap and Paging
  • Network read & write and transfers
  • Local File-systems
  • Network File-system (NFS)
  • Top Processes by CPU use, Memory size and I/O rates
  • Kernel stats including Run Queue, context-switch, fork, Load Average & Uptime
  • Large and Huge memory pages
  • Virtual Machine stats (depending on the hardware) — useful for Linux running KVM to host virtual machines
  • Resources in the Server and virtual machine
  • nmon -h lists the details
  • To start collecting the stats to a file use the -f or -F option

When viewing in on-screen mode the stats displayed are controlled by the user using single letter toggles. For example, "c" to show CPU and then another "c" will switch the CPU stats off. Use h to display a list of the options.

When saving the stats to a file, there is a common default set of stats and then users can request more using command line options. Use nmon -? to display all the options.

The output file can be analyzed with nmon_analyzer.{{Cite web |last=Griffiths |first=Nigel |date=2020-01-13 |title=nmon_analyser: A free tool for producing AIX performance reports |url=https://developer.ibm.com/articles/au-nmon_analyser/?mhsrc=ibmsearch_a&mhq=nmonanalyser |archive-url= |website=developer.ibm.com}}

History

The original nmon version was for the IBM AIX operating system (Release 4.3 and above) and was freely downloadable binary format only tool from the IBM AIX wiki.{{Cite web |last=Griffiths |first=Nigel |date=February 27, 2006 |title=IBM Developer |url=https://developer.ibm.com/components/aix/ |url-status=deviated |archive-url=https://web.archive.org/web/20150128113454/http://www.ibm.com/developerworks/aix/library/au-analyze_aix/ |archive-date=January 28, 2015 |access-date=January 24, 2015 |website=IBM developerWorks}}

  • Later a version was written for the Linux operating system running on IA-32, x86, x86_64, IBM RS/6000 and POWER processors, Mainframe and ARM (including Raspberry Pi). nmon for Linux was released by IBM as open-source in July 2009. The code is available from the Sourceforge open source repository.{{Cite web |title=nmon for Linux {{!}} Main / HomePage |url=https://nmon.sourceforge.net/pmwiki.php |access-date=January 24, 2015 |website=nmon.sourceforge.net}}
  • The nmon for AIX code was later bundled in as part of the AIX operating systems. From AIX 5.3 TL09 and AIX 6.1 TL02 onward it was included in the default installation of AIX and fully supported by IBM. The nmon command{{Cite web |title=nmon Command |url=http://www-01.ibm.com/support/knowledgecenter/ssw_aix_61/com.ibm.aix.cmds4/nmon.htm |url-status=deviated |archive-url=https://web.archive.org/web/20141011214631/http://www-01.ibm.com/support/knowledgecenter/ssw_aix_61/com.ibm.aix.cmds4/nmon.htm |archive-date=October 11, 2014 |access-date=January 24, 2015}} and the topas command{{Cite web |title=Commands Reference, Volume 5, s - u |url=http://public.dhe.ibm.com/systems/power/docs/aix/53/aixcmds5.pdf |website=IBM |page=386}} are the same binary but behave differently depending on the command name used.

The two editions (AIX and Linux) have completely different source code but offer many similar features, command line options and data — as much as the underlying operating system allow.

Features

  • There are two runtime modes available:
  1. In Online Mode it uses curses for efficient screen handling, which updates the terminal frequently for real-time monitoring.
  2. In Capture Mode, the data is saved to a file in CSV format for later processing and graphing. The file also includes important configuration details that are useful for recommending tuning.
  • nmon concentrates on performance information for the performance tuner and in a concise layout to aid understanding. This includes CPU, memory, disks, adapters, networks, NFS, Kernel statistics, File-systems, Workload Manager (AIX), Workload Partitions (AIX) and Top Processes.
  • nmon includes support for older AIX releases, Linux running on x86, POWER and Mainframe platforms and other Linux supporting hardware.

Screenshots

File:Nmon 16m-2 CPU and memory screenshot.png|CPU Utilisation and Memory statistics

File:Nmon 16m-2 resources and load average screenshot.png|Resources and Kernel/load average statistics

File:Nmon 16m-2 top screenshot.png|top Processes sorted by CPU used

Alternatives

On AIX, there is the topas command that can output reports to a file but this is not in a format that can be used easily as a source for a spreadsheet or web tools like RRDtool.

On Linux, there is the top command which is good for CPU and processes but does not cover disks and networks. For disk I/O, the iostat command can give you the details and ntop for network information. But neither of these commands allow saving data in a format suitable for a spreadsheet or simple further processing. Linux utility dstat can be used to produce text data, even in comma separated value format, which is quite suitable for spreadsheet programs.

References

{{Reflist}}