How to install Apache Spark on Ubuntu?

How to install Apache Spark on Ubuntu?

This tutorial is for Ubuntu Users. For Windows users, you can directly install Apache Spark from the below link and start it directly on Powershell.

Download the latest Spark from Apache Website https://spark.apache.org/downloads.html

Open the download folder in the terminal and run the below command to extract.

tar xvf spark-3.3.1-bin-hadoop3.tgz

Now move the extracted folder to /opt/spark

sudo mv spark-3.3.1-bin-hadoop3/ /opt/spark

Add path to .bashrc file

export SPARK_HOME=/opt/spark export PATH=$PATH:$SPARK_HOME/bin:$SPARK_HOM/sbin

and refresh source

source ~/.bashrc

Now you will be able to run all spark commands from the terminal.

For example, To start the spark server with master and worker-run the below command and then enter jps and open http://localhost:8080 to see the spark GUI

start-all.sh

To run spark-shell REPL directly in the terminal run the below command

spark-shell

Let's Connect on:

Tags :
Share :

Related Posts

How to create a simple server with Python Flask?

How to create a simple server with Python Flask?

Flask is one of the popular and simple-to-learn frameworks of Python to build a full-stack web app. This tutorial is the first part of the complete full-stack web app, we are going to build using Fl

read more
How to open VS Code Live Server Extension web page on Mobile?

How to open VS Code Live Server Extension web page on Mobile?

Hello guys, today I am going to write about a very productive topic if you have started learning as a Web developer and using one of our favorite Code editors as a VS Code. So, if you have ever writ

read more