Return-Path: X-Original-To: apmail-htrace-dev-archive@minotaur.apache.org Delivered-To: apmail-htrace-dev-archive@minotaur.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id AA50618158 for ; Thu, 8 Oct 2015 19:01:36 +0000 (UTC) Received: (qmail 35021 invoked by uid 500); 8 Oct 2015 19:01:36 -0000 Delivered-To: apmail-htrace-dev-archive@htrace.apache.org Received: (qmail 34953 invoked by uid 500); 8 Oct 2015 19:01:36 -0000 Mailing-List: contact dev-help@htrace.incubator.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@htrace.incubator.apache.org Delivered-To: mailing list dev@htrace.incubator.apache.org Received: (qmail 34940 invoked by uid 99); 8 Oct 2015 19:01:36 -0000 Received: from Unknown (HELO spamd4-us-west.apache.org) (209.188.14.142) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 08 Oct 2015 19:01:36 +0000 Received: from localhost (localhost [127.0.0.1]) by spamd4-us-west.apache.org (ASF Mail Server at spamd4-us-west.apache.org) with ESMTP id 21798C0F5F for ; Thu, 8 Oct 2015 19:01:36 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd4-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: 0.97 X-Spam-Level: X-Spam-Status: No, score=0.97 tagged_above=-999 required=6.31 tests=[KAM_LAZY_DOMAIN_SECURITY=1, RCVD_IN_MSPIKE_H3=-0.01, RCVD_IN_MSPIKE_WL=-0.01, T_RP_MATCHES_RCVD=-0.01] autolearn=disabled Received: from mx1-eu-west.apache.org ([10.40.0.8]) by localhost (spamd4-us-west.apache.org [10.40.0.11]) (amavisd-new, port 10024) with ESMTP id jbs9hFUA7iuF for ; Thu, 8 Oct 2015 19:01:35 +0000 (UTC) Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by mx1-eu-west.apache.org (ASF Mail Server at mx1-eu-west.apache.org) with SMTP id 439A724E1C for ; Thu, 8 Oct 2015 19:01:34 +0000 (UTC) Received: (qmail 34922 invoked by uid 99); 8 Oct 2015 19:01:33 -0000 Received: from mail-relay.apache.org (HELO mail-relay.apache.org) (140.211.11.15) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 08 Oct 2015 19:01:33 +0000 Received: from mail-wi0-f170.google.com (mail-wi0-f170.google.com [209.85.212.170]) by mail-relay.apache.org (ASF Mail Server at mail-relay.apache.org) with ESMTPSA id E27631A0163 for ; Thu, 8 Oct 2015 19:01:32 +0000 (UTC) Received: by wicfx3 with SMTP id fx3so41663013wic.1 for ; Thu, 08 Oct 2015 12:01:31 -0700 (PDT) MIME-Version: 1.0 X-Received: by 10.194.248.198 with SMTP id yo6mr11195354wjc.66.1444330891180; Thu, 08 Oct 2015 12:01:31 -0700 (PDT) Received: by 10.195.11.74 with HTTP; Thu, 8 Oct 2015 12:01:31 -0700 (PDT) In-Reply-To: <20783_1444325541_t98HWKoH022398_CAKFCR+dXx7FLYJ3Oz+ReQSbxy_3HdDa9RO_s62REMhQQqUCLzw@mail.gmail.com> References: <20783_1444325541_t98HWKoH022398_CAKFCR+dXx7FLYJ3Oz+ReQSbxy_3HdDa9RO_s62REMhQQqUCLzw@mail.gmail.com> Date: Thu, 8 Oct 2015 12:01:31 -0700 Message-ID: Subject: Re: Java exception From: "Colin P. McCabe" To: dev@htrace.incubator.apache.org Content-Type: text/plain; charset=UTF-8 Hi Odin, org/htrace/Trace is a class from the pre-Apache version of HTrace. It sounds like the HTrace jar you need is not 3.1.0-incubating, but perhaps 3.0.4 (or even some older version)? Try finding the source code for the version of Hadoop you are using and running "mvn dependency:tree" best, Colin On Thu, Oct 8, 2015 at 10:32 AM, Odin Guillermo Caudillo Gallegos wrote: > Hi, i'm building a code to write files on hdfs, but it gives me the > following error: > > Exception in thread "main" java.lang.NoClassDefFoundError: org/htrace/Trace > at org.apache.hadoop.hdfs.DFSOutputStream.(DFSOutputStream.java:1703) > at > org.apache.hadoop.hdfs.DFSOutputStream.newStreamForCreate(DFSOutputStream.java:1756) > at org.apache.hadoop.hdfs.DFSClient.create(DFSClient.java:1668) > at org.apache.hadoop.hdfs.DFSClient.create(DFSClient.java:1593) > at > org.apache.hadoop.hdfs.DistributedFileSystem$6.doCall(DistributedFileSystem.java:397) > at > org.apache.hadoop.hdfs.DistributedFileSystem$6.doCall(DistributedFileSystem.java:393) > at > org.apache.hadoop.fs.FileSystemLinkResolver.resolve(FileSystemLinkResolver.java:81) > at > org.apache.hadoop.hdfs.DistributedFileSystem.create(DistributedFileSystem.java:393) > at > org.apache.hadoop.hdfs.DistributedFileSystem.create(DistributedFileSystem.java:337) > at org.apache.hadoop.fs.FileSystem.create(FileSystem.java:909) > at org.apache.hadoop.fs.FileSystem.create(FileSystem.java:802) > at test.HDFSMain.main(HDFSMain.java:23) > Caused by: java.lang.ClassNotFoundException: org.htrace.Trace > at java.net.URLClassLoader$1.run(URLClassLoader.java:366) > at java.net.URLClassLoader$1.run(URLClassLoader.java:355) > at java.security.AccessController.doPrivileged(Native Method) > at java.net.URLClassLoader.findClass(URLClassLoader.java:354) > at java.lang.ClassLoader.loadClass(ClassLoader.java:425) > at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:308) > at java.lang.ClassLoader.loadClass(ClassLoader.java:358) > ... 12 more > > I already have the htrace-core-3.1.0-incubating.jar in my external jars, > but it appears that isnt't looking for the apache one but a different > version. > I had included all the jars in the hadoop library folder but no success. > Thanks