Results 1 to 6 of 6

Thread: Java Programming using Adventnet SNMP Java API

  1. #1
    Join Date
    Apr 2010
    Posts
    57

    Java Programming using Adventnet SNMP Java API

    Hi everyone, I am trying to write a code that can be able to connect remote SMTP device and a proper responses from that device. However , I have not idea about which classes for this to work (when using Adventnet SMTP java API). Would you all help me about the same..

    1. Message processing model
    2. User Security Model
    3. How to use OID

    I am discussing about such concepts as I used these components in SNMP4J..But , I have not any idea to use them in ADVENTNET SNMP API.

  2. #2
    Join Date
    Oct 2005
    Posts
    2,358

    Re: Java Programming using Adventnet SNMP Java API

    I am working with the snmp4j classes are able to create, send and getting SNMPv1/v2c/v3 messages. A SNMP message is written of its message header and its PDU payloads. This one package have three different and primary groups of classes and interfaces as a linking destination for the SMTP4J libraries. I require to search out something same to Adventnet SNMP as well. I selected to go with the javadocs..It does not tell me how the object and class usage occur when we make the SMTP connection in the network.
    I'm the Proud Owner of the most dangerous weapon
    known to man kind: Human Brain

  3. #3
    Join Date
    Apr 2010
    Posts
    52

    Re: Java Programming using Adventnet SNMP Java API

    Hello, Whenever I start the snmp-routine, then I got the warning-message as "Unable to load the AdventNet SNMP API properties file" is getting displayed on the screen . How can I search out the properties file or the way through which I can be able to remove out the message activation. How do I get rid from this one error message.

  4. #4
    Join Date
    Sep 2005
    Posts
    1,370

    Re: Java Programming using Adventnet SNMP Java API

    The gcjsnmp2.jar file always requires the extraction with the manual procedure because the GCJ compiler does not detect into the jar files for the specified classes. It can be performed with the help of JDK's jar utility using the following specified method .

    1- Unzip the jar file within the classes directory where the com.adventnet.snmp.snmp2 package contains . The unzipping will result in overwriting of the already having SASClient class in the com/adventnet/snmp/snmp2/directory with the another one SASClient class in the jar.

    2- unzip the classes in a different folder. After unzipping, the gcjsnmp2 package should be initially configured within the CLASSPATH suggested by the main AdventNet classes.
    DFI LANPARTY SLI-DR
    AMD 64 x2 4800+
    OCZ (2 x 512) DDR600

  5. #5
    Join Date
    Apr 2010
    Posts
    57

    Re: Java Programming using Adventnet SNMP Java API

    I am running with the exact issue when I use to run the code below :

    Code:
    import com.adventnet.snmp.beans.*;
    
    public class snmpget {
    
    public snmpget() {
    SnmpTarget target = new SnmpTarget();
    target.setTargetHost( "localhost");  
    
    target.setCommunity("public");
    target.setTimeout(5);
    target.setRetries(3);
    System.out.println(target.getCommunity());
    
    String oids[] = new String[1];
    // for (int lp=1;lp<opt.remArgs.length;lp++)
    oids[0] = ".1.3.6.1.2.1.1.1.0";
    target.setObjectIDList(oids);
    String result[] = target.snmpGetList(); 
    if (last == null) {
    System.err.println("Request failed or timed out. \n"+
    target.getErrorString());
    
    } else { 
    System.out.println("Response received. Values:");
    
    for (int lp=0;lp<oids.length;lp++) {
    System.out.println(target.getObjectID(lp) + ": " + last);
    }
    }
    }
    }
    It occurs the message as "unable to load the adventNet SNMP API properties file...please suggest me what should I do in this situation ???

  6. #6
    Join Date
    Apr 2008
    Posts
    1,948

    Re: Java Programming using Adventnet SNMP Java API

    The warning message displays if the snmp.properties file is not stored and configured within the AdventNetSnmp.jar . You are able to verify the similar by stating out the files available wihtin the AdventNetSnmp.jar and check whether the snmp.properties file is saved within the location com/adventnet/snmp/snmp2 . Hope this is clear and can be helpful to solve it out .

Similar Threads

  1. Object oriented programming with java
    By cloud101 in forum Software Development
    Replies: 2
    Last Post: 22-02-2012, 01:11 AM
  2. Help with java programming term
    By cloud101 in forum Software Development
    Replies: 1
    Last Post: 06-02-2012, 01:45 PM
  3. Java programming
    By overlord94 in forum Software Development
    Replies: 1
    Last Post: 07-10-2011, 07:45 PM
  4. What is RMI in java programming?
    By Sonam Goenka in forum Software Development
    Replies: 5
    Last Post: 12-03-2010, 08:37 PM
  5. How to Start programming in JAVA ?
    By Keegan in forum Software Development
    Replies: 11
    Last Post: 22-12-2008, 02:02 PM

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Page generated in 1,711,616,781.82830 seconds with 17 queries