Hadoop学习笔记-入门伪分布式配置(Mac OS,0.21.0,Eclipse 3.6)
说实话,Hadoop的入门学习配置比我想像中的要简单,当然,Hadoop本身是比较复杂的(那么厚厚的一本书就能说明问题)。开发环境:Mac OS(Unix)
Hadoop版本:0.21.0
Eclipse版本: 3.6.0
第一步:下载Hadoop
下载地址:http://hadoop.apache.org/common/releases.html#Download
注意,当前21版本的Hadoop是不稳定、不支持并且不保证安全的最新版本。
第二步:配置Hadoop
将下载的Hadoop压缩文件解压缩,找到conf目录,打开core-site.xml,修改代码如下所示:
<?xml version="1.0"?><?xml-stylesheet type="text/xsl" href="configuration.xsl"?><!-- Put site-specific property overrides in this file. --><configuration> <property> <name>fs.default.name</name> <value>localhost:9000</value> </property></configuration>
找到mapred-site.xml修改代码如下所示:
<?xml version="1.0"?><?xml-stylesheet type="text/xsl" href="configuration.xsl"?><!-- Put site-specific property overrides in this file. --><configuration><property> <name>mapred.job.tracker</name> <value>localhost:9001</value></property></configuration>
找到hdfs-site.xml修改代码如下所示:
<?xml version="1.0"?><?xml-stylesheet type="text/xsl" href="configuration.xsl"?><!-- Put site-specific property overrides in this file. --><configuration><property> <name>dfs.replication</name> <value>1</value></property></configuration>
找到hadoop-env.sh打开,加入以下配置
<div class="quote_title">引用
页:
[1]