为 Hadoop 2.4 版本构建 Apache Pig [英] Building Apache Pig for Hadoop 2.4 version

查看:27
本文介绍了为 Hadoop 2.4 版本构建 Apache Pig的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我下载了 PIG 0.14 并做了一个 ant -dhadoopversion=23 jar ,但是当我在 Hadoop 2.4 上使用它时它不起作用.除了跑蚂蚁还有什么我应该做的吗?

I downloaded PIG 0.14 and did an ant -dhadoopversion=23 jar , but when I used it on Hadoop 2.4 its not working. Is there anything I should do other than just running ant?

Pig 正在运行,但显示错误

Pig is running, but showing errors

ang.IncompatibleClassChangeError: 找到接口 org.apache.hadoop.mapreduce.JobContext,但需要类

ang.IncompatibleClassChangeError: Found interface org.apache.hadoop.mapreduce.JobContext, but class was expected

谢谢!

推荐答案

如果您从 SVN 主干检出 Pig,您可以在以下位置验证它使用的 Hadoop 版本$PIG_HOME/ivy/libraries.properties .对于23"配置文件,它是 2.4.0 .从源代码( ant -Dhadoopversion=23 )构建 Pig 后,您可以验证 ivy 是否已在 $PIG_HOME/build/ivy/lib/Pig 下检索到正确的 Hadoop jar.

我怀疑您的 PIG_CLASSPATH 中的 Hadoop 版本有误.

If you checked out Pig from SVN trunk you can verify the Hadoop version it uses at $PIG_HOME/ivy/libraries.properties . For the "23" profile it is 2.4.0 . After you have built Pig from source ( ant -Dhadoopversion=23 ) you can verify whether ivy has retrieved the correct Hadoop jars under $PIG_HOME/build/ivy/lib/Pig .

I suspect that you have a wrong Hadoop version in your PIG_CLASSPATH.

这篇关于为 Hadoop 2.4 版本构建 Apache Pig的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