Prerequisites
Hardware requirements:
Local machine
RAM 8 gb or above
Software requirements:
VMware Workstation , Version : 16 pro
Download the software from given link :- https://prwatech.in/blog/software-installation/vmware-workstation-installation/
Ubuntu , Version:18.04 :- https://prwatech.in/blog/software-installation/vmware-workstation-installation/
Programming languages: Linux
Learn Linux : https://prwatech.in/blog/linux/linux-architecture/
1.Install java
Command: $sudo apt-get install openjdk-8-jdk
![](https://prwatech.in/blog/wp-content/uploads/2021/03/image-281.png)
2. check the java version whether it is installed
![](https://prwatech.in/blog/wp-content/uploads/2021/03/image-282.png)
3. Download spark in terminal by using following command :
wget https://archive.apache.org/dist/spark/spark-2.4.0/spark-2.4.0-bin-hadoop2.7.tgz
![](https://prwatech.in/blog/wp-content/uploads/2021/03/image-283.png)
4. Untar the file using following command :
tar -xvf spark-2.4.0-bin-hadoop2.7.tgz
![](https://prwatech.in/blog/wp-content/uploads/2021/03/image-284.png)
5. Edit bashrc file
![](https://prwatech.in/blog/wp-content/uploads/2021/03/image-285.png)
6. Add the following lines in bashrc file
export SPARK_HOME=/home/user/spark-2.4.0-bin-hadoop2.7
export PATH=$PATH:$SPARK_HOME/bin
![](https://prwatech.in/blog/wp-content/uploads/2021/03/image-286.png)
7. Save the bashrc file
![](https://prwatech.in/blog/wp-content/uploads/2021/03/image-287.png)
8. Run spark-shell from the bin directory of spark
![](https://prwatech.in/blog/wp-content/uploads/2021/03/image-288.png)
9. Spark installation is completed now you can write query
![](https://prwatech.in/blog/wp-content/uploads/2021/03/image-289.png)