SNMP Association file directory
Eranga Udesh
eranga@REDACTED
Fri Apr 28 10:00:09 CEST 2006
Hi,
I have made the mistake and thought the .funcs files are loaded in run-time.
But after your advice, I moved the .funcs files to the directory where the
MIBs files are located, compiled the MIBs and loaded to BIN (compiled MIB)
files to the SNMP agent (giving the full path) and now it's working
perfectly.
Thank you very much for your advice.
Regards,
- Eranga
-----Original Message-----
From: Micael Karlberg [mailto:bmk@REDACTED]
Sent: Thursday, April 27, 2006 6:42 PM
To: Eranga Udesh
Cc: erlang-questions@REDACTED
Subject: Re: SNMP Association file directory
Hi,
Eranga Udesh wrote:
> Hi,
>
> Thanks for the reply.
>
> Yes, I am talking about the .funcs files. Where should I place them in a
> release? As per my knowledge the SNMP application (in my case SNMP Agent)
> loads those files when loading the MIBs (compiled), correct? So, how can I
> give the corresponding .funcs file for a certain MIB when loading?
>
The data of the funcs-file (an MFA) is compiled into the MIB, so you only
have to make sure that your node has the path to the module implementing
the functions referenced in the funcs-file.
> In my .config file for the release I have below entries.
>
> {snmp,
> [{agent,
> [
> ....,
> {db_dir,
"/usr2/omni_oam/system/lib/omni_oam-2.0/priv/snmp/agent/db"},
> ....,
> {config, [{dir,
>
"/usr2/omni_oam/system/lib/omni_oam-2.0/priv/snmp/agent/conf"},{force_load,
> true},{verbosity, silence}]},
> ....}]}]},
>
> I have placed the compiled MIB files (.bin) in the directory specified by
> db_dir parameter, but when I try to do snmpa:load_mibs/2 with just the
name
> of the MIB file, it doesn't work (error - noent). But if I give the full
> path to the MIB file, it loads the file. But still I don't see it loading
> the .funcs file, though I have the .funcs file in the same directory where
> the .bin file is located.
As stated by the documentation, you have to give the full path to the
MIB-file. You can put your MIB-files anywhere you like.
As I wrote in my previous mail, db_dir is just a place for the snmp
application to store internal data.
>
> Please help if you see any problem I do.
>
> Thanks,
> - Eranga
>
/BMK
>
>
> -----Original Message-----
> From: Micael Karlberg [mailto:bmk@REDACTED]
> Sent: Thursday, April 27, 2006 2:07 PM
> To: Eranga Udesh
> Cc: erlang-questions@REDACTED
> Subject: Re: SNMP Association file directory
>
> Hi,
>
> Eranga Udesh wrote:
>> Hi,
>>
>>
>>
>> In a release where should the Association file located?
>
> Association file? Do you mean the .funcs files?
>
>> I installed in
>> the directory which I specified as the db_dir in the SNMP config file,
>
> db_dir is just a place for the snmp application to store internal data.
> It does not care what else you put into that directory, as long as you
> don't mess with the files created by the snmp application. But in
> principle, I would leave that directory to the snmp application (and not
> put my own stuff into it).
>
>> but it doesn't seem to be loading that file. The compiled MIB files
>> (.bin) are also located in that directory. Also I had to give the full
>> path to the .bin file (it didn't get it from the db_dir parameter place).
>>
>
> Most of this stuff is described in the documentation.
>
>>
>>
>> What could be wrong?
>>
>>
>>
>> Thanks,
>>
>> - Eranga
>>
>
> /BMK
>
>
>
More information about the erlang-questions
mailing list