2 Replies Latest reply on Jun 29, 2005 3:23 AM by Armando Ota

    Howot Add external Libaries

    - - Newbie

      I tried to add some externals libs to use JBoss as a Snmp Server.
      But I still get the error Message, when I try to deploy the app. Do I have to package the external jar somehow?


      java.lang.NoClassDefFoundError: com/adventnet/snmp/beans/SnmpTarget


      The Code looks like this:
      public String GetSnmpSysName(String TargetURL) {
       String result = "" ;
       try {
       SnmpTarget target = new SnmpTarget();
       target.setCommunity("public");
       target.setTargetHost("localhost");
       target.setObjectID(".1.3.6.1.2.1.1.1.0");
       result = target.snmpGet();
       }
       catch(Exception e)
       {
       System.out.println(e.toString());
       }
       return result;
       }
      

      The Code works without beeing in a EJB
      Thanks for any help

      Mathias



        • 1. Re: Howot Add external Libaries
          - - Newbie

          Hi People,
          my Problem is solved, I had to add the jars into the /server/default/lib directory to to find them.

          Cheers Mathias

          • 2. Re: Howot Add external Libaries
            Armando Ota Newbie

            OK here is my problem !!! with your idea ..

            I have some libs .. that are allready in the JBoss .. but I dont want Jboss to use the new one .. since I'm not sure what was really changed and might effect Jboss work .. How do I do that .. I cant put my new libs in the LIB folder since they exist .. I tried to put it in the same dir as my App but not working . any ideas would be appreciated !!


            bye

            Armando