Return-Path: X-Original-To: apmail-accumulo-user-archive@www.apache.org Delivered-To: apmail-accumulo-user-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 2087A116F6 for ; Mon, 16 Jun 2014 13:17:29 +0000 (UTC) Received: (qmail 26348 invoked by uid 500); 16 Jun 2014 13:17:28 -0000 Delivered-To: apmail-accumulo-user-archive@accumulo.apache.org Received: (qmail 26298 invoked by uid 500); 16 Jun 2014 13:17:28 -0000 Mailing-List: contact user-help@accumulo.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: user@accumulo.apache.org Delivered-To: mailing list user@accumulo.apache.org Received: (qmail 26285 invoked by uid 99); 16 Jun 2014 13:17:28 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 16 Jun 2014 13:17:28 +0000 X-ASF-Spam-Status: No, hits=1.5 required=5.0 tests=HTML_MESSAGE,RCVD_IN_DNSWL_LOW,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (athena.apache.org: domain of busbey@cloudera.com designates 209.85.216.178 as permitted sender) Received: from [209.85.216.178] (HELO mail-qc0-f178.google.com) (209.85.216.178) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 16 Jun 2014 13:17:24 +0000 Received: by mail-qc0-f178.google.com with SMTP id c9so7622710qcz.37 for ; Mon, 16 Jun 2014 06:17:03 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:content-type; bh=cpVxqviIE9TdrrFL4IoPUgowYvAnEltaPOuvdhSluoE=; b=eJReSGqWr3Q1ApQY8O1lISQKA1ppxaZB0Hwo+dDMjRE5qOSfDBS8aWDee7RfjRM880 0k5Ceyec91ER37sKNWrvKwz+UaGqMdZHnXwhwNph7wpvNa/FZDb4cq67KYJyLYoyJFGh kU97dXttmX2ugqy/sp5cJrS4ttla7Q5v/92DKiEvjPJlW7UoK8Qb237JlUL/r1cnVsCx +YeYvsxpJ4grF0BbF+D8wcp47weVFqkcPKIPp6b4u4p+x8uQx21ZTPqamyeMy8bQWwSB 5G8fooVqLNp5usQjAL1eAMvVZOp+k7BLGnd2/KuWFhHvZzHUoCmNvb+KyCQZtP1il2NM MEFA== X-Gm-Message-State: ALoCoQmR1XVKZrYKpPC/G/FPjMQWcKDVcIuC/L8EBNCwdK8oW8Lxq0u/ODhqZOZdcuqWgIdMhe8j X-Received: by 10.224.63.194 with SMTP id c2mr25801499qai.21.1402924623433; Mon, 16 Jun 2014 06:17:03 -0700 (PDT) MIME-Version: 1.0 Received: by 10.229.64.72 with HTTP; Mon, 16 Jun 2014 06:16:43 -0700 (PDT) In-Reply-To: References: From: Sean Busbey Date: Mon, 16 Jun 2014 09:16:43 -0400 Message-ID: Subject: Re: Need help. Error: java.lang.NoSuchMethodError: org.apache.commons.codec.binary.Base64.encodeBase64String To: Accumulo User List Content-Type: multipart/alternative; boundary=001a11c2cce8d3cf5204fbf3d7aa X-Virus-Checked: Checked by ClamAV on apache.org --001a11c2cce8d3cf5204fbf3d7aa Content-Type: text/plain; charset=UTF-8 Hi Jianshi! What version of Accumulo are you using? I believe you're running into a problem with what Accumulo presumes will be provided by Hadoop. The immediate fault is that Accumulo wants commons-codec. It's normally in the classpath as a part of Hadoop client. To make sure you have the entire classpath, I believe you're going to have to use the "Accumulo classpath" command: ${ACCUMULO_HOME}/bin/accumulo classpath Unfortunately, the output of this command is not tailored towards passing to another process, so you'll have to do some follow-on munging. In many of the Accumulo set ups I've seen, there are far more jars included in this classpath than Accumulo actually needs, so it might be best to use it as a guide for what you include manually. On Mon, Jun 16, 2014 at 5:19 AM, Jianshi Huang wrote: > Hi, > > I'm trying to use Accumulo with Spark writing to AccumuloOutputFormat. I > got the following errors in my spark app log: > > 14/06/16 02:01:44 INFO cluster.YarnClientClusterScheduler: > YarnClientClusterScheduler.postStartHook done > Exception in thread "main" java.lang.NoSuchMethodError: > org.apache.commons.codec.binary.Base64.encodeBase64String([B)Ljava/lang/String; > at > org.apache.accumulo.core.client.mapreduce.lib.impl.ConfiguratorBase.setConnectorInfo(ConfiguratorBase.java:127) > at > org.apache.accumulo.core.client.mapreduce.AccumuloOutputFormat.setConnectorInfo(AccumuloOutputFormat.java:92) > at > com.paypal.rtgraph.demo.MapReduceWriter$.main(MapReduceWriter.scala:44) > at > com.paypal.rtgraph.demo.MapReduceWriter.main(MapReduceWriter.scala) > at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) > at > sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) > at > sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) > at java.lang.reflect.Method.invoke(Method.java:606) > at > org.apache.spark.deploy.SparkSubmit$.launch(SparkSubmit.scala:292) > at org.apache.spark.deploy.SparkSubmit$.main(SparkSubmit.scala:55) > at org.apache.spark.deploy.SparkSubmit.main(SparkSubmit.scala) > > Anyone knows what's wrong with my code or settings? I've added all jars to > spark's classpath. > > And here's my spark-submit cmd: > > spark-submit --class com.paypal.rtgraph.demo.MapReduceWriter --master > yarn-client --jars `find lib -type f | tr '\n' ','` --driver-memory 2G > --executor-memory 20G --executor-cores 8 --num-executors 2 --verbose > rtgraph.jar > > If anyone has Accumulo+Spark examples, it would be great if they could be > shared. :) > > > Cheers, > > -- > Jianshi Huang > > LinkedIn: jianshi > Twitter: @jshuang > Github & Blog: http://huangjs.github.com/ > -- Sean --001a11c2cce8d3cf5204fbf3d7aa Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Hi Jianshi!

