Installation & Configuration of Apache Solr

Before start with the installation of apache solr. Let's understand the working of apache solr. In this article, I am going to demonstrate the installation and integration part of solr with Magento.

Apache Solr:

Apache Solr is an open source application use for the search index.

Apache Solr is basically working as Full-text Search engine.

Solr provides the XML interface and JSON API with which search application can be work.

Solr is written on Java Platform.

It is very stable and reliable application when you need any application for the search index.

Apache Solr running on default port 8983.

Apache solr can be used or integrate with multiple platforms like Magento, drupaletc. In this article, we will see the integration of apache solr with Magento platform.

You need to install below packages on the server.

Apache Solr 3.6.X

JAVA 7.x or 8

We have using solr 3.6 version. Reason to use this version is because it is a stable solr version and compatible with Magento platform. We are tried using latest version with Magento but it will not compatible with Magento. I have personally recommended you to use Solr version 3.6 series.

I have divided this article into two parts,

Installation

Integration

Installation of Apache Solr

Step 1: Download Apache Solr

Download the below link on the server under the “/opt/ directory. Download this link using wget command.

Step 3: Restart Solr Server

If you do not yet install init script then you need to kill the solr process and run again in the background.

ps aux | grep java

Kill -9 PID [stop service]

cd /opt/apache-solr/example

sudo java -jar start.jar [start service]

Step 4 : Configuration Solr in Magento panel

Now open Magento admin panel in the browser. Go to the “System → Configuration → Catalog → Solarium”.

Once you open configuration window use same settings which show in below image. After filling all the configuration settings click on “Test Connection” & “Self Test” button.

Once you get the success message on clicking Test Connection then your configuration is successfully completed.

Step 5 : Reindex the Catalog Search

Once configuration part compete you need to run catalog indexing which helps to build the solr search. After reindexing open website and search in the search box you will get the search result.

I hope you like the article if you find any difficulties while installing apache solr with magento then please do comment your queries or problem via the comment section, till then stay tuned to techthings.org for more such valuable articles.