3 if ! getent group koha > /dev/null 2>&1; then
4 groupadd koha &> /dev/null
7 if ! getent passwd koha > /dev/null 2>&1; then
8 useradd -g koha koha &> /dev/null
12 echo "Koha files are installed, however there are a few more steps to perform"
14 echo "Please create a mysql database named 'koha', and allow full access to user"
15 echo "'kohaadmin' with password 'katikoan'"
16 echo "You can do this by issuing the following command:"
17 echo " \$ echo 'create database koha; grant all on koha.* to kohaadmin@localhost \\"
18 echo " identified by '\''katikoan'\''; flush privileges;' | mysql -uroot -p"
20 echo "In order to use Koha's command-line batch jobs,"
21 echo "you should set the following environment variables:"
23 echo "export KOHA_CONF=/etc/koha/koha-conf.xml"
24 echo "export PERL5LIB=/usr/share/koha/lib"
26 echo "Please consult the /usr/share/doc/koha-$1/INSTALL file on how to"
27 echo "complete the installation. Steps 1-4 were completed by this package, "
28 echo "you should continue at step 5"
33 # handle upgrade from 3.2 to 3.4
34 if [ ${1:2:2} == 04 ] && [ ${2:2:2} == 02 ]; then
35 echo "Koha 3.4.x no longer stores items in biblio records so as part of the"
36 echo "upgrade we now run the following two steps, they can take a"
37 echo "long time (several hours) to complete for large databases"
39 echo "/usr/share/koha/bin/maintenance/remove_items_from_biblioitems.pl --run"
40 echo "/usr/share/koha/bin/migration_tools/rebuild_zebra.pl -b -r"
42 echo "Running /usr/share/koha/bin/maintenance/remove_items_from_biblioitems.pl --run"
43 export PERL5LIB=/usr/share/koha/lib
44 export KOHA_CONF=/etc/koha/koha-conf.xml
45 /usr/share/koha/bin/maintenance/remove_items_from_biblioitems.pl --run
48 echo "Running /usr/share/koha/bin/migration_tools/rebuild_zebra.pl -b -r"
49 /usr/share/koha/bin/migration_tools/rebuild_zebra.pl -b -r
60 echo "If you have created a koha database, you might want to remove it now by running:"
61 echo " \$ echo 'drop database koha;' | mysql -uroot -p"