check_snmp command question

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
Locked
User avatar
benhank
Posts: 1264
Joined: Tue Apr 12, 2011 12:29 pm

check_snmp command question

Post by benhank »

Im trying to use the check_snmp command to poll a server with snmp v3 When I run (in CCM/services/addnew)

Code: Select all

-U Nagios1017 -A SEalug17 -a SHA -x AES -X 71gulsES -L authNoPriv -P 3 -o $ARG1$
I get

Code: Select all

[[email protected] ~]# /usr/local/nagios/libexec/check_snmp -H 172.2.10.226-U Nagios1017 -A SEalug17 -a SHA -x AES -X 71gulsES -L authNoPriv -P 3 -o 1.3.6.1.4.1.35969.1.1.2.3.2
[-A authpasswd] [-X privpasswd]
What am I missing?
I can snmpwalk to the destination server with the credentials in the example.
Last edited by benhank on Mon Dec 05, 2016 11:56 am, edited 2 times in total.
Proudly running:
NagiosXI 5.4.12 2 node Prod Env 2500 hosts, 13,000 services
Nagiosxi 5.5.7(test env) 2500 hosts, 13,000 services
Nagios Logserver 2 node Prod Env 500 objects sending
Nagios Network Analyser
Nagios Fusion
User avatar
mcapra
Posts: 3739
Joined: Thu May 05, 2016 3:54 pm

Re: check_snmp command question

Post by mcapra »

Can you show your command definition for check_snmp? It looks like there might be a missing space between $HOSTADDRESS$ and $ARG1$ presented here:

/usr/local/nagios/libexec/check_snmp -H 172.2.10.226-U Nagios1017 -A SEaslug17 -a SHA -x AES -X 71gulsES -L authNoPriv -P 3 -o 1.3.6.1.4.1.35969.1.1.2.3.2
Former Nagios employee
https://www.mcapra.com/
avandemore
Posts: 1597
Joined: Tue Sep 27, 2016 4:57 pm

Re: check_snmp command question

Post by avandemore »

Please use the Run Check Command from XI > Configure > CCM > Services > [Your Service]. The output should look something like this:
run_check_command.png
You do not have the required permissions to view the files attached to this post.
Previous Nagios employee
User avatar
benhank
Posts: 1264
Joined: Tue Apr 12, 2011 12:29 pm

Re: check_snmp command question

Post by benhank »

here you go:
Capture.PNG
You do not have the required permissions to view the files attached to this post.
Proudly running:
NagiosXI 5.4.12 2 node Prod Env 2500 hosts, 13,000 services
Nagiosxi 5.5.7(test env) 2500 hosts, 13,000 services
Nagios Logserver 2 node Prod Env 500 objects sending
Nagios Network Analyser
Nagios Fusion
avandemore
Posts: 1597
Joined: Tue Sep 27, 2016 4:57 pm

Re: check_snmp command question

Post by avandemore »

It looks as if you're ARG1 field contains extraneous information.
Previous Nagios employee
User avatar
benhank
Posts: 1264
Joined: Tue Apr 12, 2011 12:29 pm

Re: check_snmp command question

Post by benhank »

ok, meybe I should rephrase my question.
Is there any documentation out there that shows how to correcty use check_snmp with snmp v3? I mknow that I can poll the server since snmpwak produced results. Im just missing something with the check command I think.
Proudly running:
NagiosXI 5.4.12 2 node Prod Env 2500 hosts, 13,000 services
Nagiosxi 5.5.7(test env) 2500 hosts, 13,000 services
Nagios Logserver 2 node Prod Env 500 objects sending
Nagios Network Analyser
Nagios Fusion
avandemore
Posts: 1597
Joined: Tue Sep 27, 2016 4:57 pm

Re: check_snmp command question

Post by avandemore »

https://www.monitoring-plugins.org/doc/ ... _snmp.html or

Code: Select all

# /usr/local/nagios/libexec/check_snmp -h
Previous Nagios employee
User avatar
Box293
Too Basu
Posts: 5126
Joined: Sun Feb 07, 2010 10:55 pm
Location: Deniliquin, Australia
Contact:

Re: check_snmp command question

Post by Box293 »

@benhank

Based on the troubleshooting I did with you, I've included SNMP v3 steps in the following updated documentation:

https://assets.nagios.com/downloads/nag ... g_SNMP.pdf
As of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.
User avatar
benhank
Posts: 1264
Joined: Tue Apr 12, 2011 12:29 pm

Re: check_snmp command question

Post by benhank »

BEHOLD! Thanks bro! you guys can lock this im all set
Proudly running:
NagiosXI 5.4.12 2 node Prod Env 2500 hosts, 13,000 services
Nagiosxi 5.5.7(test env) 2500 hosts, 13,000 services
Nagios Logserver 2 node Prod Env 500 objects sending
Nagios Network Analyser
Nagios Fusion
Locked