[Linux] Linux Install and configure the Solr/tomcat/ik word breaker detailed example one.

Source: Internet
Author: User
Tags solr

Here we explain the installation and configuration of the three, because SOLR needs to use the Tomcat and IK word breakers, which are described in the form of graphic tutorials for their installation and use.
Note: This article belongs to the original article, if reproduced, please indicate the source, thank you.
Article about setting up an IK word breaker ik word breaker: http://www.cnblogs.com/wang-meng/p/5814798.html

1. Unzip the tar file
First we create a SOLR directory under the root directory (using the command: MKDIR/SOLR):


Then check to see if the directory was generated successfully:


Unzip the Solr/tomcat/ik to the SOLR folder:


Because the IK compression package is in the ZIP format, the decompression method here is somewhat different, first we create an IK directory in the SOLR directory, and then extract:


The final directory structure:


2. View the SOLR directory structure


There is a separate boot entry in the bin, but Tomcat is not used in the development project, but it is used because Tomcat is stable.
All the core files are in the example directory. Let's look at the directory of Lib:


3, copy the Solr/solr-4.10.3/example/bin/ext jar package to Apache-tomcat-7.0.47/lib


Copy the jar package under Ext to Tomcat/lib.


Go to the tomcat pack to see if the replication succeeds:



4, copy Solr.war
First find the War package location:


Copy the war package to the WebApps of Tomcat:


Unzip the Solr.war to the SOLR directory



Delete Solr.war(note: The Solr.war will need to be removed after the decompression is complete, since Tomcat will re-unzip the war package under WebApps each time it starts)


5, configure the SOLR file save path under Web. xml


To edit a configuration file using Vim Web. xml:


Episode: Do you know how to display line numbers in vim mode? After Vim enters Web. XML, use the SHIFT Plus: command and enter the Set NU carriage return:



Configured above:/SOLR/SOLR-4.10.3/EXAMPLE/SOLR is where the data is stored in SOLR, similar to the meaning of our MySQL saved data. Also known as SOLR's home. Use the shift Z shortcut key to save and exit when we are done configuring. (Of course there are other shortcuts like Wq, here I prefer shift Z Z)


6, start Tomcat

7. View the Tomcat log


Check here to show that our Tomcat was successfully launched.
After the successful launch we can see the SOLR visual interface, but because the IK word breaker is not configured at this time, so the current participle result is not what we want, then I will introduce the IK word breaker configuration in the next post:
IK word breaker: http://www.cnblogs.com/wang-meng/p/5814798.html



[Linux] Linux Install and configure the Solr/tomcat/ik word breaker detailed example one.

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.