SNMP error.

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.
UndMe
Posts: 14
Joined: Thu Nov 22, 2018 6:40 pm

Re: SNMP error.

Post by UndMe »

scottwilkerson wrote:What operating system are you on? I think you are missing several of the standard MIBs that should have been installed by default when you installed net-snmp
I'm using Ubuntu Server 16.04, the 32-bit version because this machine does not support 64.

Apart from nagios I have not installed any snmp, that may be the problem.
I did not know that the snmp was installed apart from nagios. :?:
scottwilkerson
DevOps Engineer
Posts: 19396
Joined: Tue Nov 15, 2011 3:11 pm
Location: Nagios Enterprises
Contact:

Re: SNMP error.

Post by scottwilkerson »

You may need to install snmp with

Code: Select all

sudo apt-get install snmp
Former Nagios employee
Creator:
ahumandesign.com
enneagrams.com
UndMe
Posts: 14
Joined: Thu Nov 22, 2018 6:40 pm

Re: SNMP error.

Post by UndMe »

scottwilkerson wrote:You may need to install snmp with

Code: Select all

sudo apt-get install snmp
I have the snmp service installed and I still have the same problem. I have to configure something else?
User avatar
tgriep
Madmin
Posts: 9177
Joined: Thu Oct 30, 2014 9:02 am

Re: SNMP error.

Post by tgriep »

For licensing reasons, net-snmp package installs only a small number of MIBs in /usr/share/mibs directory. A large number of standard MIBs can be installed using snmp-mibs-downloader package:
Run this to install the SNMP Downloader and download the MIB files.

Code: Select all

    $ sudo apt-get install snmp-mibs-downloader
    $ sudo download-mibs
To have the new MIBs recognized by net-snmp, edit /etc/snmp/snmp.conf file and add the following:

Code: Select all

mibs +ALL
That should download and install the missing MIB files on the server.
Be sure to check out our Knowledgebase for helpful articles and solutions!
UndMe
Posts: 14
Joined: Thu Nov 22, 2018 6:40 pm

Re: SNMP error.

Post by UndMe »

tgriep wrote:For licensing reasons, net-snmp package installs only a small number of MIBs in /usr/share/mibs directory. A large number of standard MIBs can be installed using snmp-mibs-downloader package:
Run this to install the SNMP Downloader and download the MIB files.

Code: Select all

    $ sudo apt-get install snmp-mibs-downloader
    $ sudo download-mibs
To have the new MIBs recognized by net-snmp, edit /etc/snmp/snmp.conf file and add the following:

Code: Select all

mibs +ALL
That should download and install the missing MIB files on the server.
Thank you very much, I have already solved the status of each port of the switch that I am monitoring.

But I do not understand the uptime that information gives me, I think you have to give me the time (hours, minutes, seconds) that the computer is on and I put something else I do not know how to interpret it.
I leave a capture for you to tell me.


If I execute the following command directly it gives me this (I put a picture):
/usr/local/nagios/libexec/check_snmp -H 192.168.1.17 -C public -o sysUPtime.0
This command may not understand well how this command works and I have to use another one.
Attachments
nagios2.PNG
Nagios.PNG
Nagios.PNG (5.52 KiB) Viewed 2565 times
User avatar
tgriep
Madmin
Posts: 9177
Joined: Thu Oct 30, 2014 9:02 am

Re: SNMP error.

Post by tgriep »

The following is a description of what the sysUpTime OID returns when it is polled.

"The time (in hundredths of a second) since the network management portion of the system was last re-initialized."

What you are seeing is a count of the number of tenths of a second the system has been up.

To get an output in Days, Hours, Minutes, Seconds, you would have to find a plugin that displays that data for you and this example I found on the Exchange site looks like it should work for you.
https://exchange.nagios.org/directory/P ... me/details
Be sure to check out our Knowledgebase for helpful articles and solutions!
UndMe
Posts: 14
Joined: Thu Nov 22, 2018 6:40 pm

Re: SNMP error.

Post by UndMe »

tgriep wrote:The following is a description of what the sysUpTime OID returns when it is polled.

"The time (in hundredths of a second) since the network management portion of the system was last re-initialized."

What you are seeing is a count of the number of tenths of a second the system has been up.

To get an output in Days, Hours, Minutes, Seconds, you would have to find a plugin that displays that data for you and this example I found on the Exchange site looks like it should work for you.
https://exchange.nagios.org/directory/P ... me/details
Thanks.
I'm going to try that plugin, but in what folder do I have to put it?
/usr/local/nagios/libexec
User avatar
tgriep
Madmin
Posts: 9177
Joined: Thu Oct 30, 2014 9:02 am

Re: SNMP error.

Post by tgriep »

In the same folder as all of the other plugins.
/usr/local/nagios/libexec
Be sure to check out our Knowledgebase for helpful articles and solutions!
Locked