如何在hadoop集群中加载本机hadoop库?

agxfikkp  于 2021-06-02  发布在  Hadoop
关注(0)|答案(1)|浏览(342)

我正在cloudera hadoop(cdh)4.6版本中运行revolutionr企业版7.0,使用mapreduce服务生成决策树。
当我运行hadoop集群计算上下文时,本机hadoop库似乎没有加载。我装了revoscaler软件包。
我已经检查了革命分析博客,pdf手册和这个论坛,我还没有找到解决办法。

> rxSetComputeContext(myHadoopCluster)
> BetterTree <- rxDTree(CountryCode ~ IndicatorCode + 1960 + 1961 + 1962 + 1963 + 1964 + 1965 + 1966 + 1967 + 1968 + 1969 + 1970 + 1971 + 1972 + 1973 + 1974 + 1975 + 1976 + 1977 + 1978 + 1979 + 1980 + 1981 + 1982 + 1983 + 1984 + 1985 + 1986 + 1987 + 1988 + 1989 + 1990 + 1991 + 1992 + 1993 + 1994 + 1995 + 1996 + 1997 + 1998 + 1999 + 2000 + 2001 + 2002 + 2003 + 2004 + 2005 + 2006 + 2007 + 2008 + 2009 + 2010 + 2011 + 2012 + 2013, data=salida, blocksPerRead=30, maxUnorderedLevels = 1300,  cp=1e-5)
======  localhost.localdomain (Master HPA Process) has started run at Fri May 23 16:45:42 2014  ======
RxInitializeHadoop sSystemCommand: hadoop RevoScaleR -Dmapred.reduce.tasks=1     -Dmapred.min.split.size=9223372036854775807 /user/RevoShare/cloudera/F8D3BB9C6CDE411CA0F48520656EFE19    /.input /user/RevoShare/cloudera/F8D3BB9C6CDE411CA0F48520656EFE19/IRO.iro /share/better localhost.localdomain 8020 /usr/bin/Revoscript
14/05/23 16:46:40 WARN util.NativeCodeLoader:**Unable to load native-hadoop library for your  platform... using builtin-java classes where applicable**
RxInitializeHadoop after fixup sSystemCommand: hadoop  RevoScaleR  -Dmapred.reduce.tasks=1  -Dmapred.min.split.size=9223372036854775807  /user/RevoShare/cloudera/F8D3BB9C6CDE411CA0F48520656EFE19/.input  /user/RevoShare/cloudera/F8D3BB9C6CDE411CA0F48520656EFE19/IRO.iro  /share/better/*  localhost.localdomain  8020  /usr/bin/Revoscript
Exception in thread "main" java.lang.NoClassDefFoundError: RevoScaleR
Caused by: java.lang.ClassNotFoundException: RevoScaleR
at java.net.URLClassLoader$1.run(URLClassLoader.java:202)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:190)
at java.lang.ClassLoader.loadClass(ClassLoader.java:306)
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:301)
at java.lang.ClassLoader.loadClass(ClassLoader.java:247)
Could not find the main class: RevoScaleR.  Program will exit.

HadoopMR output object '/user/RevoShare/cloudera/F8D3BB9C6CDE411CA0F48520656EFE19/IRO.iro' does not exist. Job has failed.
Error in rxCall("RxDTree", params) :
Error:  Error in rxCall("RxDTree", params) :

======  localhost.localdomain (Master HPA Process) has completed run at Fri May 23 16:51:50 2014  ======
Error in rxuHandleClusterJobTryFailure(retObject, hpcServerJob, autoCleanup,  :
Error completing job on cluster:
Error in rxCall("RxDTree", params) :

我在r symbol中编写了以下命令来检查revoscaler,但是没有加载。

> library(RevoScaleR)
> is.loaded("RevoScaleR")
[1] FALSE

你能给我一些建议吗?
谢谢。

s2j5cfk0

s2j5cfk01#

你的问题不是本机hadoop库。这只是一个警告。可能是hadoop类路径中没有revoscaler mapreduce jar。尝试将jar复制到hadoop lib文件夹中 scaleR-hadoop-0.1-SNAPSHOT.jar 也许是在 /usr/lib64/Revo-7.x/hadoop/scripts . 我不确定路径,因为我无法访问7.0安装。

相关问题