Language:

Search

Koha Install on Debian 7 ( Step by Step)

  • Share this:
post-title

First You should confirm dependency of KOHA.  Source URL has been listed in below

deb http://security.debian.org/ wheezy/updates main contrib
deb-src http://security.debian.org/ wheezy/updates main contrib
deb http://ftp.debian.org/debian/ wheezy-updates main contrib
deb-src http://ftp.debian.org/debian/ wheezy-updates main contrib
deb http://ftp.debian.org/debian wheezy main contrib non-free
deb-src http://ftp.debian.org/debian wheezy main contrib non-free
deb http://ftp.indexdata.dk/debian wheezy main
deb-src http://ftp.indexdata.dk/debian wheezy main
deb http://debian.koha-community.org/koha stable main
deb http://ftp.de.debian.org/debian wheezy-backports main

 

Source files is /etc/apt/sources.list

In files sources.list you should add above URL then run following command or process

1. wget -O- http://ftp.indexdata.dk/debian/indexdata.asc | sudo apt-key add -

2. wget -q -O- http://debian.koha-community.org/koha/gpg.asc | sudo apt-key add -

3.  sudo apt-get update

4.  sudo apt-get install koha-common

4. sudo a2dismod mpm_event

5. sudo apt-get install -f

Installing Database:

1. sudo apt-get install mysql-server

If not exists Apache2 then install apache2

Setup Apache

1. sudo a2enmod rewrite

2. sudo a2enmod cgi

3. sudo service apache2 restart

Create  database

1. mysql -u root -p

Enter New password: 

mysql> create database dbname;

mysql> exit;

Download Koha

1. cd /tmp/

2. wget http://download.koha-community.org/koha-latest.tar.gz Or Get Download link from Koha Website

3. tar -xvzf  koha-latest.tar.gz

4. cd koha-latest

5. sudo dpkg --set-selections < install_misc/debian.packages

6. sudo apt-get dselect-upgrade

7. perl koha_perl_deps.pl -m -u

(This will list whether any Perl dependencies are missing or need a later version and whether they are required. You can then install them another way. such as  sudo cpan Graphics::Magick CHI CHI::Driver::Memcached)

8. misc/sax_parser_print.pl

 (You should see something like:

XML::LibXML::SAX::Parser=HASH(0x81fe220)

If you are configured to use PurePerl or Expat, the script will say you have a problem and
you'll need to edit your ini file to correct it.

The file is typically located at:

/etc/perl/XML/SAX/ParserDetails.ini

The correct parser entry will need to be moved to the bottom of the file.
The following is the entry you are looking for:

[XML::LibXML::SAX::Parser]
http://xml.org/sax/features/namespaces = 1)

9.  sudo adduser koha

10. perl Makefile.PL

11. make

12. make test

13. sudo make install

14. export KOHA_CONF=/path/to/your/koha-conf.xml

15. export PERL5LIB=/path/to/koha/lib

16. sudo ln -s /etc/koha/koha-httpd.conf /etc/apache2/sites-available/koha

Update Apache Port /etc/apache2/ports.conf

Listen 80
Listen 8080

Run the following commands:

1. sudo a2enmod rewrite deflate

2. sudo a2ensite koha

3. sudo apache2ctl restart

Then run your server such as http://servername:8080 (admin) or http://servername (user)

Yusuf Khalil

Yusuf Khalil