hadoop wordcout

 

./bin/hadoop fs -ls /    查看目录

./bin/hadoop fs -rmr /wordcout  删除

./bin/hadoop fs -mkdir /wordcount  创建目录

./bin/hadoop fs -mkdir /wordcount/input

./bin/hadoop fs -mkdir /wordcount/output

./bin/hadoop fs -ls -R /wordcount   递归查看目录

./bin/hadoop fs -put  ./NOTICE.txt /wordcount/input/    上传一个文件

./bin/hadoop jar share/hadoop/mapreduce/hadoop-mapreduce-examples-2.6.5.jar wordcount /wordcount/input /wordcount/output/result1  执行wordcount命令

./bin/hadoop fs -cat /wordcount/output/result2/part-r-00000   查看结果