Installation of Scala in Linux environment

Hi Scalalearners,

This material will give you some instruction of how to install and check scala in your machine. Check out the below steps to get scala in your machine

1. Download
Download the scala latest version from the official website of scala. Click the below link to reach scala website to download scala.
Scala Official website

Download Java from its offical website. Click the below link and download JDK in your machine.
Java official website

2. Untar Scala and Java
After downloading untar both Scala and Java. Use below command to untar it.
$ tar -zxvf scala-2.11.5.tgz
$ tar -zxvf Jdk1.7.0_45.tar.gz

3. Environmental setup
Now set the path of Java and scala on .bashrc file. And run .bashrc file. Follow below steps to do it.

$ vi .bashrc

export JAVA_HOME=/home/saravanan/jdk1.7.0_45
export SCALA_HOME=/home/saravanan/scala-2.11.5
export PATH=$HOME/bin:$JAVA_HOME/bin:$SCALA_HOME/bin:$PATH

$ source .bashrc

To check java version you can use the below command. This command will show you the version of java that is been installed in your system.
java -version

Now using terminal enter in to Scala folder. And lets check whether scala is working or not. Do the below steps, you will get scala shell then we can check scala installed in your machine.

$ cd scala-2.11.5
$ bin/scala
$ scala> println(“Hello,world!”)


Article written by DataDotz Team

DataDotz is a Chennai based BigData Team primarily focussed on consulting and training on technologies such as Apache Hadoop, Apache Spark , NoSQL(HBase, Cassandra, MongoDB), Search and Cloud Computing.

Note: DataDotz also provides classroom based Apache Kafka training in Chennai. The Course includes Cassandra , MongoDB, Scala and Apache Spark Training. For more details related to Apache Spark training in Chennai, please visit