Support Questions
Find answers, ask questions, and share your expertise

unable to load hadoop-mapreduce-examples

unable to load hadoop-mapreduce-examples

Contributor

hadoop-mapreduce-examples.jar file failed to run with below error.

[yarn@namenode hadoop-mapreduce]$ id

uid=514(yarn) gid=500(hadoop) groups=500(hadoop)

[yarn@namenode hadoop-mapreduce]$ hdfs jar /usr/hdp/2.3.0.0-2557/hadoop-mapreduce/hadoop-mapreduce-examples.jar randomwriter /users/mapred-examples Error: Could not find or load main class jar

Please advise.

Thank you,

Sachin A

5 REPLIES 5

Re: unable to load hadoop-mapreduce-examples

Super Guru

Can you please run this instead for the test

hadoop jar /usr/hdp/current/hadoop-mapreduce-client/hadoop-mapreduce-examples.jar 
            randomwriter -Dtest.randomwrite.total_bytes=10000000 /users/mapred-examples/

Re: unable to load hadoop-mapreduce-examples

Contributor

Thanks for your prompt response. The give command worked as expected. One more question, where can I find the log file for the submitted job?

Thank you,

Sachin A

Re: unable to load hadoop-mapreduce-examples

Contributor

Thanks for your prompt response. The give command worked as expected. One more question, where can I find the log file for the submitted job?

Thank you,

Sachin A

Re: unable to load hadoop-mapreduce-examples

Expert Contributor

You have multiple options to find the log:

  • When submitting the job with the above command, some log gets printed to the standard output (this contains the application ID, MapReduce progress and status, some job output, etc.)
  • You can use the Resource Manager UI: <RM.host>:8088/cluster/apps -> choose your application11596-rm-ui-app.png
    • On this screen you can choose the Logs link next to the appattempts
  • You can use the yarn logs command line utility
yarn logs -applicationId application_1485119335316_0032
  • The actual log files are under the directories defined by the yarn.nodemanager.log-dirs key

Re: unable to load hadoop-mapreduce-examples

New Contributor

if the same issue is with cloudera

then check jar files in the following folder
/opt/cloudera/parcels/CDH-5.12.2-1.cdh5.12.2.p0.4/jars/hadoop-examples.jar