Win7下Spark环境搭建


1.spark下载

网站:http://spark.apache.org/downloads.html
我下载的版本是 spark-2.2.0-bin-hadoop2.7.tgz,表明下载的hadoop需要时2.7.x版本的

2.scala下载

3.hadoop下载

网站:http://www.apache.org/dyn/closer.cgi/hadoop/core/,选择与spark一致的版本

4.winutils.exe下载

网站:https://github.com/steveloughran/winutils选择与hadoop一致的版本,然后将bin下的文件覆盖已安装的hadoop目录下的bin

5.环境变量

 
   
SCALA_HOME  : C:\Program Files (x86)\scala2.11.7;
JAVA_HOME   : C:\Program Files\Java\jdk1.8.0_51
HADOOP_HOME : C:\Hadoop\winutils-master\hadoop-2.7.1
SPARK_HOME  : C:\Hadoop\spark-2.2.0-bin-hadoop2.7
PATH    : %JAVA_HOME%\bin;%SCALA_HOME%\bin;%HADOOP_HOME%\bin;%SPARK_HOME%\bin
参考网站: https://stackoverflow.com/questions/44386153/why-does-spark-shell-fail-with-error-not-found-value-spark

你可能感兴趣的:(JAVA)