In this post, I will demonstrate the installation of latest koha in Ubuntu 16.04. I have successfully installed it and now will display all the necessary steps to install it in your system or server. All the prerequisites for the system are as follows. You must download all of them before starting the installation:-
- A computer system 64 bit or 32 bit.
- An Operating system either Windows, Linux, or Mac.
- Virtualbox 64 bit or 32 bit depending on your OS/CPU.
- Ubuntu 16.04 server iso image.
Step by Step Guide to Install latest koha in Ubuntu 20.04 Server.
Note: If you are installing Koha in Ubuntu Server / Desktop directly without Virtualbox then jump to point j directly.
If you are unable to follow the steps you can download the preinstalled image from here or here
After you have downloaded these packages and images then we can start the process:-
- Install Virtualbox in your system. To see how to install follow the instructions shown in the video.
- After Virtualbox installation is over then follow the steps mentioned in the video below to install Ubuntu 16.04 Server in VirtualBox. While installing the server change the System Name to : library, Username to: koha and Group: koha.
- After the installation of Ubuntu server 16.04 is over then do the following settings in VirtualBox.
- Shut down the server by clicking Machine -> close -> ACPI shutdown from Top Menu.
- Click on File -> Preferences -> Network -> Host Only Adapters -> Add new Host-only adapter icon. This will add vboxnet0 adapter into your virtualbox.
- click ok to save.
- Click on the virtual machine which you have created.
- Click settings->network->adapter 2-> select Enable Network Adapter.
- From Attached to menu: select: Host only adapter.
- As you select vboxnet0 will automatically be displayed in the Name box.
- Click ok to save.
- Click start to start the virtual machine.
- After it had turned on it will ask for Username and Password. Enter Username and password.
- After logging in to the server. Now issue the following command.
- sudo apt-get update; sudo apt-get upgrade -y
- Press enter
- it will now ask for a password. Enter password.
- After finishing step 5. Now its time to configure the network. Issue the following command:
- sudo nano /etc/network/interfaces
- Press enter. It will ask for a password. Enter password.
- This command will open the interface file. Check and change the contents of the file as mentioned below: # This file describes the network interfaces available on your system
# and how to activate them. For more information, see interfaces(5).
source /etc/network/interfaces.d/*
# The loopback network interface
auto lo
iface lo inet loopback# The primary network interface
auto enp0s3
iface enp0s3 inet dhcp
#The secondary network interface
auto enp0s8
iface enp0s8 inet dhcp - Press Ctrl O to save the file. Press Enter to save.
- Press Ctrl X to exit.
- Issue the command
- sudo service network restart
- Press Enter
- To Check the IP address of the new interface issue the command ifconfig . The output will come as follows:
- ifconfig
enp0s3 Link encap:Ethernet HWaddr 08:00:27:67:e4:b1
inet addr:10.0.2.15 Bcast:10.0.2.255 Mask:255.255.255.0
inet6 addr: fe80::a00:27ff:fe67:e4b1/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:14 errors:0 dropped:0 overruns:0 frame:0
TX packets:23 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:2276 (2.2 KB) TX bytes:2318 (2.3 KB)enp0s8 Link encap:Ethernet HWaddr 08:00:27:d4:d7:55
inet addr:192.168.56.101 Bcast:192.168.56.255 Mask:255.255.255.0
inet6 addr: fe80::a00:27ff:fed4:d755/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:427 errors:0 dropped:0 overruns:0 frame:0
TX packets:254 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:41627 (41.6 KB) TX bytes:31601 (31.6 KB)lo Link encap:Local Loopback
inet addr:127.0.0.1 Mask:255.0.0.0
inet6 addr: ::1/128 Scope:Host
UP LOOPBACK RUNNING MTU:65536 Metric:1
RX packets:160 errors:0 dropped:0 overruns:0 frame:0
TX packets:160 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1
RX bytes:11840 (11.8 KB) TX bytes:11840 (11.8 KB) - The address mentioned in above output (marked in orange color) is 192.168.56.101. This is the address from where we can access our koha portal.
- Now minimize the virtualbox window.
- Perform the steps mentioned below to connect to Guest OS i.e, Ubuntu Server from Winodws/Linux/Mac OS.
- Press Alt Ctrl T . This will launch Terminal window in Ubuntu Desktop OS, Launch Terminal form Launchpad from MAC OS, and If you are using Windows Operating system, then download putty.exe.
- In shell issue the command:
- ssh koha@192.168.56.101
- It will now ask for pressing Yes/No. Press Yes
- Now enter password you have used to enter Ubuntu Server.
- After above process is finished now issue the following commands one by one. Press enter after issuing every command. You can now copy and paste the commands in the terminal window.
- echo deb http://debian.koha-community.org/koha stable main | sudo tee /etc/apt/sources.list.d/koha.list
- wget -O- http://debian.koha-community.org/koha/gpg.asc | sudo apt-key add –
- sudo apt-get update
- sudo apt-get upgrade
- sudo apt-get clean
- sudo apt-get install koha-common koha-deps koha-perldeps
- Pre Web Install Process
- For configuring your server for koha open the file by issuing the following command:
- sudo nano /etc/koha/koha-sites.conf
- You would now set DOMAIN=”.mydomain.org”, INTRAPORT=”8080″, INTRASUFFIX=”-admin”, OPACPORT=”80″, OPACSUFFIX=”-opac”
- Press Ctrl O and Press Enter to save.
- Press Ctrl X to exit from nano.
- Now configure apache ports. Issue following commands one by one.
- sudo nano /etc/apache2/ports.conf
- Add all the missing lines in your file. The contents of your file must be same as mentioned below.
# If you just change the port or add more ports here, you will likely also
# have to change the VirtualHost statement in
# /etc/apache2/sites-enabled/000-default.conf
Listen 80
Listen 8080
<IfModule ssl_module>
Listen 443
</IfModule>
<IfModule mod_gnutls.c>
Listen 443
</IfModule># vim: syntax=apache ts=4 sw=4 sts=4 sr noet - Press Ctrl O and Press Enter to save.
- Press Ctrl X to exit from nano.
- Enter the following commands:
- sudo service apache2 restart
- sudo apt-get install mysql-server
- sudo a2enmod rewrite
- sudo a2enmod cgi
- sudo a2enmod deflate
- sudo a2ensite library
- sudo a2dissite 000-default.conf
- sudo service apache2 restart
- sudo koha-create –create-db library
- sudo nano /etc/mysql/mysql.conf.d/mysqld.cnf
- Look for [mysqld] section and paste the following lines:
sql_mode=IGNORE_SPACE,NO_ZERO_IN_DATE,NO_ZERO_DATE,ERROR_FOR_DIVISION_BY_ZERO,NO_AUTO_CREATE_USER,NO_ENGINE_SUBSTITUTION - sudo mysql_secure_installation
- Now Open the browser and enter the following address for web installation:
- http://192.168.56.101:8080
- Now you can visit your administration website to continue with the Koha web installer. The username to log in with will be koha_library.
and you can get the password from this command
sudo xmlstarlet sel -t -v ‘yazgfs/config/pass’ /etc/koha/sites/library/koha-conf.xml - Press next till finish.
- When finished Enter http://192.168.56.101 in the address bar for OPAC
- For configuring your server for koha open the file by issuing the following command:
All the above will install Koha in Ubuntu 16.04 Server.
Leave a Reply
You must be logged in to post a comment.