0. install xubuntu

we recommend to set username as "hadoop"

after installation, set user "hadoop" as administrator

sudo addgroup hadoop
sudo adduser --ingroup hadoop hadoop

打开/etc/sudoers文件

sudo gedit /etc/sudoers

在root  ALL=(ALL:ALL)  ALL下添加hadoop  ALL=(ALL:ALL)  ALL

1. install java

.解压java压缩包到usr/java(新建的文件夹)中。解压后就可使用

.配置环境变量。如下
在etc/profile 文件中。在最后添加如下内容
#set java environment
export JAVA_HOME=/usr/java/jdk1..0_67
export JRE_HOME=/usr/java/jdk1..0_67/jre
export PATH=$PATH:/usr/java/jdk1..0_67/bin
export CLASSPATH=./:/usr/java/jdk1..0_67/lib:/usr/java/jdk1..0_67/jre/lib .配置立即生效命令
source /etc/profile .检测是否配置成功
java -version 如果不行,重启linux

2. configure login in ssh without entering password

please operate under user "hadoop"

su - hadoop
sudo apt-get install openssh-server
sudo /etc/init.d/ssh start   cd ~/.ssh
ssh-keygen -t rsa -P ""  
cat ~/.ssh/id_rsa.pub>> ~/.ssh/authorized_keys  

3. install hadoop

. unzip hadoop.tar.gz into /usr/hadoop
  then, ensure user "hadoop" owns /usr/hadoop
  
sudo chown -R hadoop:hadoop hadoop  
. edit environment
2.1 gedit /etc/profile append these: export JAVA_HOME=/usr/java/
export JRE_HOME=/usr/java/jre
export HADOOP_INSTALL=/usr/hadoop
export PATH=$PATH:$JAVA_HOME/bin:$HADOOP_INSTALL/bin:$HADOOP_INSTALL/sbin
export CLASSPATH=./:/usr/java/lib:/usr/java/jre/lib 2.2 gedit /usr/hadoop/conf/hadoop-env.sh append these: # The java implementation to use. Required.
export JAVA_HOME=/usr/java
export HADOOP_INSTALL=/usr/hadoop
export PATH=$PATH:$JAVA_HOME/bin:$HADOOP_INSTALL/bin:$HADOOP_INSTALL/sbin . restart linux

4. test

hadoop@ms:~$
hadoop@ms:~$ java -version
java version "1.7.0_79"
Java(TM) SE Runtime Environment (build 1.7.0_79-b15)
Java HotSpot(TM) -Bit Server VM (build 24.79-b02, mixed mode)
hadoop@ms:~$ hadoop version
Hadoop 1.2.
Subversion https://svn.apache.org/repos/asf/hadoop/common/branches/branch-1.2 -r 1503152
Compiled by mattf on Mon Jul :: PDT
From source with checksum 6923c86528809c4e7e6f493b6b413a9a
This command was run using /usr/hadoop/hadoop-core-1.2..jar
hadoop@ms:~$

5. hadoop 伪分布式

编辑三个文件:
). core-site.xml: <configuration>
<property>
<name>fs.default.name</name>
<value>hdfs://localhost:9000</value>
</property>
<property>
<name>hadoop.tmp.dir</name>
<value>/usr/local/hadoop/tmp</value>
</property>
</configuration> ).hdfs-site.xml: <configuration>
<property>
<name>dfs.replication</name>
<value></value>
</property>
<property>
<name>dfs.name.dir</name>
<value>/usr/local/hadoop/datalog1,/usr/local/hadoop/datalog2</value>
</property>
<property>
<name>dfs.data.dir</name>
<value>/usr/local/hadoop/data1,/usr/local/hadoop/data2</value>
</property>
</configuration> ). mapred-site.xml: <configuration>
<property>
<name>mapred.job.tracker</name>
<value>localhost:</value>
</property>
</configuration> . 启动Hadoop到相关服务,格式化namenode, secondarynamenode, tasktracker:
hadoop@derekUbun:/usr/local/hadoop$ source /usr/local/hadoop/conf/hadoop-env.sh
hadoop@derekUbun:/usr/local/hadoop$ hadoop namenode -format

6*. install hbase[伪分布式]

. unzip hbase.tar.gz into /usr/hbase
  then, ensure user "hadoop" owns /usr/hbase
  
sudo chown -R hadoop:hadoop hbase . edit environment
2.1 gedit /etc/profile append these: export HBASE_HOME="/usr/hbase"
export PATH=$HBASE_HOME/bin:$PATH 2.2 gedit /usr/hbase/conf/hbase-site.xml append these: <property>
<name>hbase.rootdir</name>
<!-- 对应hadoop中hdfs的配置项 -->
<value>hdfs://localhost:9000/hbase</value>
</property>
<property>
<name>hbase.cluster.distributed</name>
<value>true</value>
</property>
<property>
<name>hbase.master.info.port</name>
<value></value>
</property> 2.3 gedit /usr/hbase/hbase-env.sh modify these: # The java implementation to use. Java 1.6 required.
export JAVA_HOME=/usr/java/ # Extra Java CLASSPATH elements. Optional.
export HBASE_CLASSPATH=/usr/hadoop/conf # Tell HBase whether it should manage it's own instance of Zookeeper or not.
export HBASE_MANAGES_ZK=true . restart linux

