SOLR deployment to Tomcat

Source: Internet
Author: User
Tags solr

1. Version Selection

Solr-5.3.1.tgzapache-tomcat-8.0.29.tar.gz

2. Unzip Tomcat and SOLR

tar -zxvf apache-tomcat-8.0. . Tar  tar -zxvf solr-5.3. 1

3. Copy SOLR project to Tomcat

1) Copy the WebApp from the/solr-5.3.1/server/solr-webapp directory into the Tomcat WebApps directory

pwd/luxh/solr/solr-5.3. 1/server/solr-webapp[[email protected] solrlswebapp[[email protected] SOLR  CP -R webapp//luxh/solr/apache-tomcat-8.0. /webapps/

2) Rename the webapp copied to Tomcat to SOLR

[Email protected] solr-webapp]# cd/luxh/solr/apache-tomcat-8.0. /lsdocs  Examples  host-manager  manager  ROOT   mv webapp/lsdocs  Examples  host-manager  Manager  ROOT  

4. Building the SOLR root directory

mkdir Solr_home[[email protected] solr]# CD solr_home/pwd/luxh/solr/solr_home

Copy all files under the SOLR-5.3.1/SERVER/SOLR directory to the SOLR root directory

pwd/luxh/solr/solr-5.3. 1/server/lsconfigsets  README.txt  solr.xml  CP -r/luxh/ solr/solr-5.3. 1/SERVER/SOLR/*

5. Configure the SOLR project in Tomcat

1) Modify the Web. xml file for the SOLR project

pwd/luxh/solr/apache-tomcat-8.0. /webapps/solr/web-inf[[email protected] WEBVI

Remove the <env-entry> comment and set the <env-entry-value> value to the root of the SOLR before setting up

<env-entry>       <env-entry-name>solr/home</env-entry-name>       <env-entry-value>/luxh/solr/solr_home</env-entry-value>       <env -entry-type>java.lang.string</env-entry-type>    </env-entry>

2) in the SOLR project that copies all the jar packages in the Solr-5.3.1/server/lib/ext directory

CP -r/luxh/solr/solr-5.3. 1/server/lib/ext/*

3) The log4j.properties copy of the Solr-5.3.1/server/resources directory in the SOLR project

Create the Classes folder first

pwd/luxh/solr/apache-tomcat-8.0. /webapps/solr/web-inf[[email protected] WEBlslib  weblogic.xml  web.xml[[ Email protected] Webmkdir  classes[[email protected] weblsclasses  Lib  weblogic.xml  web.xml[[email protected] Web

Copy log4j.properties

pwd/luxh/solr/solr-5.3. 1/server/lsjetty-logging.properties  CP log4j.properties/luxh/solr/apache-tomcat-8.0. /webapps/solr/web-inf/

6. Start Tomcat

[Email protected] apache-tomcat-8.0.  in pwd/luxh/solr/apache-tomcat-8.0.  in [email protected] Apache-tomcat-8.0. ] # Bin/startup. SH

7, visit http://Your ip:8080/solr/admin.html, the following interface appears, indicating the successful deployment.

SOLR deployment to Tomcat

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: info-contact@alibabacloud.com 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.