1, 安装过程
参考http://wiki.apache.org/hadoop/MountableHDFS
和
http://savagegarden.iteye.com/blog/1170752
2, install ant 1.8
3, cd $HADOOP_HOME/common, 执行ant mvn-install
4, cd $HADOOP_HOME/hdfs, 执行ant compile-c++-libhdfs -Dlibhdfs=1 -Dcompile.c++=1 或ant compile -
Dcompile.c++=true -Dlibhdfs=true
5, 解决Hadoop0.21.0 HDFS/MapReduce编译错误(ivy-resolve-common does not find hadoop-common)
参考http://www.iteye.com/topic/1070647
6, 解决lib not found错误
参考http://blog.naver.com/PostView.nhn?blogId=wja30&logNo=100123240782
BUILD FAILED/home/cavc/hadoop-0.21.0/common/build.xml:407: The following error occurred while executing
this line:/home/cavc/hadoop-0.21.0/common/src/contrib/build.xml:30: The following error occurred while
executing this line:/home/cavc/hadoop-0.21.0/common/src/contrib/build-contrib.xml:137:
/home/cavc/hadoop-0.21.0/common/lib not found.
7, cd $HADOOP_HOME/hdfs, 执行ant package
8, 解决错误,
/root/hadoop-0.21.0/hdfs/build.xml:810: 'java5.home' is not defined. Forrest requires Java 5. Please
pass -Djava5.home=<base of Java 5 distribution> to Ant on the command-line.
参考http://www.hadoopor.com/viewthread.php?tid=941
9, 重新执行ant package,
ant package -Djava5.home=/root/dev/jdk1.5.0_22 -Dforrest.home=$FORREST_HOME
10,执行
ant compile-contrib -Dlibhdfs=1 -Dfusedfs=1
11,
ln -s /root/hadoop-0.21.0/hdfs/build/contrib/fuse-dfs/fuse_dfs_wrapper.sh /usr/local/bin
ln -s /root/hadoop-0.21.0/hdfs/build/contrib/fuse-dfs/fuse_dfs /usr/local/bin
mkdir /export/hdfs (or wherever you want to mount it)
fuse_dfs_wrapper.sh dfs://localhost:9000 /root/download/hdfs -d
and from another terminal, try ls /export/hdfs
1,下载linux内核源代码
yum -y install kernel-devel
2,下载fuse2.8.6
http://sourceforge.net/projects/fuse/files/fuse-2.X/2.8.6/
3,解决fuse--module fuse not found错误
参考http://morgan363.iteye.com/blog/757228,更新kernel
chmod +x /root/download/hadoop-0.21.0/hdfs/build/contrib/fuse-dfs/fuse_dfs_wrapper.sh
chmod +x /root/download/hadoop-0.21.0/hdfs/build/contrib/fuse-dfs/fuse_dfs
ln -s /root/download/hadoop-0.21.0/hdfs/build/contrib/fuse-dfs/fuse_dfs_wrapper.sh /usr/local/bin
ln -s /root/download/hadoop-0.21.0/hdfs/build/contrib/fuse-dfs/fuse_dfs /usr/local/bin/
参考http://wiki.apache.org/hadoop/MountableHDFS
和
http://savagegarden.iteye.com/blog/1170752
2, install ant 1.8
3, cd $HADOOP_HOME/common, 执行ant mvn-install
4, cd $HADOOP_HOME/hdfs, 执行ant compile-c++-libhdfs -Dlibhdfs=1 -Dcompile.c++=1 或ant compile -
Dcompile.c++=true -Dlibhdfs=true
5, 解决Hadoop0.21.0 HDFS/MapReduce编译错误(ivy-resolve-common does not find hadoop-common)
参考http://www.iteye.com/topic/1070647
6, 解决lib not found错误
参考http://blog.naver.com/PostView.nhn?blogId=wja30&logNo=100123240782
BUILD FAILED/home/cavc/hadoop-0.21.0/common/build.xml:407: The following error occurred while executing
this line:/home/cavc/hadoop-0.21.0/common/src/contrib/build.xml:30: The following error occurred while
executing this line:/home/cavc/hadoop-0.21.0/common/src/contrib/build-contrib.xml:137:
/home/cavc/hadoop-0.21.0/common/lib not found.
7, cd $HADOOP_HOME/hdfs, 执行ant package
8, 解决错误,
/root/hadoop-0.21.0/hdfs/build.xml:810: 'java5.home' is not defined. Forrest requires Java 5. Please
pass -Djava5.home=<base of Java 5 distribution> to Ant on the command-line.
参考http://www.hadoopor.com/viewthread.php?tid=941
9, 重新执行ant package,
ant package -Djava5.home=/root/dev/jdk1.5.0_22 -Dforrest.home=$FORREST_HOME
10,执行
ant compile-contrib -Dlibhdfs=1 -Dfusedfs=1
11,
ln -s /root/hadoop-0.21.0/hdfs/build/contrib/fuse-dfs/fuse_dfs_wrapper.sh /usr/local/bin
ln -s /root/hadoop-0.21.0/hdfs/build/contrib/fuse-dfs/fuse_dfs /usr/local/bin
mkdir /export/hdfs (or wherever you want to mount it)
fuse_dfs_wrapper.sh dfs://localhost:9000 /root/download/hdfs -d
and from another terminal, try ls /export/hdfs
1,下载linux内核源代码
yum -y install kernel-devel
2,下载fuse2.8.6
http://sourceforge.net/projects/fuse/files/fuse-2.X/2.8.6/
3,解决fuse--module fuse not found错误
参考http://morgan363.iteye.com/blog/757228,更新kernel
chmod +x /root/download/hadoop-0.21.0/hdfs/build/contrib/fuse-dfs/fuse_dfs_wrapper.sh
chmod +x /root/download/hadoop-0.21.0/hdfs/build/contrib/fuse-dfs/fuse_dfs
ln -s /root/download/hadoop-0.21.0/hdfs/build/contrib/fuse-dfs/fuse_dfs_wrapper.sh /usr/local/bin
ln -s /root/download/hadoop-0.21.0/hdfs/build/contrib/fuse-dfs/fuse_dfs /usr/local/bin/