SOLR Installation with Tomcat

SOLR Installation Guide

Solr Tutorials


Even though SOLR is written using Java, knowledge in Java is not required to install and use SOLR. It provides REST-like API for almost all functionalities. For this tutorial, we will install tomcat6 and SOLR in a Debian machine. Let us see the SOLR installation with Tomcat in Debian or Ubuntu.

tomcat6 installation

We will use the Debian native package manager to install tomcat6. Open terminal and use the following command.

sudo apt-get install tomcat6 tomcat6-admin

To validate the installation of tomcat6, open the following URL in your favorite browser


If you are installing a remote machine, use the IP address instead of localhost.

SOLR Installation

We will install the latest version of SOLR (as of this writing, the latest version is 4.2). Open a Terminal and run the following commands which should install SOLR application in tomcat.

tar xvfz solr-4.2.0.tgz
cd solr-4.2.0
cp dist/solr-4.2.0.war /var/lib/tomcat6/webapps/solr.war
cp -fr example/solr /var/lib/tomcat6/
chown -R tomcat6:tomcat6 /var/lib/tomcat6/solr

The solr application should get auto deployed in tomcat. To be safe, restart the tomcat which should load the solr application.

sudo /etc/init.d/tomcat6 restart

Once restart is complete, Check the installation by opening the below URL in your browser.


You should be greeted with SOLR welcome page. This is part of the example application which we copied before. Next you can either create multiple cores in same SOLR instance or configure SOLR for Search or Faceting.

This post is part of series of posts constituting a SOLR tutorial.