Hi all,
I'm tinkering with Plack on Koha 3.20.04 (Ubuntu x64 14.04 LTS). I followed the
(somewhat outdated) instructions here:
http://www.generalthreat.com/2013/04/serving-koha-common-with-plack/ and made
sure that my pathways were corrected in the scripts. I'm using the port 5000
option rather than the unix socket option. After restarting koha-common, I
received the following output:
root@vps43351:~# service koha-common restart
* Restarting Koha ILS koha-common
Stopping Zebra server for library
Stopping Plack servers for library
Servers stopped
SIP server for library not running.
Starting Zebra server for library
Starting OPAC Plack server for library
/usr/share/koha/misc/plack/unlock-opac-plack.sh: 3:
/usr/share/koha/misc/plack/unlock-opac-plack.sh: Syntax error: "&" unexpected
/usr/share/koha/misc/plack/opac-plack.sh: 5:
/usr/share/koha/misc/plack/opac-plack.sh: Syntax error: "&" unexpected
The above looks as if Plack is up and running, but the syntax warning for
opac-plack.sh is puzzling. I'm not entirely sure whether there is a syntax
error in the code; everything looks correct, but I could be missing something
here. Does anyone have any suggestions or advice on how to proceed? I'd love to
get Plack up and running to see the performance difference. If there's a better
way to install Plack or configure it for 3.20, I am all ears too!
My opac-plack.sh file is as follows:
#!/bin/sh
# --max-requests = decreased from 1000 to 50 to keep memory usage sane
# --workers = number of cores on machine
test ! -z "$1" && site=$1 && shift
dir=`dirname $0`
export KOHA_CONF=/etc/koha/sites/$site/koha-conf.xml
export OPACDIR="$( xmlstarlet sel -t -v 'yazgfs/config/opacdir' $KOHA_CONF |
sed 's,/cgi-bin/opac,,' )"
export LOGDIR="$( xmlstarlet sel -t -v 'yazgfs/config/logdir' $KOHA_CONF )"
export MEMCACHED_SERVERS=localhost:11211
export MEMCACHED_NAMESPACE=$site
PIDFILE=/var/run/koha/$site/opac-plack.pid
#SOCKET=/var/run/koha/$site/opac-plack.sock
PORT=5000
# uncomment to enable logging
opt="$opt --access-log $LOGDIR/opac-access.log --error-log
$LOGDIR/opac-error.log"
opt="$opt -M FindBin --max-requests 50 --workers 2 -E deployment"
if [ $SOCKET ]; then
opt="$opt --listen $SOCKET -D --pid $PIDFILE"
elif [ $PORT ]; then
opt="$opt --port $PORT -D --pid $PIDFILE"
fi
/usr/bin/starman $opt $dir/koha.psgi
Many thanks!
Craig Butosi, MA, MLIS, B Mus (Hons.)
LIBRARY SERVICES MANAGER
the royal conservatory
TELUS Centre for Performance and Learning
273 Bloor Street West Toronto, ON M5S 1W2
416.408.2824 x338
www.rcmusic.ca<https://webmail.rcmusic.ca/owa/redir.aspx?C=b481823b299d45ee94b0016389bb76e9&URL=http%3a%2f%2fwww.rcmusic.ca%2f>
Note: This email message and any attachments are intended only for the use of
the individual to which it is addressed, and may contain information that is
privileged, confidential and exempt from disclosure under applicable law. If
the recipient of this email is not the intended recipient (or the employee or
agent responsible for delivering the email to the intended recipient), you are
hereby notified that any review, dissemination, distribution or copying or
other use of this message is strictly prohibited. If you have received this
communication in error, please notify the sender immediately by return email
and delete this message and attachments from your system, thank you.
_______________________________________________
Koha mailing list http://koha-community.org
[email protected]
https://lists.katipo.co.nz/mailman/listinfo/koha