问题描述
我正在尝试运行 Hadoop在行动中的书第15页中所指出的示例.这是需要运行的命令:
I am trying to run an example as it is pointed in Hadoop in Action book page 15.this is the command that needs to be run :
bin/hadoop jar hadoop-*-examples.jar
但我收到此错误
"Error: Could not find or load main class org.apache.hadoop.util.RunJar"
似乎是类路径问题之类的.有人可以指出一些准则吗?
It seems like a classpath issue or something. Can someone point out some guideline ?
实际上,我无法运行任何hadoop命令,例如version,fs,jar ...等.
Actually I am not able to run any of hadoop commands like version, fs, jar ... and so on .. !
注意:我正在使用Windows.
NOTE: I am using windows.
推荐答案
[已编辑]好的,我的阅读速度太快了,您提到您也无法运行hadoop fs
命令.我想您可能会错过一些配置或根本没有启动服务.尝试遵循此教程一步一步来.
Okay, i was reading too fast, you mentioned you were not able to run hadoop fs
commands as well. I guess you might miss a few congifurations or haven't start the services at all. Try following this tutorial step by step.
您将需要输入类名,例如:
you will need to pass in the class name, for example:
bin/hadoop jar hadoop-*-examples.jar org.apache.hadoop.examples.WordCount [input] [output]
这篇关于“错误:找不到或加载主类org.apache.hadoop.util.RunJar"是什么意思?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!