Select Page

Just for reference, here is the file I use to bring up my vagrant dev box with Solr 4 and Jetty ready to go.

#!/usr/bin/env bash
apt-get install python-software-properties
add-apt-repository ppa:ondrej/php5
apt-get update
apt-get install php5
apt-get install php5-mysql
apt-get install mysql-server libapache2-mod-auth-mysql php5-mysql
apt-get install phpmyadmin
apt-get install php5-curl
apt-get install -y apache2
apt-get install -y tomcat6 curl

rm -rf /var/www
ln -fs /vagrant /var/www
mkdir -p /opt/jetty/webapps/
mkdir -p /opt/jetty/webapps/
cd /opt
tar -xvf solr-4.4.0.tgz
cp solr-4.4.0/dist/solr-4.4.0.war /opt/jetty/webapps/solr.war
cp -r /opt/solr-4.4.0/dist /opt/solr
p -r /opt/solr-4.4.0/contrib /opt/solr
# copy new cores
cp -R /var/www/solr-config-master/solr-config-master/example solr
cp -r solr-4.4.0 solr

#/etc/init.d/tomcat6 start
cd /etc/init.d/
sudo sh tomcat6 start
cd /opt/solr/example/
sudo java -jar start.jar

Whenever a new Solr version comes out they tend to move the location , so a good idea to check whats’ what:

%d bloggers like this: