Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

netsnmp agent: how to get value for any OID from my agent extention

Status
Not open for further replies.

mrkozmic

Programmer
May 25, 2011
2
NO
Hi,
I have added a MIB to by agent and wrote som GET/SET operations and traps. I would like to include values for OIDs from other MIBS and attach those to a
trap I'm sending. How do I do that? Do I have to do that in c code or in the MIB definition file?
 
You would define that in the MIB file(OBJECTS clause i think).

Then some c-coding would probably have to be done, not sure.

Bill
 
Thanks bnorton916, but that's the c coding part I need more info on. At least which API part should I look at.
 
Hi!

I need some guidance to write new MIB or how to customize existing MIBs.

I want to change IP-MIB , i want to change it ipAddress portion from read to read-write access.

plz guide me in this concern.
Thanks
 
I believe that would cause a revision of the IP-MIB something that is not likely to happen.

Writing a new MIB is not trivial.

What is this all for?
 
Thanks for reply sir!

Actually i want to change some Parameters/Object via snmp interface.
like we change sysContact or sysName of System group via SNMP set command, but we cant IP because Access is restricted to read only for IP and read-write for Some System group objects.


 
Sir!
As i am beginners, so i started a easy task,and now i am stuck at one point and could not find out the solution.

i created a private MIB with an object(purpose of it to just Display String when snmpget invoked in terminal).

i generated .c and .h files using mib2c and mib2c.scalar.conf. i compiled source code of NET-snmp with new MIB and compiled it successfully!

snmptranslate command wokrs fine but when i run snmoget command, i got object is unknown, can you guide me in this concern plz.

Thanks
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top