So, I actually just stumbled across the answer.

Having the file loaded in snmp.conf and apparently read and parsed in snmpd didn't work.

Adding a configure option

--with-mibfiles="/share/snmp/mibs/filename.txt"

worked.

Its still loading it as snmpd starts up, but now it seems to work and allow use of the MIB defined names instead of just using numeric OIDs.

Problem solved.

Doug

On 8/20/2019 4:15 PM, Doug Ehlers wrote:
Hi All,

I have I think a very basic question.  I've been chasing around on this for a couple of days.

I am setting up a custom monitor command in snmpd.conf.  As long as I supply numeric OIDs, it works fine.  However, if I supply a name in place of the OID, from an MIB file that resolves just fine with snmptranslate, snmpd throws a configuration error saying it can't find the OID.  I can see in the -Dread_config output of snmpd that it is seeing and loading my custom MIB file, and obviously snmptranslate is seeing it as well.

The question is this.  Should I be able to do this, or does the mib2c command get involved and I have to set up the .h and .c files in agent/mibgroup?  I'm really hoping creating the .c file isn't required and that I just have some other minor mis-configuration.

After spending a couple days reading and playing with it, I just was hoping for some confirmation from the group.

Thanks,
Doug


_______________________________________________
Net-snmp-users mailing list
Net-snmp-users@lists.sourceforge.net
Please see the following page to unsubscribe or change other options:
https://lists.sourceforge.net/lists/listinfo/net-snmp-users

--
Doug Ehlers
TimeMachines Inc
300 S 68th St Place, STE 100
Lincoln, NE  68510
(402) 486-0511 ext. 2
(206) 339-8595 FAX
http://www.timemachinescorp.com



_______________________________________________
Net-snmp-users mailing list
Net-snmp-users@lists.sourceforge.net
Please see the following page to unsubscribe or change other options:
https://lists.sourceforge.net/lists/listinfo/net-snmp-users

Reply via email to