Home » Categories » Check Library

Network Interface Checks

Network Interface Checks

These checks are for the network interface cards (NIC) on the remote computer. Depending on your Operating System (OS) the NIC will be named differently, here are some examples:

  • CentOS 6 = eth0
  • CentOS 7 = ens32
  • Windows = Ethernet0

 

Nagios Plugins

Nagios Plugins does not provide NIC checking capabilities.

NCPA

NPCA includes an interfaces module. There are several check types available depending on what you want to monitor. The interface metrics are an increasing number, hence the delta -d argument is used to get the change in value (in seconds) over time since the last check result, producing useful performance graph data.

Bytes Sent / Bytes Received

Unit: k
Warning: 10kB/s
Critical: 100kB/s

Commands:

./check_ncpa.py -H 10.25.14.10 -t 'Str0ngT0k3n' -P 5693 -M 'interface/Ethernet0/bytes_sent' -d -u k -w 10 -c 100
./check_ncpa.py -H 10.25.14.10 -t 'Str0ngT0k3n' -P 5693 -M 'interface/Ethernet0/bytes_recv' -d -u k -w 10 -c 100

Output:

OK: Bytes_sent was 0.26 kB/s | 'bytes_sent'=0.26;10;100;
OK: Bytes_recv was 1.46 kB/s | 'bytes_recv'=1.46;10;100;

 

The following nodes are also available:

  • packets_sent / packets_recv
  • dropin / dropout
  • errin / errout

NSClient++ via check_nt

NSClient++ via check_nt does not include a NIC module.

An alternative method is to query a performance counter, for example:

\Network Interface(Intel[R] PRO_1000 MT Network Connection)\Bytes Received/Sec

More information about performance counters can be found in the Performance Counter Checks KB article.

NSClient++ via check_nrpe

NSClient++ via check_nrpe includes a check_network module however it doesn't seem to report any data, it's likely this module is still in a development stage (tested with 0.5.2.20). An example command has been provided:

Command:

./check_nrpe -H 10.25.14.2 -c check_network

Output:

: Intel(R) PRO/1000 MT Network Connection >0 <0 bps|'Intel(R) PRO/1000 MT Network Connection_total'=0;10000;100000

 

An alternative method is to query a performance counter, for example:

\Network Interface(Intel[R] PRO_1000 MT Network Connection)\Bytes Received/Sec

More information about performance counters can be found in the Performance Counter Checks KB article.

WMI

Check WMI Plus includes a checknetwork module and produces a lot of output.

Bytes Sent / Bytes Received

Unit: Bytes
Warning: 10000B/s
Critical: 100000B/s

Commands:

./check_wmi_plus.pl -H 10.25.14.10 -u wmiagent -p Str0ngP@ssw0rd -m checknetwork -a 'Ethernet0' -w _BytesSentPersec=10000 -w _BytesReceivedPersec=10000 -c _BytesSentPersec=100000 -c _BytesReceivedPersec=100000

Output:

OK (Sample Period 262 sec) - Number of Interfaces=1. Interface Details - OK - Interface:Ethernet0, IP Address:(10.25.14.10,fe80::88ae:6647:7d3c:da4c,2001:44b8:3132:25:10cc:fe71:bc9b:1b3e,2001:44b8:3132:25:88ae:6647:7d3c:da4c,
2001:44b8:3132:25:10:25:254:f440,2001:44b8:3132:25:10:25:14:10), MAC Address 00:50:56:AB:AD:9D, Speed:1Gbit/s, DHCPEnabled=False, Byte Send Rate=295B/sec (Utilisation=0.00%), Byte Receive Rate=1.718KB/sec(Utilisation=0.00%)
Packet Send Rate=1packet/sec, Packet Receive Rate=9packet/sec, Output Queue Length=0, Packets Received Errors=0 |'Ethernet0 BytesSentPersec'=295;10000;100000; 'Ethernet0 Send Utilisation'=0.00%;
'Ethernet0 BytesReceivedPersec'=1718;10000;100000; 'Ethernet0 Receive Utilisation'=0.00%; 'Ethernet0 PacketsSentPersec'=1; 'Ethernet0 PacketsReceivedPersec'=9; 'Ethernet0 OutputQueueLength'=0; 'Ethernet0 PacketsReceivedErrors'=0;

 

If your Windows OS is older than Server 2012 or Windows 8 then you may require the -o legacy argument.

The following thresholds are also available:

  • CurrentBandwidth
  • _PacketsSentPersec / _PacketsReceivedPersec
  • OutputQueueLength
  • PacketsReceivedErrors
  • _SendBytesUtilisation / _ReceiveBytesUtilisation

SNMP

Monitoring NICs using SNMP can be done using MRTG. It is a powerful program and you should refer to the official website on how to get it up and running:

https://oss.oetiker.ch/mrtg/

If you are using Nagios XI then you simply run the Network Switch / Router configuration wizard. This uses MRTG in the backend and the wizard does all the configuring for you. Even though the name of the wizard says switch / router it can be used against any OS that has SNMP enabled.

 

 

Final Thoughts

For any support related questions please visit the Nagios Support Forums at:

http://support.nagios.com/forum/

5 (1)
Article Rating (1 Votes)
Rate this article
  • Icon PDFExport to PDF
  • Icon MS-WordExport to MS Word
Attachments Attachments
There are no attachments for this article.
Related Articles RSS Feed
Operating System Checks
Viewed 14302 times since Tue, Nov 14, 2017
Performance Counter Checks
Viewed 19448 times since Wed, Nov 15, 2017
Memory Checks
Viewed 47229 times since Mon, Nov 13, 2017
Process Checks
Viewed 60659 times since Thu, Nov 23, 2017
File And Folder Checks
Viewed 55014 times since Sun, Nov 26, 2017
Health Checks
Viewed 14173 times since Wed, Nov 29, 2017
Disk Space Checks
Viewed 78669 times since Thu, Nov 9, 2017
Agent Checks
Viewed 11289 times since Tue, Nov 14, 2017
Disk Performance Checks
Viewed 16700 times since Sun, Nov 26, 2017
Uptime Checks
Viewed 25736 times since Sun, Nov 26, 2017