1.å¦ä½è¿è¡èªå¸¦wordcount-Hadoop2
2.å¦ä½è¿è¡èªå¸¦wordcount
å¦ä½è¿è¡èªå¸¦wordcount-Hadoop2
查询qq业务定制源码1.æ¾å°examplesä¾åæ们éè¦æ¾æè¿ä¸ªä¾åçä½ç½®ï¼é¦å éè¦æ¾å°ä½ çhadoopæ件夹ï¼ç¶åä¾ç §ä¸é¢è·¯å¾ï¼/hadoop/share/hadoop/mapreduce第äºæ¥ï¼æ们éè¦éè¦åä¸ä¸è¿è¡éè¦çå·¥ä½ï¼æ¯å¦è¾å ¥è¾åºè·¯å¾ï¼ä¸ä¼ ä»ä¹æ件çã1.å å¨HDFSå建å 个æ°æ®ç®å½ï¼1.hadoopfs-mkdir-p/data/wordcount2.hadoopfs-mkdir-p/output/2.ç®å½/data/wordcountç¨æ¥åæ¾Hadoopèªå¸¦çWordCountä¾åçæ°æ®æ件ï¼è¿è¡è¿ä¸ªMapReduceä»»å¡çç»æè¾åºå°/output/wordcountç®å½ä¸ãé¦å æ°å»ºæ件inputWordï¼1.vi/usr/inputWordæ°å»ºå®æ¯ï¼æ¥çå 容ï¼å°æ¬å°æ件ä¸ä¼ å°HDFSä¸ï¼å¯ä»¥æ¥çä¸ä¼ åçæ件æ åµï¼æ§è¡å¦ä¸å½ä»¤ï¼1.hadoopfs-ls/data/wordcountå¯ä»¥çå°ä¸ä¼ å°HDFSä¸çæ件ãç»å½å°Webæ§å¶å°ï¼è®¿é®é¾æ¥å¯ä»¥çå°ä»»å¡è®°å½æ åµã
查询qq业务定制源码å¦ä½è¿è¡èªå¸¦wordcount
查询qq业务定制源码ãã1.æ¾å°examplesä¾å
查询qq业务定制源码ããæ们éè¦æ¾æè¿ä¸ªä¾åçä½ç½®ï¼é¦å éè¦æ¾å°ä½ çhadoopæ件夹ï¼ç¶åä¾ç §ä¸é¢è·¯å¾ï¼
查询qq业务定制源码ãã/hadoop/share/hadoop/mapreduceä¼çå°å¦ä¸å¾ï¼
查询qq业务定制源码ããhadoop-mapreduce-examples-2.2.0.jar
查询qq业务定制源码ãã第äºæ¥ï¼
查询qq业务定制源码ããæ们éè¦éè¦åä¸ä¸è¿è¡éè¦çå·¥ä½ï¼æ¯å¦è¾å ¥è¾åºè·¯å¾ï¼ä¸ä¼ ä»ä¹æ件çã
查询qq业务定制源码ãã1.å å¨HDFSå建å 个æ°æ®ç®å½ï¼
查询qq业务定制源码ããhadoop fs -mkdir -p /data/wordcount
查询qq业务定制源码ããhadoop fs -mkdir -p /output/
查询qq业务定制源码ãã2.ç®å½/data/wordcountç¨æ¥åæ¾Hadoopèªå¸¦çWordCountä¾åçæ°æ®æ件ï¼è¿è¡è¿ä¸ªMapReduceä»»å¡çç»æè¾åºå°/output/wordcountç®å½ä¸ã
查询qq业务定制源码ããé¦å æ°å»ºæ件inputWordï¼
查询qq业务定制源码ããvi /usr/inputWord
查询qq业务定制源码ããæ°å»ºå®æ¯ï¼æ¥çå 容ï¼
查询qq业务定制源码ããcat /usr/inputWord
查询qq业务定制源码ããå°æ¬å°æ件ä¸ä¼ å°HDFSä¸ï¼
查询qq业务定制源码ããhadoop fs -put /usr/inputWord /data/wordcount/
查询qq业务定制源码ããå¯ä»¥æ¥çä¸ä¼ åçæ件æ åµï¼æ§è¡å¦ä¸å½ä»¤ï¼
查询qq业务定制源码ããhadoop fs -ls /data/wordcount
查询qq业务定制源码ããå¯ä»¥çå°ä¸ä¼ å°HDFSä¸çæ件ã
查询qq业务定制源码ããéè¿å½ä»¤
查询qq业务定制源码ããhadoop fs -text /data/wordcount/inputWord
查询qq业务定制源码ããçå°å¦ä¸å 容ï¼
查询qq业务定制源码ãã
查询qq业务定制源码ããä¸é¢ï¼è¿è¡WordCountä¾åï¼æ§è¡å¦ä¸å½ä»¤ï¼
查询qq业务定制源码ããhadoop jar /usr/hadoop/share/hadoop/mapreduce/hadoop-mapreduce-examples-2.2.0.jar wordcount /data/wordcount /output/wordcount
查询qq业务定制源码ãã
查询qq业务定制源码ããå¯ä»¥çå°æ§å¶å°è¾åºç¨åºè¿è¡çä¿¡æ¯
查询qq业务定制源码ããæ¥çç»æï¼æ§è¡å¦ä¸å½ä»¤ï¼
查询qq业务定制源码ããhadoop fs -text /output/wordcount/part-r-
查询qq业务定制源码ç»ææ°æ®ç¤ºä¾å¦ä¸ï¼
查询qq业务定制源码ç»å½å°Webæ§å¶å°ï¼è®¿é®é¾æ¥http.//master:/å¯ä»¥çå°ä»»å¡è®°å½æ åµã
查询qq业务定制源码