In my opinion, it was rather difficult to run the hadoop application without the hadoop command. You are better off using a haopa gang than java -jar.
I think you do not have hadoop environment in your machine. First, you need to make sure that chaos works well on your computer.
Personally, I prefer configuring to mapred-site.xml, core-site.xml, yarn-site.xml, hdfs-site.xml. I know a clear hadoop cluster installation tutorial in here
At this point, you can control hdfs in port 50070, a yarn cluster in port 8088, mapreduce history history in port 19888.
You must then prove that your hdfs and yarn environments work well. For the hdfs environment, you can try using the simple hdfs command, such as mkdir, copyToLocal, copyFromLocal, etc., And for the yarn environment, you can try the sample wordcount project.
After the hasoop environment, you can create your own mapreduce application (you can use any IDE). you might need this for a tutorial. compile it and make it in the bank.
open your terminal and run this command
hadoop jar <path to jar> <arg1> <arg2> ... <arg n>
hope this helps.
source share