How to change master password of Koha ?

Koha master login username and password is same as MySQL database (e.g. koha_library), where data stored.

First change the password of koha_library database.
Then put new password in /etc/koha/sites/library/koha-conf.xml

Apply following commands in Applications > Accessories > Terminal

sudo mysql -uroot -p  

[enter the MySQL Root password]

use mysql;
SET PASSWORD FOR 'koha_library'@'localhost' = PASSWORD('koha123');
flush privileges;
quit;


Need to change new password in Koha configuration file.

Open the configuration file using any text editor. Use any text editor, mousepad/leafpad. Install mousepad;

sudo apt-get install mousepad

sudo mousepad /etc/koha/sites/library/koha-conf.xml

The file will open. Scroll to bottom part of the file and find the line for password.

You can find old password. Place your new password.
Save [Ctrl+O] and close [Ctrl+x] the file. Login Koha using new password.

Koha upgrade

The new version of Koha release every six months with a bundle of new features. Updates also release during the six months.

Up-gradation is easy with Koha installation based on Debian packages.

Apply the following command in Applications > Accessories > Terminal

sudo apt-get update
sudo apt-get upgrade
sudo apt-get install koha-common



If any errors show, install again repository key.

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

Again repeat the upgrade process.

Clean the packages after upgradations,

sudo apt-get clean


Upgrade Database Schema
Database schema of old Koha should upgrade to new one. Apply following commands in a terminal,

sudo koha-upgrade-schema library

Rebuild the Zebra Index.

Apply following command in a terminal,

sudo koha-rebuild-zebra -v -f library

How to schedule database backup in Koha

You can enable schedule backup of koha database with the help of cron job feature in Ubuntu. Cron is a system daemon used to execute desired tasks (in the background) at designated times.You can read more about cron in Ubuntu here.

In this process we put a mysql command to take backup of Koha database in every 60 minutes.

Create a folder in home folder called "backup", where backup file store.

Open Applications > Accessories > Terminal

 Apply the following command,

crontab -e

It will ask to select a text editor. You can select Nano text editor.



You can see crontab file content. Use down arrow button and move the cursor to bottom part of the cron file. Copy following command there.

*/60 * * * * mysqldump -ukoha_library -pkoha123 koha_library | xz > /home/koha/backup/koha_library.sql.xz

Run backup command in a specific time

15 16 * * * mysqldump -ukoha_library -pkoha123 koha_library | xz > /home/koha/backup/koha_library.sql.xz

Above mentioned command take a backup at 3:15 PM every day.

Apply  Ctrl + o button to save the file.

Then apply Ctrl + x to leave the cron.

You can find backup file in /home/koha/backup folder after 60 minutes.

Explanations of key parts in the command,

-u koha_library = MySQL Koha Database username

-p koha123 = password of Koha Database

koha_library = Koha database name

XZ = compression format.


How to add new language translation into Koha

Koha supports many language translations. Add a new language (e.g. Arabic) by using the following steps,
Open Applications > System > Terminal and apply the following commands,

sudo su 
export KOHA_CONF=/etc/koha/sites/library/koha-conf.xml
export PERL5LIB=/usr/share/koha/lib

Enter inside the translation folder,

cd /usr/share/koha/misc/translator

Check and find the availability of translations and language codes.

koha-translate --list --available

Find the desired language code (e.g. Arabic) and apply the command to install it,

perl translate install ar-Arab

Confirm that the Arabic language translation installed into Koha,

koha-translate --list

Enable the newly added translation, visiting
Administration > System Preferences > I18N/L10N > Language & OPAC languages

Check the languages and save changes.

To see the change, visit the Koha staff client, refresh the page. See the name of the translations that appeared at the left bottom part of the Koha staff client.