I have some VMWare ESX Servers and NetApp filers.
and wrote the following functions and probes to instrument CPU and Memory for them in The Dude:
(also there is a windows service probe)
FUNCTIONS
cpu_mem_disk_enhanced
Same as supllied cpu_mem_disk, but with added support for VMWare and NetApp CPU load
concatenate(
if(cpu_usage_available(), concatenate("cpu: ", round(cpu_usage()), "% "), “”),
if(vmcpu_usage_available(), concatenate("cpu: ", round(vmcpu_usage()), "% "), “”),
if(netappcpu_usage_available(), concatenate("cpu: ", round(netappcpu_usage()), "% "), “”),
if(mem_usage() > 0, concatenate("mem: ", round(mem_usage()), "% "), “”),
if(virtual_mem_usage() > 0, concatenate("virt: ", round(virtual_mem_usage()), "% "), “”),
if(hdd_usage() > 0, concatenate("disk: ", round(hdd_usage()), "% "), “”),
if(netapphdd_usage() > 0, concatenate("disk: ", round(netapphdd_usage()), "% "), “”)
)
device_performance_enh
Adjusted to call cpu_mem_disk_enhanced
if(
string_size(cpu_mem_disk_enhanced()) > 0,
concatenate(cpu_mem_disk_enhanced(), "
"),
“”
)
failed_service_summary
Shows failed services. Used to produce summary information on maps
if (device_property(“ServicesCount”)<>device_property(“ServicesUpCount”), concatenate(“Services (”, device_property(“ServicesUpCount”), “/”, device_property(“ServicesCount”), ")
", if (device_property(“ServicesUnstableCount”), concatenate("Unstable: ", device_property(“ServicesUnstableCount”), "
"), “”), if (device_property(“ServicesDownCount”), concatenate("Down: ", device_property(“ServicesDownCount”), "
"), “”), if (device_property(“ServicesAckedCount”), concatenate("Acked: ", device_property(“ServicesAckedCount”), "
"), “”), if (device_property(“ServicesUnknownCount”), concatenate("Unknown: ", device_property(“ServicesUnknownCount”), "
"), “”)), “”)
netappcpu_usage
Reports the CPU usage in percent of a NetApp
oid(“1.3.6.1.4.1.789.1.2.1.3.0”)
netappcpu_usage_available
Detects whether NetApp CPU usage is available
if(oid(“1.3.6.1.4.1.789.1.2.1.3.0”),1,0)
netapphdd_usage
Reports NetApp Total Storage usage as a percentage.
oid(“1.3.6.1.4.1.789.1.5.7.3.0”)
vmcpu_usage
Report the CPU usage in percent on a VMWare server
100-oid(“1.3.6.1.4.1.2021.11.11.0”)
vmcpu_usage_available
Detects whether VMWare CPU usage is available.
if (oid(“1.3.6.1.4.1.2021.11.11.0”),1,0)
FUNCTION PROBES
VMWare – cpu
Monitor the host CPU on a VMWare server
Available: vmcpu_usage_available()
Error: if(vmcpu_usage_available(), “”, “down”)
Value: vmcpu_usage()
Unit: %
Rate: none
NetApp - active disks
Number of active RAID disks
Available: if(oid(“1.3.6.1.4.1.789.1.6.4.2.0”)>0,1,0)
Error: if(oid(“1.3.6.1.4.1.789.1.6.4.2.0”)>0,“”,“none”)
Value: oid(“1.3.6.1.4.1.789.1.6.4.2.0”)
Unit:
Rate: none
NetApp - bad disks
Number of failed RAID disks
Available: if(oid(“1.3.6.1.4.1.789.1.6.4.7.0”)=0,1,0)
Error: if(oid(“1.3.6.1.4.1.789.1.6.4.7.0”)=0,“”,“bad disks”)
Value: oid(“1.3.6.1.4.1.789.1.6.4.7.0”)
Unit:
Rate: none
NetApp - bad fans
Number of failed cooling fans.
Available: if(oid(“1.3.6.1.4.1.789.1.2.4.2.0”)=0,1,0)
Error: if(oid(“1.3.6.1.4.1.789.1.2.4.2.0”)=0,“”,“bad fans”)
Value: oid(“1.3.6.1.4.1.789.1.2.4.2.0”)
Unit:
Rate: none
NetApp - bad power
Number of failed power supply units.
Available: if(oid(“1.3.6.1.4.1.789.1.2.4.4.0”)=0,1,0)
Error: if(oid(“1.3.6.1.4.1.789.1.2.4.4.0”)=0,“”,“bad psu”)
Value: oid(“1.3.6.1.4.1.789.1.2.4.4.0”)
Unit:
Rate: none
NetApp – cpu
CPU Busy % time
Available: netappcpu_usage_available()
Error: if(netappcpu_usage_available(), “”, “down”)
Value: netappcpu_usage()
Unit: %
Rate: none
NetApp - space used
Percentage of disk space used
Available: if(oid(“1.3.6.1.4.1.789.1.5.7.1.0”)>0,1,0)
Error: if(oid(“1.3.6.1.4.1.789.1.5.7.1.0”)>1,“disk space low”,“”)
Value: oid(“1.3.6.1.4.1.789.1.5.7.3.0”)
Unit: %
Rate: none
NetApp – spare disks
Number of spare disks in NetApp array
Available: if(oid(“1.3.6.1.4.1.789.1.6.4.8.0”)>0,1,0)
Error: if(oid(“1.3.6.1.4.1.789.1.6.4.8.0”)>0,“”,“no spares”)
Value: oid(“1.3.6.1.4.1.789.1.6.4.8.0”)
Unit:
Rate: none
NetApp – total disks
Total number of disks in NetApp array
Available: if(oid(“1.3.6.1.4.1.789.1.6.4.1.0”)>0,1,0)
Error: if(oid(“1.3.6.1.4.1.789.1.6.4.1.0”)>0,“”,“no disks”)
Value: oid(“1.3.6.1.4.1.789.1.6.4.1.0”)
Unit:
Rate: none
Windows Service MyService
Is the Windows Service MyService up
Available: if(array_find(oid_column(“1.3.6.1.4.1.77.1.2.3.1.1”),“MyService”)>0, 1, 0)
Error: if(array_find(oid_column(“1.3.6.1.4.1.77.1.2.3.1.1”),“MyService”)>0, “”, “MyService not detected by SNMP probe”)
Value: 1
Unit:
Rate: none
*Need to replace MyService with the name of the service that you actually want to monitor
SNMP PROBES
NetApp - over temp
Probe to detect NetApp temperature limit
Oid: iso.org.dod.internet.private.enterprises.netapp.netapp1.sysStat.environment.envOverTemperature.0
Type: integer
Compare: ==
String Value: 1
NetApp - status
Probe to detect when the NetApp is not ok
Oid: iso.org.dod.internet.private.enterprises.netapp.netapp1.sysStat.misc.
miscGlobalStatus.0
Type: integer
Compare: ==
String Value: 3
Also in “Server Configuration” → “Map” → “Device Appearance”
I modified the global default for device label to use the enhanced device performance function from the list above
Change Device Appearance Label to:
[Device.CustomField1]
[Device.Name]
[Device.FirstAddress]
[device_performance_enh()][failed_service_summary()]