Monday, November 22, 2010

Installing and running hadoop on windows xp in standalone mode

Prereqs : have cygwin installed
2. unpack the file hadoop-0.20.2.tar.gz.gz in C:/ (using tar xvf filename)
3. Add the following to conf/hadoop-env.sh in the unpacked folder : 
export JAVA_HOME=/cygdrive/c/Java/jdk1.6.0_23
(assuming that C:/Java/jdk1.6.0_23/bin contains javac.exe and other binaries)

5. Unpack the file tomwhite-hadoop-book-32dae01.tar.gz
6. in the unpacked folder : cd ch02/src/main/java
7. mkdir -p build/classes
8. $ javac -verbose -classpath C:\\hadoop-0.20.2\\hadoop-0.20.2-core.jar MaxTemperature*.java -d build/classes
9. export HADOOP_CLASSPATH=build/classes
10. hadoop MaxTemperature ../../../../input/ncdc/sample.txt output

your output is in output folder

No comments:

Blog Archive