Skip to content

Provisioning Islandora on Ubuntu

Gavin Morris edited this page Nov 12, 2015 · 18 revisions

Introduction

Within this repository, there will be a stand alone bash script designed to install an all-in-one Islandora stack upon any type of platform e.g Virtual Machine, bare metal server etc.

This document is for the evaluation and testing of Islandora but with the secondary purpose of explaining all involved installation steps for wider Islandora adoption and educational transparency.

###Document Maintainer This document is being submitted to the Islandora DevOps Interest Group to demonstrate a base Islandora install as performed and agreed upon by the Islandora Community. Any feedback should be directed at the Islandora DevOps Interest Group at https://github.com/islandora-interest-groups/Islandora-DevOps-Interest-Group.

###Disclaimer This documentation is provided by the Islandora DevOps Interest Group "as is" and "with all faults." Islandora DevOps makes no representations or warranties of any kind concerning the safety, suitability, inaccuracies, typographical errors, or other harmful components resulting from the use of this documentation or the software installed and referenced in the documentation. There are inherent dangers in the use of any software, and the user is solely responsible for determining whether this software product and this documentation is compatible with their equipment and other software installed on their equipment. Users are also solely responsible for the protection of their equipment and backup of their data, and Islandora DevOps will not be liable for any damages one may suffer in connection with using or modifying this documentation or referenced software.

Index

  • Server
  • Script
  • Install Dependencies and Pre-setup
  • Environment
  • OS
  • Package Installation
  • From Source
  • ghostscript
  • ffmpeg
  • From Binaries
  • ffmpeg2theora
  • java
  • Fits
  • adore-djatoka
  • drush
  • Configuration
  • OpenOffice
  • Monit
  • Apache and PHP
  • Setup Databases
  • Install Fedora Commons
  • Fedora Commons Base Install
  • XACML Settings
  • GSearch and Solr
  • GSearch Multithreading
  • Adore-Djatoka
  • Setup Logging
  • Drupal Filter
  • Install Drupal
  • CLUI Config
  • Islandora Modules
  • Libraries
  • Drupal site install
  • Drush Enables and Configuration

###Server This document is outlining a single (all-in-one) Islandora stack installation using Ubuntu 14.04 LTS system.

For general purpose repository sites, we recommend at minimum 2-4 CPU cores and 8GB-10GB of RAM.

This would be scaled up according to user-load, the type of derivative files being generated by the system (ie. creating web friendly version of archival quality images or video are quite processor intensive) and many other factors.

###SSH keys User accounts e.g. islandora
Sudoers config (location, ideal setup)
iptables (turn off for initial deploy?)
Install Dependencies and Pre-setup

###Environment created a islandora-install.properties file that should be removed or secured later

cat ~/islandora-install.properties

#!/bin/bash
DB_SERVER="localhost"
DB_ROOT_PASSWORD="password"            # Set MySQL root password -> keep it simple -> run mysql_secure_installation after install to secure mySQL
DRUPAL_DB_NAME="drupal7"               # Drupal database name
DRUPAL_DB_USER="drupal"                # Drupal username for settings.php file
DRUPAL_DB_PASS="password"              # Drupal password for settings.php file
DRUPAL_ADMIN_USER="admin"              # Drupal admin username to log into Drupal Site
DRUPAL_ADMIN_PASS="password"           # Drupal admin password to log into Drupal Site
DRUPAL_SITE_NAME="Islandora Install"   # Drupal site name - displayed on the web site
FEDORA_VERSION="3.7.1"                 # Fedora version to install:  3.5 or 3.6.2 or 3.7.0 or 3.7.1
FEDORA_DB_NAME="fedora3"               # Name of fedora MySQL database -> fedora3 is recommended
FEDORA_DB_USER="fedoraAdmin"           # Fedora db username -> for fedora.fcfg file
FEDORA_DB_PASS="password"              # Fedora db password -> for fedora.fcfg file
FEDORA_ADMIN_USER="fedoraAdmin"        # Username for http://localhost:8080/fedora/admin
FEDORA_ADMIN_PASS="password"           # Password for http://localhost:8080/fedora/admin
FEDORA_USER="fedora"                   # User that tomcat runs as
FEDORA_HOME="/usr/local/fedora"        # Fedora home dir
CATALINA_HOME="$FEDORA_HOME/tomcat"    # Tomcat location
# NOTE adjust memory so that it is no larger than half of total system memory. Depending on stack deployment this can be adjusted further. Don’t recommend running stack on system with less than 4GB of ram
JAVA_OPTS="-Xms3072m -Xmx3072m -XX:MaxPermSize=512m -XX:+CMSClassUnloadingEnabled -  Djavax.net.ssl.trustStore=/usr/local/fedora/server/truststore -Djavax.net.ssl.trustStorePassword=tomcat -Dsolr.solr.home=/usr/local/fedora/solr -Dkakadu.home=/opt/adore-djatoka/bin/Linux-x86-64 -Djava.library.path=/opt/adore-djatoka/lib/Linux-x86-64 -DLD_LIBRARY_PATH=/opt/adore-djatoka/lib/Linux-x86-64"
JAVA_HOME=/usr/lib/jvm/java-7-oracle/jre  
# Moved this down below java install please change to match java version
TOMCAT_BASE="http://localhost:8080"
ISLANDORA_BASE="$TOMCAT_BASE/fedora"
SOLR_BASE="$TOMCAT_BASE/solr"
ISLANDORA_BRANCH="7.x"
TUQUE_BRANCH="1.x"
ERROR_LEVEL="2"
FEDORA_GSEARCH_URL="http://downloads.sourceforge.net/fedora-commons/fedoragsearch-2.7.1.zip"
FEDORA_GSEARCH_NAME="fedoragsearch-2.7.1"
SOLR_VERSION="4.2.0"
NUMBER_OF_GSEARCH_THREADS="2"          #do one gsearch thread per cpu might want to skip multithreading if you only have 1 cpu
GSEARCH_UPDATER_NAMES="FgsUpdaters FgsUpdater1"
DRUPAL_FILTER_URL="https://github.com/Islandora/islandora_drupal_filter/releases/download/v7.1.3/fcrepo-drupalauthfilter-3.7.1.jar"
SOLR_URL="http://archive.apache.org/dist/lucene/solr/4.2.0/solr-4.2.0.tgz"
SOLR_NAME="solr-4.2.0"
SOLR_DEFAULT_CORE_PATH="collection1"

