Page 2 of 3

Re: Monitor Sophos Firewall Through Nagios

Posted: Fri May 06, 2016 2:23 pm
by SJ04
Hi @tgriep,

so i copy MY MIB file to these Location:

Code: Select all

/usr/share/snmp/mibs/
on the Nagios Server and then run the Command which you have written down.

Re: Monitor Sophos Firewall Through Nagios

Posted: Fri May 06, 2016 2:32 pm
by SJ04
hi ,

Can you please write me Down one command for One Value.

Code: Select all

/usr/local/nagios/libexec/check_snmp -H 192.168.1.1 -o 1.3.6.1.4.1.9789.1500.1.117
,

when i use the Command I get again the Same Error like these.

Code: Select all

External command error: Error in packet
Reason: (noSuchName) There is no such variable name in this MIB.
Failed object: iso.3.6.1.4.1.9789.1500.1.117

Re: Monitor Sophos Firewall Through Nagios

Posted: Fri May 06, 2016 4:24 pm
by SJ04
When i use -n in check_snmo command i get this Output., no matter which OID i am Using.

Code: Select all

./check_snmp -n -H 10.30.0.1 -o .1.3.6.1.4.1.9789.1500.3.82 16
SNMP OK - Timeticks: (560619050) 64 days, 21:16:30.50 |

Re: Monitor Sophos Firewall Through Nagios

Posted: Sat May 07, 2016 3:05 pm
by SJ04
Hi Guys,

Please Help me , I have Checked the Whole Internet but i didnt Find the Answer for my Problem.

Re: Monitor Sophos Firewall Through Nagios

Posted: Sat May 07, 2016 3:37 pm
by SJ04
tgriep wrote:Here is a command you use to show you the OID number and the associated description to it.

Code: Select all

snmptranslate -m /usr/share/snmp/mibs/ASTARO-MIB.txt -Tz
You can use the output to look for the OID you can use for the check_snmp commands you want.
hey ,

do you any suggestion about my last reply ?

Re: Monitor Sophos Firewall Through Nagios

Posted: Sun May 08, 2016 7:24 pm
by Box293
SJ04 wrote:Hello There,

I am in trouble with monitoring the Sophos Firewall via Nagios. I have downloaded the Firewall MIB file and when i trying to get the Value of Firewall i am having this Error.

Code: Select all

/usr/local/nagios/libexec/check_snmp -H 192.168.1.1 -o .1.3.6.1.4.1.9789 1
External command error: Error in packet
Reason: (noSuchName) There is no such variable name in this MIB.
Failed object: iso.3.6.1.4.1.9789
i have also copied the MIB file to SNMP/MIB directory but it still didnt work. Will be really Appricating if someone can help me out.

thanks

SJ04
I've noticed in your commands you have the OID followed by a space and then another number. This does not appear to be correctly formatted.

Normally OIDs end with a .0
If they end with a .1 then it is a reference to a table, not a value.

What is the result of these commands:

Code: Select all

/usr/local/nagios/libexec/check_snmp -H 192.168.1.1 -o .1.3.6.1.4.1.9789.0
/usr/local/nagios/libexec/check_snmp -H 192.168.1.1 -o .1.3.6.1.4.1.9789.1
/usr/local/nagios/libexec/check_snmp -H 192.168.1.1 -o 1.3.6.1.4.1.9789.1500.1.117.0
/usr/local/nagios/libexec/check_snmp -H 192.168.1.1 -o 1.3.6.1.4.1.9789.1500.1.117.1
Also:
The commands you have been using will be using SNMP v1 by default. I suggest you add -P 2c to your commands.

None of your commands specify a community string, you should have something like -C public

Leave the leading period (.) off the oid

With those suggestions in mind, try these commands:

Code: Select all

/usr/local/nagios/libexec/check_snmp -H 192.168.1.1 -P 2c -C public -o 1.3.6.1.4.1.9789.0
/usr/local/nagios/libexec/check_snmp -H 192.168.1.1 -P 2c -C public -o 1.3.6.1.4.1.9789.1
/usr/local/nagios/libexec/check_snmp -H 192.168.1.1 -P 2c -C public -o 1.3.6.1.4.1.9789.1500.1.117.0
/usr/local/nagios/libexec/check_snmp -H 192.168.1.1 -P 2c -C public -o 1.3.6.1.4.1.9789.1500.1.117.1
You should do a walk on the device to see what OIDs are available:

Code: Select all

snmpwalk -v 2c -c public 192.168.1.1 -O n -m all 1.3.6.1.4.1.9789