What version of Accumulo ar= e you using?

I believe you're running into a p= roblem with what Accumulo presumes will be provided by Hadoop. The immediat= e fault is that Accumulo wants commons-codec. It's normally in the clas= spath as a part of Hadoop client.

To make sure you have the entire classpath, I believe y= ou're going to have to use the "Accumulo classpath" command:<= /div>

${ACCUMULO_HOME}/bin/accumulo classpath

Unfortunately, the output of this command is not tailored to= wards passing to another process, so you'll have to do some follow-on m= unging. In many of the Accumulo set ups I've seen, there are far more j= ars included in this classpath than Accumulo actually needs, so it might be= best to use it as a guide for what you include manually.


On Mon,= Jun 16, 2014 at 5:19 AM, Jianshi Huang <jianshi.huang@gmail.com= > wrote:
Hi,

I'= m trying to use Accumulo with Spark writing to AccumuloOutputFormat. I got = the following errors in my spark app log:

14/06/16 02:01:44= INFO cluster.YarnClientClusterScheduler: YarnClientClusterScheduler.postSt= artHook done
Exception in thread "main" java.lang.NoSuchMethodError: org.= apache.commons.codec.binary.Base64.encodeBase64String([B)Ljava/lang/String;=
=C2=A0 =C2=A0 =C2=A0 =C2=A0 at org.apache.accumulo.core.client.m= apreduce.lib.impl.ConfiguratorBase.setConnectorInfo(ConfiguratorBase.java:1= 27)
=C2=A0 =C2=A0 =C2=A0 =C2=A0 at org.apache.accumulo.core.client.mapredu= ce.AccumuloOutputFormat.setConnectorInfo(AccumuloOutputFormat.java:92)
=C2=A0 =C2=A0 =C2=A0 =C2=A0 at com.paypal.rtgraph.demo.MapReduceWrite= r$.main(MapReduceWriter.scala:44)
=C2=A0 =C2=A0 =C2=A0 =C2=A0 at com.paypal.rtgraph.demo.MapReduceWriter= .main(MapReduceWriter.scala)
=C2=A0 =C2=A0 =C2=A0 =C2=A0 at sun.r= eflect.NativeMethodAccessorImpl.invoke0(Native Method)
=C2=A0 =C2= =A0 =C2=A0 =C2=A0 at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMeth= odAccessorImpl.java:57)
=C2=A0 =C2=A0 =C2=A0 =C2=A0 at sun.reflect.DelegatingMethodAccessorImp= l.invoke(DelegatingMethodAccessorImpl.java:43)
=C2=A0 =C2=A0 =C2= =A0 =C2=A0 at java.lang.reflect.Method.invoke(Method.java:606)
= =C2=A0 =C2=A0 =C2=A0 =C2=A0 at org.apache.spark.deploy.SparkSubmit$.launch(= SparkSubmit.scala:292)
=C2=A0 =C2=A0 =C2=A0 =C2=A0 at org.apache.spark.deploy.SparkSubmit$.ma= in(SparkSubmit.scala:55)
=C2=A0 =C2=A0 =C2=A0 =C2=A0 at org.apach= e.spark.deploy.SparkSubmit.main(SparkSubmit.scala)

Anyone knows what's wrong with my code or settings? I've added all= jars to spark's classpath.

And here's my spark-submit cmd:

spark-submit --class com.paypal.rtgraph.demo.MapReduceWriter --master= yarn-client --jars `find lib -type f | tr '\n' ','` --driv= er-memory 2G --executor-memory 20G --executor-cores 8 --num-executors 2 --v= erbose rtgraph.jar

If anyone has Accumulo+Spark examples, it would b= e great if they could be shared. :)


Cheers,
--
Jianshi Huang

LinkedIn: jianshi
Twitter: @jshuang
Github & Blog: http://huangjs.github.com/



--
Sean
--001a11c2cce8d3cf5204fbf3d7aa--