Can some one explain me this syntax ,
bin/hadoop jar hadoop*examples*.jar wordcount /user/hpuser/testHadoop /user/hpuser/testHadoop-output
Why are we using jar soon after bin/hadoop What does hadoop*examples*.jar means..? Do wordcount is name of the job, or we asking hadoop to count no of words..?
http://www.michael-noll.com/tutorials/running-hadoop-on-ubuntu-linux-single-node-cluster/
jar
Runs a jar file. Users can bundle their Map Reduce code in a jar file and execute it using this command.
Usage:
hadoop jar <jar> [mainClass] args...
jar
is the command. hadoop*examples*.jar
is the jar file. WordCount
is the main class. The rest are arguments passed to the WordCount.main()
function:
public static void main(String[] args) throws Exception {
int res = ToolRunner.run(new Configuration(), new WordCount(), args);
System.exit(res);
}