????????

???????????е?????????MRUnit?????????????????????MapReduce???е??????????????????????????Щ???????????????е???????????????????????MapReduce??????м???????????м????????????????ν?MapReduce?????hadoop???????????????

???????????

??????windows?????????
???????jdk?????????????JAVA_HOME?jdk?????
???????Cygwin??????????????????openssh–Net?????????cygwin/bin??????????path??
???????ssh????cygwin?????У???????????????
???????sshd:$ssh-host-config
???????sshd????$netstartsshd
??????????localhost??$sshlocalhost
?????????????hadoop?汾?????????????????????0.20.2?汾??
???????????????conf/hadoop-env.sh?????JAVA_HOME?jdk???????

?????????Windows?????μ?Hadoop????????????????????л???????MapReduce???????????maven??assembly???????????????
???????£?

????<build>
????<plugins>
????<plugin>
????<artifactId>maven-assembly-plugin</artifactId>
????<configuration>
????<descriptorRefs>
????<descriptorRef>jar-with-dependencies</descriptorRef>
????</descriptorRefs>
????</configuration>
????</plugin>
????</plugins>
????</build>

??????pom.xml??????????????????mvnassembly:assembly????????????

????????????

???????

?????????????????????С?????????hadoop?????????????????????hadoop???????????????????????reducer??

???????з????

????$bin/hadoopjar--configstandalonepath/xx.jarWordCountinputoutput

????????

??????–config?????????????????????????????????????????standalone????0.20.2?汾???????п?????????????????????????

????WordCount????????????main?????????????а???????????????
????Input??????·?????????????
????Output????????????????job??豣????????????????????

????α????????

???????

????????????????hadoop???н??????NameNode??DataNode??TaskTracker??JobTracker??SecondaryNameNode???????????hadoop????????