1.進入hadoop目錄
cd /home/jason/hadoop-1.0.1/
2.格式化DFS文件系統
hadoop namenode -format
3.啓動hadoop
bin/start-all.sh
4.建立input目錄
hadoop fs -mkdir /input
5.上傳一個文本文件到hdfs
hadoop fs -put LICENSE.txt /input
6.運行wordcount例子
hadoop jar hadoop-examples-1.0.1.jar wordcount /input /output
7.查看結果
hadoop fs -cat /output/part-r-00000
node