Setting up a MAX on snmp disk percentace

Support forum for Nagios Core, Nagios Plugins, NCPA, NRPE, NSCA, NDOUtils and more. Engage with the community of users including those using the open source solutions.
Locked
paries
Posts: 4
Joined: Thu Feb 09, 2017 12:03 pm

Setting up a MAX on snmp disk percentace

Post by paries »

Hello, I am a newbie
setting up my nagios core for the first time
So far so good

So i have created a command

Code: Select all

define command{
        command_name    snmp_Disk1_Usage
        command_line    $USER1$/check_snmp -o .1.3.6.1.4.1.2021.9.1.8.1 -H $HOSTADDRESS$ $ARG1$
}
This works fine with

Code: Select all

define service{
        use                     generic-service
        host_name               www2.myhost.com
        service_description     Disk 1 Usage Percentage
        check_command           snmp_Disk1_UsedPercentage!-C my_monitor
}
The one part where i can not seem to connect the dots is how do i set this up to fail when a particular MAX Percentage is reached

Thanks
rkennedy
Posts: 6579
Joined: Mon Oct 05, 2015 11:45 am

Re: Setting up a MAX on snmp disk percentace

Post by rkennedy »

You'll want to append to your check_command, further information to pass to $ARG1$. The warning / critical values are usually adjusted with the -w / -c variables -

Code: Select all

[root@xi libexec]# ./check_snmp
check_snmp: Could not parse arguments
Usage:
check_snmp -H <ip_address> -o <OID> [-w warn_range] [-c crit_range]
[-C community] [-s string] [-r regex] [-R regexi] [-t timeout] [-e retries]
[-l label] [-u units] [-p port-number] [-d delimiter] [-D output-delimiter]
[-m miblist] [-P snmp version] [-L seclevel] [-U secname] [-a authproto]
[-A authpasswd] [-x privproto] [-X privpasswd]

Former Nagios Employee
tmcdonald
Posts: 9117
Joined: Mon Sep 23, 2013 8:40 am

Re: Setting up a MAX on snmp disk percentace

Post by tmcdonald »

Just checking in since we have not heard from you in a while. Did @rkennedy's post clear things up or has the issue otherwise been resolved?
Former Nagios employee
Locked