首页 » Ubuntu » Ubuntu:Spark安装

Ubuntu:Spark安装

原文 http://blog.csdn.net/ShellDawn/article/details/79129842

2018-01-23 02:02:00阅读(428)

创建hadoop用户:

sudo user add -m Hadoop -s /bin/bash
sudo passed hadoop
sudo adduser Hadoop sudo

登陆hadoop用户

sudo apt-get update
sudo apt-get install vim
sudo apt-get install openssh-server
ssh localhost
exit
cd ~/.ssh/
ssh-keygen -t rsa
cat ./id_rsa.pub >> ./authorized_keys

安装java环境

tar -zxvf jdk-7u79-linux-x64.tar.gz
sudo mv ~/Downloads/jdk1.7.0_79 /opt/
vim ~/.bashrc 
#export JAVA_HOME=/opt/jdk1.7.0_79
source ~/.bashrc
sudo update-alternatives --install /usr/bin/java java /opt/jdk1.7.0_79/bin/java 700
sudo update-alternatives --install /usr/bin/javac javac /opt/jdk1.7.0_79/bin/javac 700
sudo update-alternatives --install /usr/bin/jar jar /opt/jdk1.7.0_79/bin/jar 700
echo $JAVA_HOME
java -version
$JAVA_HOME/bin/java -version

安装hadoop2
选择stable文件夹下不带src的tar包
下载链接
http://mirror.bit.edu.cn/apache/hadoop/common/或者
http://mirrors.cnnic.cn/apache/hadoop/common/

sudo tar -zxf ~/Downloads/hadoop-2.9.0.tar.gz -C /usr/local
cd /usr/local/
sudo mv ./hadoop-2.6.0/ ./hadoop
sudo chown -R Hadoop ./hadoop
cd /usr/local/hadoop
./bin/hadoop version

最新发布

CentOS专题

关于本站

5ibc.net旗下博客站精品博文小部分原创、大部分从互联网收集整理。尊重作者版权、传播精品博文,让更多编程爱好者知晓!

小提示

按 Ctrl+D 键,
把本文加入收藏夹