Skip to content

Local Solr Installation

Michael Dorf edited this page Jul 17, 2013 · 10 revisions

####1. Install Solr with homebrew:

$ brew update
$ brew install solr

####2. Rename "examples" directory to "ncbo":

$ cd /usr/local/Cellar/solr/<solr version>/libexec/
$ mv example ncbo

####3. Replace configuration files with NCBO's:

$ cd /usr/local/Cellar/solr/<solr version>/libexec/ncbo/solr/collection1/conf
  • Replace solrconfig.xml with our custom file found in ontologies_linked_data/config/solr/
  • Replace schema.xml with our custom file found in ontologies_linked_data/config/solr/

####4. Create a "data" directory to store the index:

$ mkdir <your own path to data dir>

####5. Add your data directory to solrconfig.xml

  • Edit /usr/local/Cellar/solr/<solr version>/libexec/ncbo/solr/collection1/conf/solrconfig.xml
  • Find the block <dataDir>${solr.data.dir:}</dataDir> and append the path to your own data directory to solr.data.dir:
<dataDir>${solr.data.dir:/your/path/to/data}</dataDir>

####6. Start Solr server:

$ cd /usr/local/Cellar/solr/<solr version>/libexec/ncbo
$ java -jar start.jar

####7. Verify your Solr installation:

  • Navigate to http://localhost:8983/solr/#/
  • Under "Core Selector" select "collection1"
  • Click on "Schema" and "Config" options and make sure they correctly reflect the NCBO custom files
Clone this wiki locally