Q1="CREATE DATABASE IF NOT EXISTS $DRUPAL_DB_NAME CHARACTER SET utf8 COLLATE utf8_bin;"
Q2="GRANT ALL ON $DRUPAL_DB_NAME.* TO $DRUPAL_DB_USER@localhost IDENTIFIED BY '$DRUPAL_DB_PASS';"
Q3="CREATE DATABASE IF NOT EXISTS $FEDORA_DB_NAME CHARACTER SET utf8 COLLATE utf8_bin;"
Q4="GRANT ALL ON $FEDORA_DB_NAME.* TO $FEDORA_DB_USER@localhost IDENTIFIED BY '$FEDORA_DB_PASS';"
Q5="FLUSH PRIVILEGES;"
SQL="${Q1}${Q2}${Q3}${Q4}${Q5}"

APACHE_DEFAULT_SITE="000-default"
APC_CONFIG_FILE="/etc/php5/mods-available/apcu.ini"
PROXY_DJATOKA_CONFIG="/etc/apache2/conf-available/proxy_djatoka.conf"
APACHE_USER="www-data"
APACHE_SERVICE="apache2"
OS_DEFAULT_DOCUMENTROOT="/var/www"
SCHEDULE_TOMCAT_SERVICE_COMMAND="update-rc.d tomcat start 95 2 3 4 5 . stop 15 0 1 6 ."
SCHEDULE_OPENOFFICE_SERVICE_COMMAND="update-rc.d openoffice start 92 2 3 4 5 . stop 30 0 1 6 ."
CRON_SPOOL_DIR="/var/spool/cron/crontabs"
MONIT_CONF_DIR="/etc/monit/conf.d"
MONIT_CONFIG_FILE="/etc/monit/monitrc"

source environment - (Please note: this must be redone if you close your shell mid-install)

chmod +x ~/islandora-install.properties

. ~/islandora-install.properties

###Operating System Ensure latest core os updates apt-get update && apt-get upgrade

add repo to easily obtain oracle java installer. apt-get -y install python-software-properties && add-apt-repository -y ppa:webupd8team/java && apt-get -y update

Add optional multiverse repos in /etc/apt/sources.list Uncomment each line in this file that ends in multiverse.

Software Dependencies installed by Apt-Get Package Manager accept license agreement and enter root password when asked

apt-get -y install oracle-java7-installer libjpeg-dev libpng12-dev libtiff4-dev php5 php5-cli php5-curl php5-dev php5-gd php5-ldap php5-mysql php5-xsl php-apc php-soap php-xml-htmlsax3 php-xml-parser php-xml-rpc php-xml-rpc2 php-xml-rss php-xml-serializer php5-imagick php5-mcrypt php-xml* mysql-server vim curl apache2 rsync wget imagemagick ant libimage-exiftool-perl unzip lame autoconf build-essential checkinstall git libass-dev libfaac-dev libgpac-dev libmp3lame-dev libopencore-amrnb-dev libopencore-amrwb-dev librtmp-dev libtheora-dev libtool libvorbis-dev pkg-config texi2html zlib1g-dev ffmpeg2theora poppler-utils python-pip libreoffice libreoffice-writer libreoffice-calc libreoffice-impress libreoffice-draw bibutils ufraw links monit tesseract-ocr tesseract-ocr-eng tesseract-ocr-fra tesseract-ocr-spa tesseract-ocr-ita tesseract-ocr-por tesseract-ocr-hin tesseract-ocr-deu tesseract-ocr-jpn tesseract-ocr-rus

###Software Dependencies compiled from Source ghostscript #note ubuntu 14.04 installs ghostscript 9.10 which is currently failing our test sets and prevents tiffs from being generated from pdfs. Had to install from source to get right version

wget http://downloads.ghostscript.com/public/ghostscript-9.05.tar.gz tar xvzf ghostscript-9.05.tar.gz cd ghostscript-9.05 ./configure

Clone this wiki locally