17.2. Installation of Locum and Insurge

17.2.1. Závislosti
17.2.2. Download
17.2.3. Vytvoření databáze
17.2.4. Sync DSN
17.2.5. Installation of Insurge
17.2.6. Installation of Locum

Locum and Insurge are the two libraries used primarily by SOPAC. They serve as a layer of abstraction to the data. Insurge manages the social aspect (tags, reviews, ratings), while Locum manages the connection to the ILS via the connector. Both libraries use a different database from that of Drupal.

17.2.1. Závislosti

There are no packages for Debian MDB2 yet, you can install it via pear:

# apt-get install php-pear
# pear install MDB2
# pear install MDB2#mysql

17.2.2. Download

Download the Locum and Insurge libraries from SVN:

# cd /usr/local/lib
# svn co http://dobby.darienlibrary.org/svn/locum/trunk/ locum
# svn co http://dobby.darienlibrary.org/svn/insurge/trunk/ insurge

17.2.3. Vytvoření databáze

$ mysql -u root
mysql> create database scas;
mysql> grant all privileges on scas.* to scas_user@'localhost' identified by 'scas_pass';
mysql> flush privileges;
mysql> exit

17.2.4. Sync DSN

This file will provide the connection information to a DB libraries:

# nano /usr/local/etc/locum_insurge_dsn.php

Může obsahovat:

<?php
$dsn = 'mysql://scas_user:scas_pass@localhost/scas';

17.2.5. Installation of Insurge

If you customize the name of the database, remember to edit the sql file:

# nano /usr/local/lib/insurge/sql/scas_insurge.sql

Import Insurge:

$ mysql -u root -p < /usr/local/lib/insurge/sql/scas_insurge.sql

Configure Insurge:

# nano /usr/local/lib/insurge/config/insurge.ini

The variables in insurge.ini are empty. The default values are too long and cause MySQL errors.

Zde je příklad insurge.ini

; This is the Locum configuration file
; General configuration options for your installation of Insurge.
[insurge_config]
dsn_file = "/usr/local/etc/locum_insurge_dsn.php"
; This is where you configure your repository membership information.
;
; parent_server is the server name of the repository parent server you have been
; told to use.
; group_id = The group ID you have been given by your repository admin.
; These configuration points are OPTIONAL and are only necessary if you are
; participating in a repository relationship.
[repository_info]
parent_server = ""
group_id = ""
group_key = ""

17.2.6. Installation of Locum

The same procedure applies to Locum

# nano /usr/local/lib/locum/sql/scas_locum.sql
# mysql < /usr/local/lib/locum/sql/scas_locum.sql
# nano /usr/local/lib/locum/sql/locum_init.sql
# mysql < /usr/local/lib/locum/sql/locum_init.sql
# nano /usr/local/lib/locum/config/locum.ini
# mkdir /usr/local/var
# mkdir /usr/local/var/log

Nastavení DSN:

[locum_config]
dsn_file = "/usr/local/etc/locum_insurge_dsn.php"

And the information for your Koha installation:

[ils_config]
ils = "koha";
ils_version = "30x"
ils_server = "localhost"
ils_harvest_port = "80"

The rest depends on your Koha configuration.