Install VuFind on Debian/Ubuntu


Tested with Debian 10 & Ubuntu 20.04 LTS 

Install LAMP Stack , Java JDK and necessory php extensions

sudo apt -y install apache2 mariadb-server default-jdk libapache2-mod-php php-mbstring php-pear php php-dev php-gd php-intl php-json php-ldap php-mysql php-xml php-soap php-curl && sudo a2enmod rewrites ; sudo systemctl restart apache2

sudo mysql_secure_installation

Download VuFind
Go to and download latest version of VuFind (e.g. vufind-7.1.tar.gz

sudo wget

Unzip the package (Right click on the package and select "Extract here". Otherwise apply following command in a terminal. Notice the version number; it will change when new version release.

sudo tar xzvf vufind-7.1.tar.gz

Move the folder to /usr/local/vufind (Notice the version number in following command)

sudo mv vufind-7.1 /usr/local/vufind

Install VuFind

cd /usr/local/vufind
php install.php

Permission to Apache to write configuration files

sudo chown -R www-data:www-data /usr/local/vufind/local/cache
sudo chown -R www-data:www-data /usr/local/vufind/local/config

Create cache for command line tools

sudo mkdir /usr/local/vufind/local/cache/cli
sudo chmod 777 /usr/local/vufind/local/cache/cli

Link VuFind to Apache

sudo ln -s /usr/local/vufind/local/httpd-vufind.conf /etc/apache2/conf-enabled/vufind.conf

sudo systemctl restart apache2

Setup environment variables

sudo sh -c 'echo export JAVA_HOME=\"/usr/lib/jvm/default-java\" > /etc/profile.d/'
sudo sh -c 'echo export VUFIND_HOME=\"/usr/local/vufind\"  >> /etc/profile.d/'
sudo sh -c 'echo export VUFIND_LOCAL_DIR=\"/usr/local/vufind/local\"  >> /etc/profile.d/'

Load the environment manually

source /etc/profile.d/

Start Solr

VuFind using Solr search engine.

cd /usr/local/vufind/
./ start

Autostart Solr

Setting up auto start vufind using systemd, systemd is a set of tools shared across linux distributions which are focused on system and service management. Systemd is comparatively a new development in Linux, In earlier system it was used init.d, a symbolic links to a directory. sysmtemd gets ride of obscure bash scripts and replaces them with configuration files.

Create a user

sudo adduser solr --disabled-password

sudo chown -R solr:solr $VUFIND_HOME/solr/

ls -l $VUFIND_HOME/solr

sudo nano /etc/systemd/system/vufind.service

ExecStart=/bin/sh -l -c '/usr/local/vufind/ start' -x
ExecStop=/bin/sh -l -c "/usr/local/vufind/ stop" -x


sudo systemctl start vufind

Disable unix_socket plugin

sudo mysql -uroot -p
UPDATE mysql.user SET plugin='' WHERE User='root';

VuFind post installation configuration



0 Komentar