- Install Java and Tomcat 6 > https://gist.github.com/1765586
- Install Solr and Subversion
sudo apt-get install solr-tomcat subversion
- Solr is now visible on http://localhost:8080/solr/
- Install Libraries module
cd ~/web/ausbots
drush dl libraries
- Install apachesolr module
drush dl apachesolr
- Download solr-php client libraries
cd sites/all/libraries
svn export -r22 http://solr-php-client.googlecode.com/svn/trunk/ SolrPhpClient
- Next there are a few configuration things we need to do before we enable the Apache Solr module. You need to copy schema.xml and solrconfig.xml to /etc/solr/conf/.
cd sites/all/modules/apachesolr
sudo cp solrconfig.xml /etc/solr/conf/
sudo cp schema.xml /etc/solr/conf/
- Now we need to modify solrconfig.xml to tell to solr where to save files. You can use your editor of choice I like nano.
sudo nano /etc/solr/conf/solrconfig.xml
- You need to set datDir to /var/lib/solr/data, like below
<!--
CHANGE THIS TO WHATS BELOW
<dataDir>${solr.data.dir:./solr/data}</dataDir>
-->
<dataDir>/var/lib/solr/data</dataDir>
sudo service tomcat6 restart
-
Now you can enable the apache solr modules, make sure to set the port to :8080 in the module config
-
Fix for http://drupal.org/node/949912
$ cd /usr/share/solr/WEB-INF/lib
$ ln -s ../../../java/lucene-memory.jar