#. references

http://blog.csdn.net/zhaoyl03/article/details/8657104#

http://www.tuicool.com/articles/VZn6zi

http://blog.csdn.net/zhaoyl03/article/details/8657104#

http://blog.csdn.net/pdw2009/article/details/21261417

http://www.th7.cn/db/nosql/201510/134214.shtml

install hadoop on xubuntu的更多相关文章

  1. Hadoop学习日志- install hadoop

    资料来源 : http://www.tutorialspoint.com/hadoop/hadoop_enviornment_setup.htm Hadoop 安装 创建新用户 $ su passwo ...

  2. mac osx 系统 brew install hadoop 安装指南

    mac osx 系统 brew  install hadoop 安装指南   brew install hadoop 配置 core-site.xml:配置hdfs文件地址(记得chmod 对应文件夹 ...

  3. How to install Hadoop

    1.How to install Hadoop 3.0.0 http://blog.sina.com.cn/s/blog_4a1f59bf01010kx3.html 2.How to install ...

  4. [Spark] 00 - Install Hadoop & Spark

    Hadoop安装 Java环境配置 安装课程:安装配置 配置手册:Hadoop安装教程_单机/伪分布式配置_Hadoop2.6.0/Ubuntu14.04[依照步骤完成配置] jsk安装使用的链接中第 ...

  5. Steps to Install Hadoop on CentOS/RHEL 6---reference

    http://tecadmin.net/steps-to-install-hadoop-on-centosrhel-6/# The Apache Hadoop software library is ...

  6. yum install hadoop related client

    yum list avaliable hadoop\* yum list installed yum repolist repo is in /etc/yum.repos.d yum install ...

  7. install Hadoop

    Installing Java Hadoop runs on both Unix and Windows operating systems, and requires Java to beinsta ...

  8. How to install Hadoop Cluster

    https://dwbi.org/etl/bigdata/183-setup-hadoop-cluster https://www.linode.com/docs/databases/hadoop/h ...

  9. Install hadoop on windows(non-virtual machine, such cygwin)

    DownloadBefore starting make sure you have this two softwares Hadoop 2.7.1 Java – Jdk 1.7+ Extract d ...

随机推荐

  1. Access提示“操作必须使用一个可更新的查询”的解决办法

    问题:软件工程师开发了一个asp.net+access网站,本地调试增.删.改和查都没有异常.部署到服务器windows2008 R2的IIS上运行后,查询没有异常.可是在修改操作提交时,产生异常:提 ...

  2. jQuery选择器笔记

    1.$(this).hide() - 隐藏当前元素 $("p").hide() - 隐藏所有段落 $(".test").hide() - 隐藏所有 class= ...

  3. ArcGIS Engine开发之地图基本操作(4)

    ArcGIS Engine开发中数据库的加载 1.加载个人地理数据库数据 个人地理数据库(Personal Geodatabase)使用Miscrosoft Access文件(*.mdb)进行空间数据 ...

  4. APP级别处理未捕获异常

    前言: 项目APP有时候会出现Crash,然后就是弹出系统强制退出的对话框,点击关闭APP. 有的APP进行了处理,会发现,当程序出现异常的时候,会Toast一个提示"程序出现异常,3秒后将 ...

  5. Python 代码风格

    1 原则 在开始讨论Python社区所采用的具体标准或是由其他人推荐的建议之前,考虑一些总体原则非常重要. 请记住可读性标准的目标是提升可读性.这些规则存在的目的就是为了帮助人读写代码,而不是相反. ...

  6. Java 根据经纬度计算两点之间的距离

    package xxx.driver.business.utils; /** * <p>Represents a point on the surface of a sphere. (Th ...

  7. 在DBeaver中phoenix查询报错:org.apache.phoenix.exception.PhoenixIOException: The system cannot find the path specified

    环境:Phoenix:4.4,win7系统 问题:Phoenix在查询hbase时,报"系统找不到指定路径". 解决: 请参见 https://distcp.quora.com/C ...

  8. Js IP转数字

    <script type="text/javascript"> function d2h(d) { return d.toString(16) } function h ...

  9. linux 下安装web开发环境

    以下使用 linux centos系统 一.JDK的安装 1.下载jdk-8u111-linux-x64.tar.gz 2.解压该文件,将解压后的文件复制到 /usr/local/jdk1.7 目录下 ...

  10. plain framework 1 1.0.4 更新 稳定版发布

    PF由于各种因素迟迟不能更新,此次更新主要是更新了以往和上个版本出现的内存问题,该版本较为稳定,如果有用到的朋友请更新至此版本. PF 1.0.4 修复1.0.0.3更新后产生的内存问题,可能导致网络 ...