From: Corey M. E. <cor...@co...> - 2002-10-31 16:06:07
|
Hi everyone, =20 I would like to get a better understanding of how to use the agent.pm perl module. I would like to extend the snmp agent. Currently we have an extension in c using the 4.2 version of UCD. I have downloaded the net-snmp-5.0.6 version, and would like to get an extension working using the perl modules. =20 I compiled the package as follows with no problems. =20 ./configure =96with-embedded-perl make make install =20 Now I would like to understand the usage of agent.pm I read the perldocs, but I didn=92t get a full understanding. =20 My understanding is as follows: =20 1. I have a MIB that I developed (enterprises.5271.x.x.) 2. I run the snmpd and compile the MIB into the agent using the appropriate arguments. 3. Now that the snmpd has perl embedded and the perl modules are compiled, I can write a perl script using the agent.pm module and register it into the agent right? 4. Then when request come to the snmp agent for my MIB, the perl script will function \&handler will handle the request right, and pass the results back to the snmp_agent, who will pass it back to the original request? =20 =20 I am trying to use the example in the Synopsis to build a working example. I would like to get something working initially where when a request comes back for an OID in my MIB, it returns =93You did it <oid string>=94. Just so I can get the script working. =20 Can someone please lead me in the right direction, this is for a work project and I would greatly appreciate any help, examples, or extra documentation. Where someone has successfully used the Agent.pm module to extend the snmp agent. =20 I would like to gain the following from this thread: =20 Better understanding of the process, Is what I said above correct as far as process? Examples of perl scripts using the Agent.pm Extra documentation if possible =20 I don=92t want to use C if I don=92t have to. =20 Thanks in advance =20 =20 =20 =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D Corey M. Ellis Senior Network Engineer, Comverse ICD 11 Broadway Ste 365, New York, NY 10004 Office: 212.652.6790 Mobile: 856.278.0550 Fax: 212.652.6790 Email: cor...@co... =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D =20 --- Outgoing mail is certified Virus Free. Checked by AVG anti-virus system (http://www.grisoft.com). Version: 6.0.408 / Virus Database: 230 - Release Date: 10/24/2002 =20 |