Install Spark In Ubuntu
文章目录
Installation
You need three things to run spark in Ubuntu. Java Scala & Spark. So download them as follow:
NOTICE: Spark has 2 types, spark & spark-hadoop, if you need spark-stream, download spark-hadoop.
After you get those tgz files, release them under folder /opt. Then edit /etc/profile as follow:
1 | #JDK environment variable |
NOTICE: If you install java before, just make sure JAVA_HOME JRE_HOME CLASSPATH PATH be configurated correct.
Then restart computer to make configuration work forever or run command
1 | source /etc/profile |
to make it work temporary.
Test
Switch to /opt/spark-hadoop in terminal. Run
1 | ./bin/spark-shell |
, then you will get spark lauch information and scala command.