install solr, run solr, setup solr, solr cluster, solr cluster setup, solr installation steps, SolrCloud

Setup SolrCloud

This post explain how to install the solr cluster. The below installation steps, install and run the solr cluster. After installation of cluster, you can create the indexes, aliases and fields by providing the solrconfig.xml and schema.xml file.
Perform the below steps on all nodes where you wants to install the Solr.
 1.Download the Solr bundle from http://archive.apache.org/dist/lucene/solr/4.7.2/solr-4.7.2.zip using the below command:

2. Unzip the downloaded bundle:
 unzip solr-4.7.2.zip
3. Create a solr home directory to store the solr data:
 mkdir-p solr/home/
4. Move to the solr home directory and create an file named “solr.xml”:

 cd solr/home/
Create the solr.xml file and add the following content in it.
 

 
 

 
   ${host:}
   ${jetty.port:}
   ${hostContext:solr}
   ${zkClientTimeout:30000}
   ${genericCoreNodeNames:true}
 

 
   ${socketTimeout:0}
   ${connTimeout:0}
 
 
5. Now move to the example directory available inside the extracted solr folder:
 cd solr-4.7.2/example/
6. Before starting the solr, you should have running zookeeper cluster. Solr need the IP address and port of zookeeper to start.
nohup java -Xms128M -Xmx1024M -Dsolr.solr.home=solr/home/ -Djetty.port=8983 -DzkHost= zkHost1:2181,zkHost2:2181,zkHost3:2181 -DzkClientTimeout=10000 -DsocketTimeout=1000 -DconnTimeout=1000 -DhostContext=/solr -jar start.jar &
Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s