General information
Documentation
Cooperation
General information
Documentation
Cooperation
Apache Solr is an indexing and information retrieval server based on Lucene. We use is as a search engine for data stored in a PDR instance. It has to be deployed in a servlet container, like Apache Tomcat's Catalina. This article describes how to deploy Solr with Tomcat, connected to an Apache Web Server.
To provide a search engine for prosopographic data stored in our PDR, we use the indexing and retrieval capabilities of Apache's projects Lucene and Solr.
Solr is available at lucene.apache.org.
Download a binary distribution (We are running Solr in version 3.6.0)
and unpack it. You should find a subdirectory named
example
in its contents. From this subdirectory, extract solr
and place
it somehere convenient, e.g. under the root path of your Tomcat instance:
/home/tomcat8082/tomcat1/solr/
. This will be your Solr-home directory.
By copying it from the dictriobutions example
folder, we can start off
with already sufficient default configurations.
The archive also contains a deployable web archive
like dist/solr-X.X.X.war
, which we can just drop into Tomcat's webapp folder.
Now you are alomost done.
Some changes need to be made to some of Solr's configuration files.
tomcat1/conf/Catalina/localhost/solr.xml
: need to set solr/home
variable.
<?xml version="1.0" encoding="utf-8"?> <Context docBase="/home/tomcat8082/tomcat1/solr/solr.war" debug="0" crossContext="true"> <Environment name="solr/home" type="java.lang.String" value="/home/tomcat8082/tomcat1/solr" override="true"/> </Context>
In tomcat1/solr/conf/solrconfig.xml
, set dataDir:
<dataDir>${solr.data.dir:/home/tomcat8082/tomcat1/solr}</dataDir>
make sure there is an index
folder inside solr's dataDir
that
Tomcat has sufficient permissions for.
You'll possibly need to activate admin handlers in solrconfig.xml
.
retrieve ''schema.xml'' from the
download page
and save it to Solr's conf
folder.