Icinga / Nagios Plugins


Perl script for Icinga / Nagios to monitor temperature, disk and SMART status of all hard disks in QNAP NAS boxes via SNMP. Disk temperatures are returned as performance data. Should work on most (if not any) QNAP boxes that support SNMP. Based on Michael Geigers check_qnap_hdd with some bugfixes and improvements:

  • Corrected Perl Dependencies
  • Allows to specify SNMP community via -C parameter
  • Improved SMART Notification: SMART Status "Normal" is misleading as it indicates a predictive failure warning. The script returns a "Warning" condition instead of "Critical" in this case
  • Vertical alignment of visual HDD status looks nicer
  • Add support for newer Qnap models - e.g. TS-879 Pro
  • Don't get confused by emty drive slots (previous version returned UNKNOWN result)

Download check_qnap_hdd V.1.2


Perl script for Icinga / Nagios to monitor logical volume status on QNAP NAS boxes via SNMP. Returns used space of all volumes as performance data and allows setting usage percentage limits. Based on Michael Geigers check_qnap_volumes with changed behavior, bug fixes and improvements:

  • Corrected Perl Dependencies
  • Allows to specify SNMP community via -C parameter
  • Changed behavior: Performance data now shows the used space versus total space which is more intuitive
  • Changed behavior: Changed behavior: Warning and critical levels are now referring to used percentage instead of free percentage
  • Renamed to check_qnap_vol due to changed behavior
  • Removed "QNAP" from output. Shortens line and possibly allows to use with other NAS makes (if they use the NAS MIB)
  • Made output more informative like so:
    "Volumes OK - [Mirror Disk Volume: Drive 1 2]: 331GB (84%) of 393GB used, 62GB free"
  • Putting each volume on a new line makes output more readable with multiple volumes
  • Handle zero volume sizes correctly (caused div by zero error before) and give hint to possible assignment as iSCSI target

Download check_qnap_vol V.1.3


Icinga / Nagios check Plugin to test FTP speed by writing and reading a test file and measuring the time taken. Performance Data is supplied for Read and Write Speed in MBytes/s. Warning and Critical limits can be set for Write Speed. Test file size can be specified in order to adjust the tradeoff between network load and test accuracy. Instead of reading the written test file immediately after writing (which would give inaccurate results due to disk cashing) we are always reading the file written during the previous test interval. This is not intended as an accurate speed test but allows to judge performance variations over time and set performance limits for backup space repositories that must have a minimum throughput in order to allow backup jobs to finish in a given time window.


check_ftp_speed.php -H <host> -u <username> -p <password> -f <test file path> -s <test file size (kBytes)> -w <warning (Write MBytes/s)> -c <critical (Write MBytes/s)>

Download: check_ftp_speed V.1.0

Icinga2 on OpenSuse Leap 42.2

Icinga2 may show erratic behaviour including spurious false alerts and failing checks when running on OpenSuse Leap 42.2. Some checks show error messages similar to:

   Exception occured while checking '<host>': Error: Function call 'fork' failed with error code 11, 'Resource temporarily unavailable'

This error message usually indicates a shortage on memory or process resources but increasing ulimit values in /etc/security/limits.conf will not help. Reason for this behaviour is the new systemd attribute taskmax that has been added to Linux kernel 4.3 (Leap 42.2 uses Kernel 4.4). It limits the maximum number of tasks to 512 on all units. Depending on the total number of hosts and services that Icinga2 is checking, this task limit can cause Icinga2 to fail, especially under heavy load or shortly after start. You can view the effective limits with the command:

  systemctl status icinga2 | grep Tasks

The solution is simple: Edit file /etc/systemd/system/multi-user.target.wants/icinga2.service and add under [Service] section:


Execute systemctl daemon-reload and restart Icinga2 to activate the new setting.