Translations of this page:

check_snmp_env.pl

Link zum Download: http://patrick.proy.free.fr/nagios/index_commands.html

Das Plugin verwendet SNMP (V1 und V3) um den Environment status eines Gerätes zu prüfen. Je nach Gerätetyp (supported werden Cisco, Ironport, Foundry, Nokia, Bluecoat, netSNMP Linux) sind das Stromversorgung (Power supply), Ventilatoren (Fans), Spannungen (Voltages) und Temperaturen.

Einbindung des Plugins

Voraussetzung:

  • $USER1$ zeigt auf /usr/local/nagios/libexec
  • Perl in /usr/bin/perl
  • Net::SNMP

checkcommands.cfg

Erklärung: Die wichtigsten parameter des Plugins sind:

  • -C = Community
  • -P = port
  • -T = Type des gerätes

# check ihardware status

# 1=port, 2=community, 3=Type (cisco|nokia|bc|iron|foundry)
define command{
      command_name    check_env
      command_line    $USER1$/check_snmp_env.pl -H $HOSTADDRESS$ -p $ARG1$ -C $ARG2$ -T $ARG3$  $ARG4$
      }

services.cfg

Als Beispiel sei hier eine Firewall geprüft, deren Checkpoint SNMP agent auf port 260 läuft. (Bitte die standard parameter wie etwa check_period oder notification_options nach eigenen Bedürfnissen anpassen):

define service{
      host_name                       my_FW_node1
      service_description             hardware_status
      is_volatile                     0
      check_period                    24x7
      max_check_attempts              2
      normal_check_interval           9
      retry_check_interval            2
      contact_groups                  FW-admin
      notification_interval           180
      notification_period             24x7
      notification_options            c,r,w
      check_command                   check_env!260!c0mmun1ty!nokia!
}

Ausgabe

Beispielhafte Ausgabe des Plugins für eine Nokia Firewall:

Temp OK , 5 fan OK, 1 ps OK : all OK 

Sonstiges

Exakte Hilfe gibt es hier:

./check_snmp_env.pl --help

oder unter: http://patrick.proy.free.fr/nagios/index_commands.html#env

Siehe dazu auch das Nagios-Wiki HowTo für Checkpoint Firewall Monitoring

by StaGue 19. 07. 2009

nagios/plugins/check_snmp_env.pl.txt · Zuletzt geändert: 2009/07/19 23:32 von stague
CC Attribution-Noncommercial-Share Alike 3.0 Unported
www.chimeric.de Valid CSS Driven by DokuWiki do yourself a favour and use a real browser - get firefox!! Recent changes RSS feed Valid XHTML 1.0