[SNMP4J] novice help

Eugene Swank eswank at solectek.com
Wed Sep 6 17:48:37 CEST 2006


Thanks for the help, my only remaining question is how do I set the instance 1.3.6.1.4.1.4976.2.1.1.0 to config(2). Do I need to load one of the mibs into the MIB Explorer Pro to do this? Sorry I am still pretty new to this. 
  _____  

From: Frank Fock [mailto:fock at agentpp.com]
To: eswank at solectek.com
Cc: snmp4j at agentpp.org
Sent: Tue, 05 Sep 2006 13:00:56 -0700
Subject: Re: [SNMP4J] novice help

Hi Gene,

With SNMP4J-Agent 1.0 (which has now been released!) you can build
an simulation agent as follows:

1. Compile your MIB with AgenPro into its repository.
2. Load the MIB module into AgenPro's MIB tree.
3. Select the root node of your MIB module (if you want to
simulate more than one MIB module repeat this for each module)
and create a property (with the Properties tab) with name "simulation"
and set its value to "yes".
4. Open the snmp4j_by_selection project.
5. Edit the project settings and add the MIB modules you want
to simulate in the 3rd step of the wizard.
6. Run the code generation.
7. In directory snmp4j/src for each selected MIB module a .java file
will have been created.
8. Copy those files into a package directory of your choice and add
the necessary package construct to the sources.
9. Copy the TestAgent.java implementation into your new project and
replace occurrences of IfMib by your MIB module(s). (In fact you
register the MIB modules at the TestAgent).
10. Run the agent.
11. If you have an existing agent that implements the MIBs (or parts
of them), then use MIB Explorer Pro to take a snapshot from the agent.
Otherwise go directly to 12.
12. Use MIB Explorer, another MIB browser or SNMP4J to set
instance 1.3.6.1.4.1.4976.2.1.1.0 to config(2).
13. Either apply the values from the snapshot using MIB Explorer Pro's
restore snapshot feature or set the values to simulate using SNMP4J
or a browser by using SNMP. In config mode, even non-writable objects
can be written and created.

AgenPro 2 is a code generator for SNMP4J-Agent and can be tried out
from http://www.agentpp.com MIB Explorer can be checked out from
http://www.mibexplorer.com None of these products are required to
build a simulation agent with SNMP4J-Agent, but they help a lot.

To create a simulation agent manually, you should start with the
JavaDoc for the SimMOFactory.

Hope this helps.

Best regards,
Frank

Eugene Swank wrote:
> Everyone, 
> I am very new to SNMP4j and I have a question that may seem very novice, but I am confused about a few things. I am building an Element Management System for a wireless product, but the product is still months away from beta. In the mean time I want to develop a SNMP Agent to Simulate the network elements. I have been playing around with the SNMP4j agent code, but I am kinda lost when it comes to adding my own personal MIBs to the software. Is there a built in MIB compiler? I am able to use the test class that come with the product and perform simple gets and sets to it, but how do I simulate my MIB? 
> 
> Any help would be very much appreciated..
> Thanks,
> 
> Gene
> _______________________________________________
> SNMP4J mailing list
> SNMP4J at agentpp.org
> http://lists.agentpp.org/mailman/listinfo/snmp4j

-- 
AGENT++
http://www.agentpp.com
http://www.mibexplorer.com
http://www.mibdesigner.com

 


More information about the SNMP4J mailing list