check_netapp_netport (Link State)

Checks the link-state of net-ports.

Usage

$ check_netapp_netport -H <host> [--ok-state=<regex>] [...] [--help]

Description

This plugin checks each net-ports link-state. Alarms if link-state is not up (default).

sim96cluster::> network port show

Node: sim96cluster-01
                                                  Speed(Mbps) Health
Port      IPspace      Broadcast Domain Link MTU  Admin/Oper  Status
--------- ------------ ---------------- ---- ---- ----------- --------
e0a       Default      Default          up   1500  auto/1000  healthy
e0b       Default      Default          down 1500  auto/-     -
e0c       Default      Default          up   1500  auto/1000  healthy
e0d       Default      Default          up   1500  auto/1000  healthy
4 entries were displayed.

Examples

Simple Examples

./check_netapp_netport -H sim96
NETAPP_PRO NETPORT OK - 4 netports checked
sim96cluster-01.e0b.physical (enabled, state: up)
sim96cluster-01.e0d.physical (enabled, state: up)
sim96cluster-01.e0c.physical (enabled, state: up)
sim96cluster-01.e0a.physical (enabled, state: up)

Checks all net-ports. Would return CRITICAL if the state is not ‘up’


./check_netapp_netport -H sim96
NETAPP_PRO NETPORT CRITICAL - 4 netports checked, 1 CRITICAL
sim96cluster-01.e0b.physical (CRITICAL) (enabled, state: down)
sim96cluster-01.e0d.physical (enabled, state: up)
sim96cluster-01.e0c.physical (enabled, state: up)
sim96cluster-01.e0a.physical (enabled, state: up)

Same as above - but one of the ports is down.


Advanced Examples

Skipping disabled ports

Disabling a port is often not possible via the filer’s UI. So this switch might be useless on some systems.

./check_netapp_netport -H sim96
NETAPP_PRO NETPORT CRITICAL - 4 netports checked, 1 CRITICAL
sim96cluster-01.e0b.physical (CRITICAL) (disabled, state: down)
sim96cluster-01.e0d.physical (enabled, state: up)
sim96cluster-01.e0c.physical (enabled, state: up)
sim96cluster-01.e0a.physical (enabled, state: up)

One of the ports is still down but disabled as well. This allows to skip it by means of the --ignore-disabled switch:

./check_netapp_netport -H sim96 --ignore-disabled
NETAPP_PRO NETPORT OK - 3 netports checked
sim96cluster-01.e0d.physical (enabled, state: up)
sim96cluster-01.e0c.physical (enabled, state: up)
sim96cluster-01.e0a.physical (enabled, state: up)

Skipping (or choosing) ports by name

With --exclude and --include ports can be excluded or included depending on their name. Since these parameters also accept a regular expression specific nodes can be tested. (See also Regular Expressions)

./check_netapp_netport -H sim96 --include=e0a
NETAPP_PRO NETPORT OK - 1 netport checked
sim96cluster-01.e0a.physical (enabled, state: up)

Checks exactly one net-port.


./check_netapp_netport -H mycluster --include="~^mycluster-01\."
NETAPP_PRO NETPORT OK - 4 netports checked
mycluster-01.e0b.physical (enabled, state: up)
mycluster-01.e0d.physical (enabled, state: up)
mycluster-01.e0c.physical (enabled, state: up)
mycluster-01.e0a.physical (enabled, state: up)

Checks only the net-ports on node “01”.


Monitoring Interface Groups

For partial degradation monitoring of interface groups (e.g. detecting when an ifgrp is up but has lost some member ports), use the dedicated check_netapp_ifgrp check. It compares active ports against member ports and can alarm on partial failures — something check_netapp_netport cannot detect.

check_netapp_netport can see interface groups but only reports their overall link-state (up or down). To avoid duplicate alerts, you can exclude ifgrps from this check:

./check_netapp_netport -H cluster1
NETAPP_PRO NETPORT CRITICAL - 9 net-ports checked, 1 critical and 0 warning.
cluster1-01.e0a.physical: up
cluster1-01.e0b.physical: up
cluster1-01.e0c.physical: up
cluster1-01.e0d.physical: up
cluster1-02.e0a.physical: up
cluster1-02.e0b.physical: up
cluster1-02.e0c.physical: up
cluster1-02.e0d.physical: up
cluster1-01.g0a.if_group: down (CRITICAL)

Exclude interface groups and monitor them separately with check_netapp_ifgrp:

./check_netapp_netport -H cluster1 --exclude="~lag$"
NETAPP_PRO NETPORT OK - 8 net-ports checked
cluster1-01.e0a.physical: up
cluster1-01.e0b.physical: up
cluster1-01.e0c.physical: up
cluster1-01.e0d.physical: up
cluster1-02.e0a.physical: up
cluster1-02.e0b.physical: up
cluster1-02.e0c.physical: up
cluster1-02.e0d.physical: up