* Prerequisite
- Ubuntu Linux 11.10
1. JDK 1.6, must be installed
- download JDK ( http://www.oracle.com/technetwork/java/javase/downloads/index.html , 32bit, tar.gz )
- uncompress JDK
$ tar xvf jdk-7u3-linux-i586.tar.gz
- move the JDK directory
$ sudo mv ./jdk1.7.0_03 /usr/lib/jvm/jdk1.7.0
- Create symbolic link for java
$ sudo update-alternatives --install "/usr/bin/java" "java" "/usr/lib/jvm/jdk1.7.0/bin/java" 1
$ sudo update-alternatives --install "/usr/bin/javac" "javac" "/usr/lib/jvm/jdk1.7.0/bin/javac" 1
$ sudo update-alternatives --install "/usr/bin/javaws" "javaws" /usr/lib/jvm/jdk1.7.0/bin/javaws" 1
- Configure basic java
$ sudo update-alternatives --config java
$ sudo update-alternatives --config javac
$ sudo update-alternatives --config javaws
- Confirm java version
$ java -version
$ javac -version
- Set up a mozilla plugin
$ ln -s /usr/lib/jvm/jdk1.7.0/jre/lib/i386/libnpjp2.so ~/.mozilla/plugins/
2. Installing Software
- install ssh
$ sudo apt-get install ssh
- install rsync
$ sudo apt-get install rsync
3. Install the newest Hadoop distribution
- download Hadoop ( http://www.apache.org/dyn/closer.cgi/hadoop/common/ , 1.0.2, tar.gz )
- Uncompress
$ tar xvf hadoop-1.0.2.tar.gz
- Move directory
$ mv ./hadoop-1.0.2~/hadoop
- Edit JAVA_HOME environment
$ vi ~/hadoop/etc/hadoop-env.sh
- Try the Hadoop
$ cd ~/hadoop
$ bin/hadoop
- Confirm the Hadoop version
$ bin/hadoop version
4. Standalone Operation
- Prepare input files and Start the Hadoop
$ mkdir input
$ cp conf/*.xml input
$ bin/hadoop jar hadoop-examples-1.0.2.jar grep input output 'dfs[a-z.]+'
- Confirm result
$ cat output/*