下面关于Hadoop的文章您也可能喜欢,不妨看看:
Ubuntu14.04下Hadoop2.4.1单机/伪分布式安装配置教程 http://www.linuxidc.com/Linux/2015-02/113487.htm
CentOS安装和配置Hadoop2.2.0 http://www.linuxidc.com/Linux/2014-01/94685.htm
Ubuntu 13.04上搭建Hadoop环境 http://www.linuxidc.com/Linux/2013-06/86106.htm
Ubuntu 12.10 +Hadoop 1.2.1版本集群配置 http://www.linuxidc.com/Linux/2013-09/90600.htm
Ubuntu上搭建Hadoop环境(单机模式+伪分布模式) http://www.linuxidc.com/Linux/2013-01/77681.htm
Ubuntu下Hadoop环境的配置 http://www.linuxidc.com/Linux/2012-11/74539.htm
单机版搭建Hadoop环境图文教程详解 http://www.linuxidc.com/Linux/2012-02/53927.htm
0、系统环境安装
1、同步机器时间
yum install -y ntp #安装时间服务
ntpdate us.pool.ntp.org #同步时间
vi /etc/sysconfig/network-scripts/ifcfg-eth0
DEVICE=eth0
IPADDR=192.168.8.101
NETMASK=255.255.255.0
GATEWAY=192.168.8.2
HWADDR=00:0C:29:56:63:A1
TYPE=Ethernet
UUID=ecb7f947-8a93-488c-a118-ffb011421cac
ONBOOT=yes
NM_CONTROLLED=yes
BOOTPROTO=none
service network restart
ifconfig eth0
eth0 Link encap:EthernetHWaddr00:0C:29:6C:20:2B
inet addr:192.168.8.101Bcast:192.168.8.255Mask:255.255.255.0
inet6 addr: fe80::20c:29ff:fe6c:202b/64Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500Metric:1
RX packets:777 errors:0 dropped:0 overruns:0 frame:0
TX packets:316 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:70611(68.9KiB) TX bytes:49955(48.7KiB)
rm -f /etc/udev/rules.d/70-persistent-net.rule
vim /etc/sysconfig/network-scripts/ifcfg-eth0
reboot
3、设置主机名
vi /etc/sysconfig/network
NETWORKING=yes
HOSTNAME=hadoop01
NETWORKING_IPV6=no
vi /etc/hosts
127.0.0.1 localhost
192.168.8.101 hadoop01 192.168.8.102 hadoop02 192.168.8.103 hadoop03 192.168.8.104 hadoop04 192.168.8.105 hadoop05 192.168.8.106 hadoop06
关闭ipv6
1、查看系统是否开启ipv6
a)通过网卡属性查看
命令:ifconfig
注释:有 “inet6 addr:。。。。。。。“ 的表示开启了ipv6功能
b)通过内核模块加载信息查看
命令:lsmod | grep ipv6
2、ipv6关闭方法
在/etc/modprobe.d/dist.conf结尾添加
alias net-pf-10 off
alias ipv6 off
可用vi等编辑器,也可以通过命令:
cat <<EOF>>/etc/modprobe.d/dist.conf
alias net-pf-10 off
alias ipv6 off
EOF
关闭防火墙
chkconfig iptables stop
chkconfig iptables off
改好后重启服务器:
reboot
4、安装JDK
vi /etc/proflie
export JAVA_HOME=/soft/jdk1.7.0_80/
export PATH=$JAVA_HOME/bin:$JAVA_HOME/jre/bin:$PATH
source /etc/profile
更多详情见请继续阅读下一页的精彩内容: http://www.linuxidc.com/Linux/2016-01/127701p2.htm