Re: Monitor Sophos Firewall Through Nagios

Posted: Mon May 09, 2016 6:33 am
by SJ04
Box293 wrote:
SJ04 wrote:Hello There,

I am in trouble with monitoring the Sophos Firewall via Nagios. I have downloaded the Firewall MIB file and when i trying to get the Value of Firewall i am having this Error.

Code: Select all

/usr/local/nagios/libexec/check_snmp -H 192.168.1.1 -o .1.3.6.1.4.1.9789 1
External command error: Error in packet
Reason: (noSuchName) There is no such variable name in this MIB.
Failed object: iso.3.6.1.4.1.9789
i have also copied the MIB file to SNMP/MIB directory but it still didnt work. Will be really Appricating if someone can help me out.

thanks

SJ04
I've noticed in your commands you have the OID followed by a space and then another number. This does not appear to be correctly formatted.

Normally OIDs end with a .0
If they end with a .1 then it is a reference to a table, not a value.

What is the result of these commands:

Code: Select all

/usr/local/nagios/libexec/check_snmp -H 192.168.1.1 -o .1.3.6.1.4.1.9789.0
/usr/local/nagios/libexec/check_snmp -H 192.168.1.1 -o .1.3.6.1.4.1.9789.1
/usr/local/nagios/libexec/check_snmp -H 192.168.1.1 -o 1.3.6.1.4.1.9789.1500.1.117.0
/usr/local/nagios/libexec/check_snmp -H 192.168.1.1 -o 1.3.6.1.4.1.9789.1500.1.117.1
Also:
The commands you have been using will be using SNMP v1 by default. I suggest you add -P 2c to your commands.

None of your commands specify a community string, you should have something like -C public

Leave the leading period (.) off the oid

With those suggestions in mind, try these commands:

Code: Select all

/usr/local/nagios/libexec/check_snmp -H 192.168.1.1 -P 2c -C public -o 1.3.6.1.4.1.9789.0
/usr/local/nagios/libexec/check_snmp -H 192.168.1.1 -P 2c -C public -o 1.3.6.1.4.1.9789.1
/usr/local/nagios/libexec/check_snmp -H 192.168.1.1 -P 2c -C public -o 1.3.6.1.4.1.9789.1500.1.117.0
/usr/local/nagios/libexec/check_snmp -H 192.168.1.1 -P 2c -C public -o 1.3.6.1.4.1.9789.1500.1.117.1
You should do a walk on the device to see what OIDs are available:

Code: Select all

snmpwalk -v 2c -c public 192.168.1.1 -O n -m all 1.3.6.1.4.1.9789
@Box293,
I have Tried as you have suggested but I am Again getting the Somehow the Same Error.

Code: Select all

snmpwalk -v 2c -c public 192.168.1.1 -O n -m all .1.3.6.1.4.1.9789.1500.2.31                           
  .1.3.6.1.4.1.9789.1500.2.31 = No Such Object available on this agent at this OID
Thank you for your Time
SJ04

Re: Monitor Sophos Firewall Through Nagios

Posted: Mon May 09, 2016 10:19 am
by rkennedy
Can you run the exact command @Box293 mentioned?

Code: Select all

snmpwalk -v 2c -c public 192.168.1.1 -O n -m all 1.3.6.1.4.1.9789
Additionally - can you please post the output to the other 8 commands mentioned?

Re: Monitor Sophos Firewall Through Nagios

Posted: Mon May 09, 2016 10:30 am
by tgriep
One more thing to do, create a file in this folder

Code: Select all

/etc/snmp
called

Code: Select all

snmp.conf
Add this line to that file

Code: Select all

mibs +ALL
This will ensure that all of the snmp commands you run will search all of the files in the /usr/share/snmp/mibs/ folder.

Did you copy the MIB file to that folder?
Can you run the following command and post the output?

Code: Select all

ls -l /usr/share/snmp/mibs/

Re: Monitor Sophos Firewall Through Nagios

Posted: Mon May 09, 2016 12:33 pm
by SJ04
tgriep wrote:One more thing to do, create a file in this folder

Code: Select all

/etc/snmp
called

Code: Select all

snmp.conf
Add this line to that file

Code: Select all

mibs +ALL
This will ensure that all of the snmp commands you run will search all of the files in the /usr/share/snmp/mibs/ folder.

Did you copy the MIB file to that folder?
Can you run the following command and post the output?

Code: Select all

ls -l /usr/share/snmp/mibs/
Hi ,

I have created the snmp.conf file and added the command but it still didnt work