Install Tomcat
sudo apt-get install tomcat7 tomcat7-admin
Download SOLR
di http://mirror.reverse.net/pub/apache/lucene/solr/4.10.2/solr-4.10.2.tgz
tar zxvf solr-4.10.2.tgz
sudo mv solr-4.10.2 /usr/share/solr
Setup Solr
sudo cp /usr/share/solr/example/webapps/solr.war /usr/share/solr/example/multicore/solr.war
sudo cp -r solr/example/lib/ext/* /usr/share/tomcat7/lib
sudo cp -r solr/example/resources/log4j.properties /usr/share/tomcat7/lib
Edit /usr/share/tomcat7/lib/log4j.properties and set your log path by setting
solr.log=/usr/share/solr
Catalina config
cd /etc/tomcat7/Catalina/localhost
sudo gedit solr.xml
add the following to solr.xml
sudo gedit /etc/tomcat7/tomcat-users.xml
add the tomcat user within the users block:
sudo chown -R tomcat7 /usr/share/solr/example/multicore
Test tomcat
sudo service tomcat7 restart
Test Solr
Navigate to http://localhost:8080/solr
source :http://gagannaidu.blogspot.com/2014/02/apache-solr-461-tomcat7-setup-on-ubuntu.html
Good tutorial, nice and easy. You forgot to include the contents of the solr.xml and tomcat-users.xml files.
By: pefferen on November 22, 2014
at 12:07 pm
Ican’t get in catelina config. please explain
cd /etc/tomcat7/Catalina/localhost
there isn’t solr.xml file in /etc/tomcat7/Catalina/localhost please explain what to do.
sudo gedit solr.xml
By: DIVYANG on December 23, 2014
at 7:12 am
DIVYANG
You must create solr.xml files in the folder / etc / tomcat7 / Catalina / localhost / to the editor vi or gedit which contains:
By: sutrisno on December 23, 2014
at 3:16 pm