Re: Mib Loading Problem

2006-03-02 Thread Dave Shield
On Thu, 2006-03-02 at 11:48 +0530, [EMAIL PROTECTED] wrote:

> 1) Is it possible to keep the mib2c generated .c .h files in some
> other directory (other than agent/mibgroup) and force the configure
> scripts to include those files while making snmpd ?
> 
> 2) Is there any way to force "--with-mib-modules " to look for .c
> and .h other than agent/mibgrop directory

No.
Configure will look in 'agent/mibgroup'


> 
> 3) Is it possible to implement the mibs and generate .so and while
> configuring snmpd include that .so instead of
> --with-mib-modules option and still the private mibs which
> implementation is part of .so gets  loaded.

One possibility would be to load the .so file dynamically when the
agent starts - see the 'dlmod' token in snmpd.conf(5).

Alternatively, you could try tweaking the mib_module_inits.h file
(after running configure, but before make) to add a call to the
initialisation routine of your .so file.   That's not something
I've tried myself, but it should work, I think.

Dave


---
This SF.Net email is sponsored by xPML, a groundbreaking scripting language
that extends applications into web and mobile media. Attend the live webcast
and join the prime developer group breaking into this new coding territory!
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=110944&bid=241720&dat=121642
___
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


Mib Loading Problem

2006-03-01 Thread somenath.pal
Title: Mib Loading Problem







Hi ALL,

I am facing one problem. I need to implement some private MIBS. I have generated the .c and .h using mib2c and then generated "libmhso.so" .I kept the .so in /tmp/MH directory and all the other netsnmp libraries in /tmp/rh/lib. While configuring netsnmp I am following the below steps

1)export LDFLAGS="-L/tmp/MH -L/tmp/rh/lib -L/usr/local/lib"
2)LIBS="-lmhso -lnetsnmp -lcrypto" ./configure --prefix=/tmp/march2
3)make
4)make install

I am excluding  --with-mib-modules option for loading the mibs.
But while trying snmpget on that particular private mib attribute whose implementation is part of .so
I am getting the error
snmpget -c public -v2c localhost mclbVcbMhHeartBeatTimeout.0
MCLB-VCB-MIB::mclbVcbMhHeartBeatTimeout.0 = No Such Object available on this agent at this OID

My question is

1) Is it possible to keep the mib2c generated .c .h files in some other directory (other than agent/mibgroup)
and force the configure scripts to include those files while making snmpd ?

2) Is there any way to force "--with-mib-modules " to look for .c and .h other than agent/mibgrop directory

3) Is it possible to implement the mibs and generate .so and while configuring snmpd include that .so instead of
--with-mib-modules option and still the private mibs which implementation is part of .so gets  loaded.

Please help.

Thanks,
Somenath