KOHA
Koha upgrade procedura: Revision 1
Ova stranica opisuje proceduru upgrade produkcijske Koha instalacije na koha.ffzg.hr na zadnju verziju iz našeg git-a fix permsdpavlin@koha-upgrade:/srv/koha$ sudo chgrp -R koha . dpavlin@koha-upgrade:/srv/koha$ sudo chmod -R g+w . upgradedpavlin@koha-upgrade:/srv/koha$ git pull dpavlin@koha-upgrade:/srv/koha$ perl Makefile.PL ... Please specify the password of the user that owns the database to be used by Koha [katikoan] ... prerequisite[Wed Oct 28 18:35:13 2009] Makefile.PL: Warning: prerequisite IPC::Cmd 0.46 not found. We have 0.401. [Wed Oct 28 18:35:13 2009] Makefile.PL: Warning: prerequisite Memoize::Memcached 0.03 not found. [Wed Oct 28 18:35:14 2009] Makefile.PL: Warning: prerequisite Test::More 0.8 not found. We have 0.72. dpavlin@koha-upgrade:/srv/koha$ sudo apt-get install -y libcache-memcached-perl libtest-mockobject-perl dpavlin@koha-upgrade:/srv/koha$ sudo cpan IPC::Cmd Memoize::Memcached Test::More Authen::CAS::Client Lingua::Stem::Snowball testdpavlin@koha-upgrade:/srv/koha$ make test ... All tests successful, 12 subtests skipped. Files=25, Tests=391, 5 wallclock secs ( 4.71 cusr + 0.32 csys = 5.03 CPU) upgradedpavlin@koha-upgrade:/srv/koha$ sudo make upgrade ... Koha's files have now been installed. In order to use Koha's command-line batch jobs, you should set the following environment variables: export KOHA_CONF=/etc/koha/koha-conf.xml export PERL5LIB=/usr/share/koha/lib For other post-installation tasks, please consult the README. Upgrade ce iskopirati sve promijenjene fajlove i dodati im nastavak _upgrade_backup. To može biti korisno u slučaju kad su na produkciji rađene promjene koje nisu pospremljene u repozitorij (git). Stvoreni fajlovi mogu se obrisati ovako: find . -name '*_upgrade_backup' -exec rm -v {} \; konfiguracijadpavlin@koha-upgrade:/etc/koha$ sudo vi -d /etc/koha/koha-conf.xml /etc/koha/koha-conf.xml_upgrade_backup LDAP config & startProvjeriti verzijudpavlin@koha-dev:/srv/koha$ grep VERSION /srv/koha/C4/Auth_with_ldap.pm use vars qw($VERSION @ISA @EXPORT @EXPORT_OK %EXPORT_TAGS $debug); $VERSION = 3.10; # set the version for version checking /etc/koha/koha-conf.xml<ldapserver id="ldapserver" listenref="ldapserver"> <!-- <hostname>ldaps://ldap.ffzg.hr</hostname> --> <hostname>ldap://localhost:1389</hostname> <base>dc=ffzg,dc=hr</base> <replicate>1</replicate> <!-- add new users from LDAP to Koha database --> <update>0</update> <!-- update existing users in Koha database --> <auth_by_bind>1</auth_by_bind> <principal_name>%s</principal_name> <!-- optional, for auth_by_bind: a printf format to make userPrincipalName from koha userid --> <mapping> <!-- match koha SQL field names to your LDAP record field names --> <firstname is="givenname" ></firstname> <surname is="sn" ></surname> <address is="ffzg-ml_postanska_adresa_0" ></address> <!-- <city is="ffzg-prebivaliste_mjesto" ></city> --> <city is="ffzg-ml_postanska_adresa_1" ></city> <zipcode is="ffzg-prebivaliste_postanski_broj"></zipcode> <branchcode is="local-branch" >FFZG</branchcode> <userid is="hredupersonuniqueid" ></userid> <password is="userpassword" ></password> <email is="mail" ></email> <categorycode is="local-categorycode" >IMP</categorycode> <dateofbirth is="ffzg-datum_rodjenja" ></dateofbirth> <sex is="ffzg-spol" ></sex> <phone is="ffzg-ml_telefoni_fixed"></phone> <mobile is="ffzg-ml_telefoni_mobile"></mobile> </mapping> </ldapserver> Koristi LDAP rewrite Da bi sve radilo potrebno je ugasiti ExtendedPatronAttributes na https://10.60.0.252:8443/cgi-bin/koha/admin/preferences.pl?tab=patrons Za detalje pogledajte LDAP Virtualni LDAP omogućava Kohi da isporučuje podatke preko LDAP-a drugim sustavima, u našem slučaju, kopirkama, vidi SafeQ integration. Drugi dio sustava je LDAP rewrite koji omogućava korištenje login@ffzg.hr bez modifikacija kohe.
upgradeUpgrade na r61 koji ima podršku za novu koha konfiguraciju i logine bez modifikacije kohe: # tunnel dpavlin@llin:~$ ssh -R 8022:localhost:22 10.60.0.252 dpavlin@koha-2010-01-06:~$ cd /srv/virtual-ldap/ dpavlin@koha-2010-01-06:/srv/virtual-ldap$ svn update A sql A sql/organizationalunit.sql A sql/group.sql A sql/hreduperson.sql U lib/LDAP/Virtual.pm U lib/LDAP/Koha.pm U bin/ldap-rewrite.pl Updated to revision 61. start server processdpavlin@koha-upgrade:~$ screen -S virtual-ldap Pokrenuti server (inače to radi monit, ali on je deinstaliran da ne gnjavi) dpavlin@koha-upgrade:~$ cd /srv/virtual-ldap/ dpavlin@koha-upgrade:/srv/virtual-ldap$ ./bin/virtual-ldap.pl LDAP server listening on port 1389 Čudan depdendency koji ne bi trebao postojati (kako radi na produkciji?) dpavlin@koha-upgrade:/srv/virtual-ldap$ ./bin/virtual-ldap.pl Can't locate Net/LDAP/Server.pm in @INC (@INC contains: lib /etc/perl /usr/local/lib/perl/5.10.0 /usr/local/share/perl/5.10.0 /usr/lib/perl5 /usr/share/perl5 /usr/lib/perl/5.10 /usr/share/perl/5.10 /usr/local/lib/site_perl .) at lib/LDAP/Virtual.pm line 12, <DATA> line 96. BEGIN failed--compilation aborted at lib/LDAP/Virtual.pm line 12, <DATA> line 96. Compilation failed in require at ./bin/virtual-ldap.pl line 7, <DATA> line 96. BEGIN failed--compilation aborted at ./bin/virtual-ldap.pl line 7, <DATA> line 96. dpavlin@koha-upgrade:/srv/virtual-ldap$ sudo apt-get install libnet-ldap-server-perl Zebra startdpavlin@koha-upgrade:~$ sudo /usr/share/koha/bin/koha-zebra-ctl.sh start Starting Zebra Server |