SOLR and Tomcat Configuration

Source: Internet
Author: User
Tags http request solr tomcat
< c13>1 Overview

SOLR is a stand-alone enterprise Search application server that provides API interfaces similar to Web-service. The user can submit an XML file of a certain format to the search engine server via an HTTP request, generate an index, or make a lookup request through an HTTP GET operation and get the returned result in XML format.

SOLR is a high performance, JAVA5 developed, Lucene-based full-text Search server. At the same time, it is extended to provide a richer query language than Lucene, while it can be configured, extensible and optimized for query performance, and provides a perfect function management interface, is a very good full-text search engine.

2 Related Configurations

Note: It is relatively cumbersome to configure the operation of the Tomcat deployment SOLR, the simplest way to start SOLR is to start SOLR directly, since SOLR has built-in service containers that can be started without relying on Tomcat,

For details, refer to:


SOLR Download:

Tomcat Download (must download version 8.0 or above):

2.2 File Configuration

1, download SOLR and Tomcat decompression, and create solr_home empty directory,

Enter the SOLR directory: G:\solr_test\solr-5.5.4\server\solr-webapp

Copy the WebApp from the Solr-webapp directory to the WebApps directory of Tomcat and rename it to SOLR, as shown below:

2. Copy the jar package from SOLR to the Tomcat directory

Entering G:\solr_test\solr-5.5.4\server\lib\ext will be a few jars

Copy to G:\solr_test\apache-tomcat-7.0.77\webapps\solr\WEB-INF\lib

3. Copy to the Tomcat directory under the SOLR directory

Entering G:\solr_test\solr-5.5.4\server\resources will be a few jars

Copy to G:\solr_test\apache-tomcat-7.0.77\webapps\solr\WEB-INF\classes

Note: If you do not have a classes directory, you need to create it manually.

4. Create Solr_home

Enter G:\solr_test\solr-5.5.4\server

Copy Solr to the Solr_home directory

5. Modify the Solr_home reference path

Enter Tomcat under SOLR directory G:\solr_test\apache-tomcat-7.0.77\webapps\solr\WEB-INF modify Web. xml

Open the comments in the <env-entry-name> tag in the Web. xml file to change the value to the path of the solr_home that you just set, as shown in the following figure

2.3 Testing

When the above configuration is complete, start tomcat

Browser access: http://localhost:8080/solr/admin.html

2.4 Creating a core

1. Copy Basic Configuration

Enter the SOLR_HOME\SOLR directory to create the core

such as: G:\SOLR_TEST\SOLR_HOME\SOLR, and copy the Conf configuration in the SOLR case to the Solr_core,

Enter: Copy conf folder to Solr_core in G:\solr_test\solr-5.5.4\server\solr\configsets\sample_techproducts_configs

2. Create Core

On the Manage Platform page for core creation, the name must be as solr_core as the file directory name created in the previous step, as follows

Once created, you can see the core information and generate a data index data store file in the Solr_home directory:

At this point, the Tomcat deployment SOLR configuration is complete.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.