Removed subroutines now existing in modules: extractmarcfields,
[koha.git] / acqui.simple / z3950-daemon-shell.sh
1 #!/bin/sh
2
3 # Script to start Koha background Z39.50 search daemon
4
5 # Part of the Koha Library Mgmt System -  www.koha.org
6 # Licensed under the GPL
7
8 #----------------------------
9 # Do NOT run this script directly from system startup-
10 #    Call  z3950-daemon-launch.sh  instead
11
12 #----------------------------
13
14 KohaDir=/usr/local/www/koha/htdocs/cgi-bin/koha/acqui.simple
15 KohaModuleDir=/usr/local/koha/modules
16 LogDir=/var/log/koha
17
18 #----------------------------
19 LOGFILE=$LogDir/z3950-daemon-`date +%Y%m%d-%H%M`.log
20
21 touch $LOGFILE
22 if [ ! -w $LOGFILE ]
23 then
24         echo ERROR: Cannot write to log file $LOGFILE
25         exit 1
26 fi
27
28 KohaZ3950Script=$KohaDir/processz3950queue
29 if [ ! -x $KohaZ3950Script ]
30 then
31         echo ERROR: Cannot find Koha Z39.50 daemon script $KohaZ3950Script
32         exit 1
33 fi
34
35 PERL5LIB=$KohaModuleDir
36 export PERL5LIB
37
38 exec $KohaDir/processz3950queue >>$LOGFILE 2>&1