From 328aa9653362725e322dae03f9a77333a35f0fd1 Mon Sep 17 00:00:00 2001 From: Robert Soulliere Date: Wed, 15 Sep 2010 13:44:30 -0400 Subject: [PATCH] More admin clean up... --- 1.6/admin/AdminMisc.xml | 26 +-- 1.6/admin/Upgrading-Evergreen_1.6.xml | 46 +++-- 1.6/admin/sip.xml | 282 +++++++++++++++----------- 1.6/admin/troubleshooting.xml | 110 +++++----- 1.6/admin/z3950.xml | 220 ++++++++++---------- 5 files changed, 367 insertions(+), 317 deletions(-) diff --git a/1.6/admin/AdminMisc.xml b/1.6/admin/AdminMisc.xml index 8811cf2835..33f6f6e264 100644 --- a/1.6/admin/AdminMisc.xml +++ b/1.6/admin/AdminMisc.xml @@ -160,19 +160,19 @@ threshold of time or size has been reached and rotates the log files if a threshold condition has been met. To teach logrotate to rotate Evergreen logs on a weekly basis, or if they are > 50MB in size, create a new file /etc/logrotate.d/evergreen with the following contents: - - compress - /openils/var/log/*.log { - # keep the last 4 archived log files along with the current log file - # log log.1.gz log.2.gz log.3.gz log.4.gz - # and delete the oldest log file (what would have been log.5.gz) - rotate 5 - # if the log file is > 50MB in size, rotate it immediately - size 50M - # for those logs that don't grow fast, rotate them weekly anyway - weekly - } - + +compress +/openils/var/log/*.log { +# keep the last 4 archived log files along with the current log file + # log log.1.gz log.2.gz log.3.gz log.4.gz + # and delete the oldest log file (what would have been log.5.gz) +rotate 5 +# if the log file is > 50MB in size, rotate it immediately +size 50M + # for those logs that don't grow fast, rotate them weekly anyway + weekly +} + Changing Logging Level for <application>Evergreen</application> diff --git a/1.6/admin/Upgrading-Evergreen_1.6.xml b/1.6/admin/Upgrading-Evergreen_1.6.xml index 5b856c259b..1ef37957e5 100644 --- a/1.6/admin/Upgrading-Evergreen_1.6.xml +++ b/1.6/admin/Upgrading-Evergreen_1.6.xml @@ -56,13 +56,15 @@ for your distribution: - for Debian Etch (4.0)LinuxDebian + for Debian Etch (4.0) + LinuxDebian for Debian Lenny (5.0) - for Ubuntu Hardy Heron (8.04)LinuxUbuntu + for Ubuntu Hardy Heron (8.04) + LinuxUbuntu for Ubuntu Intrepid Ibex @@ -213,15 +215,19 @@ Update the Evergreen database: it is recommended that you back up your Evergreen database in order to restore your data if anything goes wrong. - psql -U evergreen -h localhost -f Open-ILS/src/sql/Pg/1.4.0.5-1.6.0.0-upgrade-db.sql evergreen - psql -U evergreen -h localhost -f Open-ILS/src/sql/Pg/1.6.0.0-1.6.0.1-upgrade-db.sql evergreen - psql -U evergreen -h localhost -f Open-ILS/src/sql/Pg/1.6.0.1-1.6.0.2-upgrade-db.sql evergreen - psql -U evergreen -h localhost -f Open-ILS/src/sql/Pg/1.6.0.2-1.6.0.3-upgrade-db.sql evergreen - psql -U evergreen -h localhost -f Open-ILS/src/sql/Pg/1.6.0.3-1.6.0.4-upgrade-db.sql evergreen - psql -U evergreen -h localhost -f Open-ILS/src/sql/Pg/1.6.0.4-1.6.0.5-upgrade-db.sql evergreen - psql -U evergreen -h localhost -f Open-ILS/src/sql/Pg/1.6.0.5-1.6.0.6-upgrade-db.sql evergreen - psql -U evergreen -h localhost -f Open-ILS/src/sql/Pg/1.6.0.6-1.6.0.7-upgrade-db.sql evergreen - psql -U evergreen -h localhost -f Open-ILS/src/sql/Pg/1.6.0.7-1.6.0.8-upgrade-db.sql evergreen + + +psql -U evergreen -h localhost -f Open-ILS/src/sql/Pg/1.4.0.5-1.6.0.0-upgrade-db.sql evergreen +psql -U evergreen -h localhost -f Open-ILS/src/sql/Pg/1.6.0.0-1.6.0.1-upgrade-db.sql evergreen +psql -U evergreen -h localhost -f Open-ILS/src/sql/Pg/1.6.0.1-1.6.0.2-upgrade-db.sql evergreen +psql -U evergreen -h localhost -f Open-ILS/src/sql/Pg/1.6.0.2-1.6.0.3-upgrade-db.sql evergreen +psql -U evergreen -h localhost -f Open-ILS/src/sql/Pg/1.6.0.3-1.6.0.4-upgrade-db.sql evergreen +psql -U evergreen -h localhost -f Open-ILS/src/sql/Pg/1.6.0.4-1.6.0.5-upgrade-db.sql evergreen +psql -U evergreen -h localhost -f Open-ILS/src/sql/Pg/1.6.0.5-1.6.0.6-upgrade-db.sql evergreen +psql -U evergreen -h localhost -f Open-ILS/src/sql/Pg/1.6.0.6-1.6.0.7-upgrade-db.sql evergreen +psql -U evergreen -h localhost -f Open-ILS/src/sql/Pg/1.6.0.7-1.6.0.8-upgrade-db.sql evergreen + + Download and run the the billing view hot-fix script wget http://www.open-ils.org/downloads/1.6.0-mmbxs-cleanup.sql psql -U evergreen -h localhost -f 1.6.0-mmbxs-cleanup.sql @@ -316,13 +322,17 @@ Create an empty Evergreen database in postgresql 8.3 by issuing the following commands as the postgres user: - createdb -E UNICODE evergreen - createlang plperl evergreen - createlang plperlu evergreen - createlang plpgsql evergreen - psql -f /usr/share/postgresql/8.3/contrib/tablefunc.sql evergreen - psql -f /usr/share/postgresql/8.3/contrib/tsearch2.sql evergreen - psql -f /usr/share/postgresql/8.3/contrib/pgxml.sql evergreen + + +createdb -E UNICODE evergreen +createlang plperl evergreen +createlang plperlu evergreen +createlang plpgsql evergreen +psql -f /usr/share/postgresql/8.3/contrib/tablefunc.sql evergreen +psql -f /usr/share/postgresql/8.3/contrib/tsearch2.sql evergreen +psql -f /usr/share/postgresql/8.3/contrib/pgxml.sql evergreen + + As the postgres user on the PostgreSQL server, create a PostgreSQL user named evergreen for the database cluster: diff --git a/1.6/admin/sip.xml b/1.6/admin/sip.xml index 7e8d44d14c..1fde5ab78d 100644 --- a/1.6/admin/sip.xml +++ b/1.6/admin/sip.xml @@ -26,39 +26,40 @@ Getting the code Current SIP code lives at github: - cd /opt - git clone git://github.com/atz/SIPServer.git SIPServer + cd /opt + git clone git://github.com/atz/SIPServer.git SIPServer Or use the old style: - $ cd /opt - $ sudo cvs -d:pserver:anonymous@openncip.cvs.sourceforge.net:/cvsroot/openncip login - # when prompted for the CVS password, just hit Enter (sudo password may be req'd) - $ sudo cvs -z3 -d:pserver:anonymous@openncip.cvs.sourceforge.net:/cvsroot/openncip co -P SIPServer + $ cd /opt + $ sudo cvs -d:pserver:anonymous@openncip.cvs.sourceforge.net:/cvsroot/openncip login + When prompted for the CVS password, just hit Enter (sudo password may be req'd) + $ sudo cvs -z3 -d:pserver:anonymous@openncip.cvs.sourceforge.net:/cvsroot/openncip co -P SIPServer Configuring the Server - Type the following commands from the command prompt: - $ sudo su opensrf - $ cd /openils/conf - $ cp oils_sip.xml.example oils_sip.xml + Type the following commands from the command prompt:configuration filesoils_sip.xml + $ sudo su opensrf + $ cd /openils/conf + $ cp oils_sip.xml.example oils_sip.xml - Edit oils_sip.xmlconfiguration filesoils_sip.xml. + Edit oils_sip.xmlconfiguration filesoils_sip.xml. Change the commented out <server-params> section to this: - <server-params - min_servers='1' - min_spare_servers='0' - max_servers='25' - /> + +<server-params +min_servers='1' +min_spare_servers='0' +max_servers='25' +/> + max_servers will directly correspond to the number of allowed SIP clients. Set the number accordingly, but bear in mind that too many connections can - exhaust memory. On a 4G RAM/4 CPU server (that is also running evergreen), I would recommend not exceeding 100 - SIP client connections, - give or take. + exhaust memory. On a 4G RAM/4 CPU server (that is also running evergreen), it is not recommended to exceed 100 + SIP client connections. @@ -66,21 +67,23 @@ Adding <systemitem class="protocol">SIP</systemitem> Users - Type the following commands from the command prompt: - $ sudo su opensrf - $ cd /openils/conf - $ cp oils_sip.xml.example oils_sip.xml + Type the following commands from the command prompt:configuration filesoils_sip.xml + $ sudo su opensrf + $ cd /openils/conf + $ cp oils_sip.xml.example oils_sip.xml - in the <accounts> section, add SIP client login information. Make sure that all <logins> use the - same institution attribute, and make - sure the institution is listed in <institutions>. All attributes in the <login> section will be used by the SIP client. + in the <accounts> section, add SIP client login information. Make sure that all + <logins> use the same institution attribute, and make + sure the institution is listed in <institutions>. All attributes in the <login> section will be + used by the SIP client. - In Evergreen, create a new profile group called SIP. This group should be a sub-group of Users - (not Staff or Patrons). - Set Editing Permission as group_application.user.sip_client and give the group the following permissions: + In Evergreen, create a new profile group called SIP. + This group should be a sub-group of Users + (not Staff or Patrons). + Set Editing Permission as group_application.user.sip_client and give the group the following permissions: COPY_CHECKIN COPY_CHECKOUT @@ -93,105 +96,119 @@ VIEW_USER_TRANSACTIONS OR use SQL like: - INSERT INTO permission.grp_tree (id,name,parent,description,application_perm) - VALUES (8, 'SIP', 1, 'SIP2 Client Systems', 'group_application.user.sip_client'); - - INSERT INTO permission.grp_perm_map (grp,perm,depth) - VALUES (8,15,0),(8,16,0),(8,17,0),(8,31,0),(8,32,0),(8,48,0),(8,54,0),(8,75,0),(8,82,0); + + +INSERT INTO permission.grp_tree (id,name,parent,description,application_perm) +VALUES (8, 'SIP', 1, 'SIP2 Client Systems', 'group_application.user.sip_client'); + +INSERT INTO permission.grp_perm_map (grp,perm,depth) +VALUES (8,15,0),(8,16,0),(8,17,0),(8,31,0),(8,32,0),(8,48,0),(8,54,0),(8,75,0),(8,82,0); + + Verify: - SELECT * - FROM permission.grp_perm_map JOIN permission.perm_list ON - permission.grp_perm_map.perm=permission.perm_list.id - WHERE grp=8; + + +SELECT * +FROM permission.grp_perm_map JOIN permission.perm_list ON +permission.grp_perm_map.perm=permission.perm_list.id +WHERE grp=8; + + - Keep in mind that the id (8) may not necessarily be available on your system. + Keep in mind that the id (8) may not necessarily be available on your system. - For each account created in the <login> section of oils_sip.xml, create a user (via the staff client user editor) that has the same username - and password and put that user into the SIP group. - The expiration date will affect the SIP users' connection, you might want to make a note of - this somewhere. + For each account created in the <login> section of oils_sip.xml, create a user (via the staff client user editor) + that has the same username + and password and put that user into the SIP group. + The expiration date will affect the SIP users' connection so you might want to make a note of + this somewhere. Running the server To start the SIP server type the following commands from the command prompt: - $ sudo su opensrf - $ oils_ctl.sh -d /openils/var/run -s /openils/conf/oils_sip.xml -a [start|stop|restart]_sip + $ sudo su opensrf + $ oils_ctl.sh -d /openils/var/run -s /openils/conf/oils_sip.xml -a [start|stop|restart]_sip - Logging-SIP + Logging-SIPSIP - Syslog - It is useful to log SIP requests to a separate file especially during initial setup by modifying your syslog config file. + <systemitem class="service">Syslog</systemitem> + It is useful to log SIP requests to a separate file especially during initial setup by modifying your + syslog config file.syslog Edit syslog.conf. - $ sudo vi /etc/syslog.conf # maybe /etc/rsyslog.conf + $ sudo vi /etc/syslog.conf # maybe /etc/rsyslog.conf Add this: - local6.* -/var/log/SIP_evergreen.log + local6.* -/var/log/SIP_evergreen.log - Syslog expects the logfile to exist so create the file. - $ sudo touch /var/log/SIP_evergreen.log + Syslog expects the logfile to exist so create the file. + $ sudo touch /var/log/SIP_evergreen.log - Restart sysklogd. - $ sudo /etc/init.d/sysklogd restart + Restart sysklogd. + $ sudo /etc/init.d/sysklogd restart - Syslog-NG + <systemitem class="service">Syslog-NG</systemitem> - Edit logging config. - sudo vi /etc/syslog-ng/syslog-ng.conf + Edit logging config.syslog-NG + sudo vi /etc/syslog-ng/syslog-ng.conf Add: - # SIP2 for Evergreen - filter f_eg_sip { level(warn, err, crit) and facility(local6); }; - destination eg_sip { file("/var/log/SIP_evergreen.log"); }; - log { source(s_all); filter(f_eg_sip); destination(eg_sip); }; + +# SIP2 for Evergreen +filter f_eg_sip { level(warn, err, crit) and facility(local6); }; +destination eg_sip { file("/var/log/SIP_evergreen.log"); }; +log { source(s_all); filter(f_eg_sip); destination(eg_sip); }; + - Syslog-ng expects the logfile to exist so create the file. - $ sudo touch /var/log/SIP_evergreen.log + Syslog-ng expects the logfile to exist so create the file. + $ sudo touch /var/log/SIP_evergreen.log - Restart syslog-ng - $ sudo /etc/init.d/syslog-ng restart - + Restart syslog-ng + $ sudo /etc/init.d/syslog-ng restart - Testing Your <systemitem class="protocol">SIP</systemitem> Connection + Testing Your <systemitem class="protocol">SIP</systemitem> ConnectionSIP In the top level CVS checkout of the SIPServer code. - $ cd SIPServer/t + $ cd SIPServer/t - Edit SIPtest.pm, change the $instid, $server, $username, and $password variables. This will be enough to test connectivity. + Edit SIPtest.pm, change the $instid, $server, $username, and + $password variables. This will be enough to test connectivity. To run all tests, you'll need to change all the variables in the Configuration section. - $ PERL5LIB=../ perl 00sc_status.t + $ PERL5LIB=../ perl 00sc_status.t This should produce something like: - 1..4 - ok 1 - Invalid username - ok 2 - Invalid username - ok 3 - login - ok 4 - SC status + +1..4 +ok 1 - Invalid username +ok 2 - Invalid username +ok 3 - login +ok 4 - SC status + - Don't be dismayed at “Invalid Username”. That's just one of the many tests that are run. + Don't be dismayed at Invalid Username. That's just one of the many tests that are run. @@ -199,14 +216,18 @@ More Testing - Once you have opened up either the SIP OR SIP2 ports to be accessible from outside you can do some testing via telnet. You can try this with localhost - if you so wish, but we want to prove that SIP2 works from non-localhost. Replace $instid, $server, $barcode, $username, and $password variables below as - necessary. - We are using 6001 here which is associated with SIP2 as per our configuration. - $ telnet $server 6001 - Connected to $server. - Escape character is '^]'. - 9300CN**$username**|CO**$password**|CP**$instid** + Once you have opened up either the SIP OR SIP2 ports to be + accessible from outside you can do some testing via telnet. You can try this with localhost + if you so wish, but we want to prove that SIP2 works from non-localhost. + Replace $instid, $server, $barcode, $username, + and $password variables below as necessary. + We are using 6001 here which is associated with SIP2 as per our configuration.telnet + +$ telnet $server 6001 +Connected to $server. +Escape character is '^]'. +9300CN**$username**|CO**$password**|CP**$instid** + You should get back. 941 @@ -215,24 +236,28 @@ 2300120080623 172148AO**$instid**|AA**$barcode**|AC$password|AD**$password** You will get back the patron information for $barcode (something similar to the what's below). 24 Y 00120100113 170738AEFirstName MiddleName LastName|AA**$barcode**|BLY|CQY|BHUSD|BV0.00|AFOK|AO**$instid**| - The response declares it is a valid patron (BLY) with a valid password (CQY) and shows the user's $name. + The response declares it is a valid patron BLY with a valid password CQY and shows the user's + $name.
- <systemitem class="protocol">SIP</systemitem> Communication + <systemitem class="protocol">SIP</systemitem> CommunicationSIP - SIP generally communicates over a TCP connection (either raw sockets or over telnet), but can also communicate via serial connections and other methods. In Evergreen, - the most common deployment is a RAW socket connection on port 6001. - SIP communication consists of strings of messages, each message request and response begin with a 2-digit command - Requests usually being an odd + SIP generally communicates over a TCP connection (either raw sockets or over + telnet), but can also communicate via serial connections and other methods. In Evergreen, + the most common deployment is a RAW socket connection on port 6001. + SIP communication consists of strings of messages, each message request and response begin with a 2-digit + command - Requests usually being an odd number and responses usually increased by 1 to be an even number. The combination numbers for the request command and response is often referred to as a Message Pair (for example, a 23 command is a request for patron status, a 24 response is a patron status, and the message pair 23/24 is patron status message pair). The table in the next section shows the message pairs and a description of them. For clarification, the Request is from the device (selfcheck or otherwise) to the ILS/ACS. The response is… the response to the request ;). - Within each request and response, a number of fields (either a fixed width or separated with a '|' [pipe symbol] and preceeded with a 2-character field identifier) + Within each request and response, a number of fields (either a fixed width or separated with a | [pipe symbol] and preceeded with a + 2-character field identifier) are used. The fields vary between message pairs. @@ -346,26 +371,28 @@ 01 Block Patron - A selfcheck will issue a Block Patron command if a patron leaves their card in a selfcheck machine or if the selfcheck detects tampering (such as attempts - to disable multiple items during a single item checkout, multiple failed pin entries, etc). + A selfcheck will issue a Block Patron command if a patron leaves their card in a selfcheck machine or if the selfcheck detects tampering (such as attempts + to disable multiple items during a single item checkout, multiple failed pin entries, etc).SelfCheck In Evergreen, this command does the following: - User alert message: 'CARD BLOCKED BY SELF-CHECK MACHINE' (this is independent of the AL 'Blocked Card Message' field). + User alert message: CARD BLOCKED BY SELF-CHECK MACHINE (this is independent of the AL + Blocked Card Message field). Card is marked inactive. The request looks like: 01<card retained><date>[fields AO, AL, AA, AC] - Card Retained: A single character field of 'Y' or 'N' - tells the ACS whether the SC has retained the card (ex: left in the machine) or not. + Card Retained: A single character field of Y or N - tells the ACS whether the SC has + retained the card (ex: left in the machine) or not. Date: An 18 character field for the date/time when the block occurred. - Format: YYYYMMDDZZZZHHMMSS (ZZZZ being zone - 4 blanks when 'local time', ' Z' (3 blanks and a Z) represents UTC(GMT/Zulu) + Format: YYYYMMDDZZZZHHMMSS (ZZZZ being zone - 4 blanks when local time, Z (3 blanks and a Z) represents UTC(GMT/Zulu) Fields: See Fields for more details. - The response is a 24 “Patron Status Response” with the following: + The response is a 24 Patron Status Response with the following: Charge privileges denied Renewal privileges denied Recall privileges denied (hard-coded in every 24 or 64 response) hold privileges denied - Screen Message 1 (AF): 'blocked' + Screen Message 1 (AF): blocked Patron @@ -374,17 +401,20 @@ 09/10 Checkin The request looks like: 09<No block (Offline)><xact date><return date>[Fields AP,AO,AB,AC,CH,BI] - No Block (Offline): A single character field of 'Y' or 'N' - Offline transactions are not currently supported so send 'N'. + No Block (Offline): A single character field of Y or N - Offline transactions are not currently + supported so send N. xact date: an 18 character field for the date/time when the checkin occurred. Format: YYYYMMDDZZZZHHMMSS (ZZZZ being zone - - 4 blanks when 'local time', ' Z' (3 blanks and a Z) represents UTC(GMT/Zulu) + 4 blanks when local time, Z (3 blanks and a Z) represents UTC(GMT/Zulu) Fields: See Fields for more details. The response is a 10 Checkin Response with the following: 10<resensitize><magnetic media><alert><xact date>[Fields AO,AB,AQ,AJ,CL,AA,CK,CH,CR,CS,CT,CV,CY,DA,AF,AG] Example (with a remote hold): 09N20100507 16593720100507 165937APCheckin Bin 5|AOBR1|AB1565921879|ACsip_01| 101YNY20100623 165731AOBR1|AB1565921879|AQBR1|AJPerl 5 desktop reference|CK001|CSQA76.73.P33V76 1996|CTBR3|CY373827|DANicholas Richard Woodard|CV02| - Here you can see a hold alert for patron (CY) 373827, named (DA) Nicholas Richard Woodard, to be picked up at (CT) BR3. Since the transaction is happening - at (AO) BR1, the alert type (CV) is 02 for “hold at remote library”. The possible values for CV are: + Here you can see a hold alert for patron CY 373827, named DA Nicholas Richard Woodard, + to be picked up at CT BR3. Since the transaction is happening + at AO BR1, the alert type CV is 02 for hold at remote library. + The possible values for CV are: 00: unknown 01: local hold @@ -394,15 +424,17 @@ 99: other - the logic for EG to determine the content is magnetic_media comes from either legacy circ scripts or search_config_circ_modifier. The default is non-magnetic. - The same is true for media_type (default 001). EG does not populate the collection_code because it does not really have any, but it will provide the call_number where - available. - Unlike the item_id (barcode), the title_id is actually a title string, unless the configuration forces the return of the bib ID. + the logic for Evergreen to determine the content is magnetic_media comes from either legacy circ scripts or search_config_circ_modifier. + The default is non-magnetic.magnetic media + The same is true for media_type (default 001). Evergreen does not populate the collection_code because it does not really have any, but it will provide the + call_number where available. + Unlike the item_id (barcode), the title_id is actually a title string, unless the configuration forces the return of + the bib ID. Don't be confused by the different branches that can show up in the same response line. - AO is where the transaction took place, - AQ is the permanent location, and - CT is the destination location (i.e., pickup lib for a hold or target lib for a transfer). + AO is where the transaction took place, + AQ is the permanent location, and + CT is the destination location (i.e., pickup lib for a hold or target lib for a transfer). @@ -417,7 +449,7 @@ 17/18 Item Information The request looks like: 17<xact_date>[fields: AO,AB,AC] - The request is very terse. AC is optional. + The request is very terse. AC is optional. The following response structure is for SIP2. (Version 1 of the protocol had only 6 total fields.) 18<circulation_status><security_marker><fee_type><xact_date>[fields: CF,AH,CJ,CM,AB,AJ,BG,BH,BV,CK,AQ,AP,CH,AF,AG,+CT,+CS] Example: @@ -426,9 +458,9 @@ 1720060110 215612AOBR1|AB1565921879| 1810020120100623 171415AB1565921879|AJPerl 5 desktop reference|CK001|AQBR1|APBR1|BGBR1|CTBR3|CSQA76.73.P33V76 1996| The first case is with a bogus barcode. The latter shows an item with a circulation_status of 10 for in transit between libraries. - The known values of circulation_status are enumerated in the spec. - EXTENSIONS: The CT field for destination location and CS call number are used by Automated Material - Handling systems. + The known values of circulation_status are enumerated in the spec. + EXTENSIONS: The CT field for destination location and CS call number are used by + Automated Material Handling systems.Automated Material Handling (AMH) 19/20 Item Status Update @@ -443,14 +475,16 @@ 2300120060101 084235AOCONS|AA999999|ACsip_01|ADuserpassword|LY|CQN|BHUSD|BV0.00|AFOK|AOCONS| 24 Y 00120100507 022803AEDoug Fiander|AA999999|BLY|CQY|BHUSD|BV0.00|AFOK|AOCONS| - The BL field (SIP2, optional) is valid patron, so the N value means + The BL field (SIP2, optional) is valid patron, so the + N value means bad_barcode doesn't match a patron, the Y value means 999999 does. - The CQ field (SIP2, optional) is valid password, so the N + The CQ field (SIP2, optional) is valid password, so the N value means bad_password doesn't match 999999's password, the Y means userpassword does. - So if you were building the most basic SIP2 authentication client, you would check for |CQY| in the response to know the user's barcode and password - are correct (|CQY| implies |BLY|, since you cannot check the password unless the barcode exists). However, in practice, + So if you were building the most basic SIP2 authentication client, you would check for + |CQY| in the response to know the user's barcode and password + are correct (|CQY| implies |BLY|, since you cannot check the password unless the barcode exists). However, in practice, depending on the application, there are other factors to consider in authentication, like whether the user is blocked from checkout, owes excessive fines, reported their card lost, etc. These limitations are reflected in the 14-character patron status string immediately following the 24 code. See the field definitions in your copy of the spec. @@ -461,14 +495,14 @@ 29/30 Renew - EG ACS status message indicates Renew is supported. + Evergreen ACS status message indicates renew is supported. 35/36 End Session 3520100505 115901AOBR1|AA999999| 36Y20100507 161213AOCONS|AA999999|AFThank you!| - The Y/N code immediately after the 36 indicates success/failure. Failure is not particularly meaningful or important in this context, and for evergreen it - is hardcoded Y. + The Y/N code immediately after the 36 indicates success/failure. Failure is not particularly meaningful or + important in this context, and for evergreen it is hardcoded Y. 37/38 Fee Paid @@ -483,7 +517,7 @@ 6300020060329 201700 AOBR1|AA999999|ADbadpwd| 64 Y 00020100623 141130000000000000000000000000AA999999|AEDavid J. Fiander|BHUSD|BV0.00|BD2 Meadowvale Dr. St Thomas, ON Canada 90210|BEdjfiander@somemail.com|BF(519) 555 1234|AQBR1|BLY|CQN|PB19640925|PCPatrons|PIUnfiltered|AFOK|AOBR1| - See 23/24 Patron Status for info on BL and CQ fields. + See 23/24 Patron Status for info on BL and CQ fields. 65/66 Renew All @@ -497,7 +531,7 @@ ... 9300CNsip_01|COsip_01|CPBR1| 941 - 941 means successful terminal login. 940 or getting dropped means failure. + 941 means successful terminal login. 940 or getting dropped means failure. 97/96 Resend @@ -510,8 +544,8 @@ status code - 1 character: 0: SC is OK - SC is out of paper - SC shutting down + 1: SC is out of paper + 2: SC shutting down max print width - 3 characters - the integer number of characters the client can print protocol version - 4 characters - x.xx @@ -522,7 +556,7 @@ Example: 9910302.00 98YYYYNN60000320100510 1717202.00AOCONS|BXYYYYYYYYYNYNNNYN| - The Supported Messages field (BX) appears only in SIP2, and specifies whether 16 different + The Supported Messages field BX appears only in SIP2, and specifies whether 16 different SIP commands are supported by the ACS or not. diff --git a/1.6/admin/troubleshooting.xml b/1.6/admin/troubleshooting.xml index a5e7aeeecc..99b46c617b 100644 --- a/1.6/admin/troubleshooting.xml +++ b/1.6/admin/troubleshooting.xml @@ -17,11 +17,13 @@ xmlns:xl="http://www.w3.org/1999/xlink" version="5.0" xml:id="troubleshooting"> Stop OpenSRF:OpenSRF osrf_ctl.sh -l -a stop_all You should get either output simlar to this: - Stopping OpenSRF C process 12515... - Stopping OpenSRF C process 12520... - Stopping OpenSRF C process 12526... - Stopping OpenSRF Perl process 12471... - Stopping OpenSRF Router process 12466... + +Stopping OpenSRF C process 12515... +Stopping OpenSRF C process 12520... +Stopping OpenSRF C process 12526... +Stopping OpenSRF Perl process 12471... +Stopping OpenSRF Router process 12466... + Or, if services have already been stopped, output may look like this: OpenSRF C not running OpenSRF Perl not running @@ -65,18 +67,18 @@ xmlns:xl="http://www.w3.org/1999/xlink" version="5.0" xml:id="troubleshooting"> OpenSRFservicesperl /openils/bin/osrf_ctl.sh -l -a start_perl You should see the output similar to the following: - - Starting OpenSRF Perl - * starting all services for ... - * starting service pid=7484 opensrf.settings - * starting service pid=7493 open-ils.cat - * starting service pid=7495 open-ils.supercat - * starting service pid=7497 open-ils.search - * starting service pid=7499 open-ils.circ - * starting service pid=7501 open-ils.actor - * starting service pid=7502 open-ils.storage - ... - + +Starting OpenSRF Perl +* starting all services for ... +* starting service pid=7484 opensrf.settings +* starting service pid=7493 open-ils.cat +* starting service pid=7495 open-ils.supercat +* starting service pid=7497 open-ils.search +* starting service pid=7499 open-ils.circ +* starting service pid=7501 open-ils.actor +* starting service pid=7502 open-ils.storage +... + If the perl services do not start correctly or you receive errors, search for errors in the following log files: @@ -110,18 +112,18 @@ xmlns:xl="http://www.w3.org/1999/xlink" version="5.0" xml:id="troubleshooting"> As user opensrf, you invoke autogen with the command: /openils/bin/autogen.sh -c /openils/conf/opensrf_core.xml -u If Autogen completes successfully, the output will be: - - Updating fieldmapper - Updating web_fieldmapper - Updating OrgTree - removing OrgTree from the cache... - Updating OrgTree HTML - Updating locales selection HTML - Updating Search Groups - Refreshing proximity of org units - Successfully updated the organization proximity - Done - + +Updating fieldmapper +Updating web_fieldmapper +Updating OrgTree +removing OrgTree from the cache... +Updating OrgTree HTML +Updating locales selection HTML +Updating Search Groups +Refreshing proximity of org units +Successfully updated the organization proximity +Done + If Autogen does not complete its task and you receive errors, use grep to find errors in the log files: grep ERR /openils/var/log/*.log @@ -139,31 +141,31 @@ xmlns:xl="http://www.w3.org/1999/xlink" version="5.0" xml:id="troubleshooting"> At the srfsh prompt, enter this command: login admin open-ils You should the request verification: - - Received Data: "6f63ff5542da1fead4431c6c280efc75" - ------------------------------------ - Request Completed Successfully - Request Time in seconds: 0.018414 - ------------------------------------ - - Received Data: { - "ilsevent":0, - "textcode":"SUCCESS", - "desc":" ", - "pid":7793, - "stacktrace":"oils_auth.c:312", - "payload":{ - "authtoken":"28804ebf99508496e2a4d2593aaa930e", - "authtime":420.000000 - } - } - - ------------------------------------ - Request Completed Successfully - Request Time in seconds: 0.552430 - ------------------------------------ - Login Session: 28804. Session timeout: 420.000 - srfsh# + +Received Data: "6f63ff5542da1fead4431c6c280efc75" +------------------------------------ +Request Completed Successfully +Request Time in seconds: 0.018414 +------------------------------------ + +Received Data: { +"ilsevent":0, +"textcode":"SUCCESS", +"desc":" ", +"pid":7793, +"stacktrace":"oils_auth.c:312", +"payload":{ +"authtoken":"28804ebf99508496e2a4d2593aaa930e", + "authtime":420.000000 +} +} + +------------------------------------ +Request Completed Successfully +Request Time in seconds: 0.552430 +------------------------------------ +Login Session: 28804. Session timeout: 420.000 +srfsh# If you encounter errors or if you are unable to connect, you should consult the srfsh.log file. The location of this file is configured in your logssrfsh.log .srfsh.xml configuration file and is diff --git a/1.6/admin/z3950.xml b/1.6/admin/z3950.xml index f2d99dd1b9..2f5b769bc6 100644 --- a/1.6/admin/z3950.xml +++ b/1.6/admin/z3950.xml @@ -2,44 +2,42 @@ - SRU and Z39.50 Server + <systemitem class="protocol">SRU</systemitem> and <systemitem class="protocol">Z39.50</systemitem> Server - Evergreen is extremely scalable and can serve the need of a large range of libraries. The specific requirements and configuration of your system should be determined based on your specific needs of your organization or consortium. - -
- Testing SRU with yaz-client + Testing SRU with yaz-clientyaz - yaz-client is installed as a part of Index Data's YAZ software. Recent versions include support for querying SRU servers. Evergreen ships an SRU configuration - that works out of the box. To search Evergreen with yaz-client, choose the GET query method and issue the find command. - In the following example, we connect to the Evergreen test server dev.gapines.org; substitute this hostname with your own Evergreen server - hostname: - Some older versions of yaz-client have known issues with SRU. Ensure that you are using the latest edition of yaz from + yaz-client is installed as a part of Index Data's YAZ software. Recent versions include support for querying SRU servers. + Evergreen ships an SRU configuration SRU + that works out of the box. To search Evergreen with yaz-client, choose the GET query method and issue the find command. + In the following example, we connect to the Evergreen test server dev.gapines.org - substitute this hostname with your own + Evergreen server hostname: + Some older versions of yaz-client have known issues with SRU. Ensure that you are using the latest edition of yaz from http://www.indexdata.com/yaz. - $ yaz-client http://dev.gapines.org/opac/extras/sru - Z> sru GET 1.1 - Z> find hemingway + $ yaz-client http://dev.gapines.org/opac/extras/sru + Z> sru GET 1.1 + Z> find hemingway - If your database has records that match that term, you will get the corresponding MARCXML records in your response from yaz-client. + If your database has records that match that term, you will get the corresponding MARCXML records + in your response from yaz-client.MARCXML Here's what the SRU request looks like as sent to the Evergreen web server: - GET /opac/extras/sru?version=1.1&operation=searchRetrieve&query=hemingway&maximumRecords=0 + GET /opac/extras/sru?version=1.1&operation=searchRetrieve&query=hemingway&maximumRecords=0 You can see what the response looks like by hitting the same URL in your Web browser: http://dev.gapines.org/opac/extras/sru?version=1.1&operation=searchRetrieve&query=hemingway&maximumRecords=0 - CQL queries - Evergreen supports some CQL index-sets for advanced queries such as a subset of Dublin Core (DC) elements. Those DC elements that are - supported map to Evergreen default indexes as follows: - - + CQL queries + Evergreen supports some CQL CQL index-sets for advanced queries such as a subset of + Dublin Core (DC) elements. Those DC elements that are + supported map to Evergreen default indexes as follows:Dublin Core + DC element Evergreen index - @@ -82,118 +80,124 @@ - Here are a few examples of SRU searches against some of these indexes: + Here are a few examples of SRU searches against some of these indexes: dc.title all complete dinosaur dc.subject all britain france dc.title exact The Empire Strikes Back dc.author=king and dc.title=zone -
- Setting up Z39.50 server support + Setting up <systemitem class="protocol">Z39.50</systemitem> server supportZ39.50 - You must have Evergreen's SRU server running before you can enable Z39.50 server support. - This support uses an Z39.50-to-SRU translator service supplied by the Net::Z3950::Simple2ZOOM Perl module to enable Evergreen to act as a Z39.50 server. - You could run the Z39.50 server on a different machine. It just needs to be able to connect to the Evergreen SRU server. + You must have Evergreen's SRU server running before you can enable Z39.50 server support. + + This support uses an Z39.50-to-SRU translator service supplied + by the Net::Z3950::Simple2ZOOMSimple2ZOOM Perl module to enable Evergreen to act as a Z39.50 server. + You could run the Z39.50 server on a different machine. It just needs to be able to connect to the + Evergreen SRU server. - Setting up the Z39.50 server + Setting up the <systemitem class="protocol">Z39.50</systemitem> server Install a recent version of yaz (the Makefile.install should have installed a suitable version). - Install Net::Z3950::Simple2ZOOM (sudo cpan Net::Z3950::Simple2ZOOM) + Install Net::Z3950::Simple2ZOOM (sudo cpan Net::Z3950::Simple2ZOOM) - Create a Simple2ZOOM configuration file. Something like the following is a good start, and is based on the Simple2ZOOM documentation example. - We'll name the file dgo.conf for our example: - - <client> - <database name="gapines"> - <zurl>http://dev.gapines.org/opac/extras/sru</zurl> - <option name="sru">get</option> - <charset>marc-8</charset> - <search> - <querytype>cql</querytype> - <map use="4"><index>eg.title</index></map> - <map use="7"><index>eg.keyword</index></map> - <map use="8"><index>eg.keyword</index></map> - <map use="21"><index>eg.subject</index></map> - <map use="1003"><index>eg.author</index></map> - <map use="1018"><index>eg.publisher</index></map> - <map use="1035"><index>eg.keyword</index></map> - <map use="1016"><index>eg.keyword</index></map> - </search> - </database> - </client> - + Create a Simple2ZOOM configuration file. Something like the following is a good start, and is + based on the Simple2ZOOM + documentation example. We'll name the file dgo.conf for our example: + +<client> + <database name="gapines"> + <zurl>http://dev.gapines.org/opac/extras/sru</zurl> + <option name="sru">get</option> + <charset>marc-8</charset> + <search> + <querytype>cql</querytype> + <map use="4"><index>eg.title</index></map> + <map use="7"><index>eg.keyword</index></map> + <map use="8"><index>eg.keyword</index></map> + <map use="21"><index>eg.subject</index></map> + <map use="1003"><index>eg.author</index></map> + <map use="1018"><index>eg.publisher</index></map> + <map use="1035"><index>eg.keyword</index></map> + <map use="1016"><index>eg.keyword</index></map> + </search> + </database> +</client> + You can have multiple <database> sections in a single file, each pointing to a different scope of your consortium. The name attribute on - the <database> element is used in your Z39.50 connection string to name the database. The <zurl> element must point to - http://hostname/opac/extras/sru. As of Evergreen 1.6, you can append an optional organization unit shortname for search + the <database> element is used in your Z39.50 connection string to name the database. The + <zurl> element must point to + http://hostname/opac/extras/sru. As of Evergreen 1.6, you can append an optional organization unit shortname for search scoping purposes, and you can also append /holdings if you want to expose the holdings for any returned records. So your zurl - could be http://dev.gapines.org/opac/extras/sru/BR1/holdings to limit the search scope to BR1 and its children, and + could be http://dev.gapines.org/opac/extras/sru/BR1/holdings to limit the search scope to BR1 and its children, and to expose its holdings. - Run simple2ZOOM as a daemon, specifying the configuration files and one or more listener addresses that the Z39.50 server will be accessible on. - If you do not specify a port, it will automatically run on port 9999. In the following example, we tell it to listen both to localhost on port 2210, - and on dev.gapines.org on port 210: - - <yazgfs> - <server id="server1"> - <retrievalinfo> - <retrieval syntax="xml"/> - <retrieval syntax="marc21"> - <backend syntax="xml"> - <marc inputformat="xml" outputformat="marc" inputcharset="utf-8" outputcharset="marc-8"/> - </backend> - </retrieval> - </retrievalinfo> - </server> - </yazgfs> - + Run simple2ZOOM as a daemon, specifying the configuration files and one or more listener addresses that the + Z39.50 server will + be accessible on. If you do not specify a port, it will automatically run on port 9999. In the following example, + we tell it to listen both to localhost on port 2210, and on dev.gapines.org + n port 210: + + <yazgfs> + <server id="server1"> + <retrievalinfo> + <retrieval syntax="xml"/> + <retrieval syntax="marc21"> + <backend syntax="xml"> + <marc inputformat="xml" outputformat="marc" inputcharset="utf-8" outputcharset="marc-8"/> + </backend> + </retrieval> + </retrievalinfo> + </server> +</yazgfs> + - Run simple2ZOOM as a daemon, specifying the configuration files and one or more listener addresses that the Z39.50 server will be accessible on. - If you do not specify a port, it will automatically run on port 9999. In the following example, we tell it to listen both to localhost on port 2210, - and on dev.gapines.org on port 210: - simple2zoom -c dgo.conf -- -f xml2marc-yaz.cfg localhost:2210 dev.gapines.org:210 + Run simple2ZOOM as a daemon, specifying the configuration files and one or more listener addresses that + the Z39.50 server will be accessible on. + If you do not specify a port, it will automatically run on port 9999. In the following example, we tell it to listen both to localhost on port 2210, and on dev.gapines.org on port 210: + simple2zoom -c dgo.conf -- -f xml2marc-yaz.cfg localhost:2210 dev.gapines.org:210 - To test the Z39.50 server, we can use yaz-client again: - - yaz-client - Z> open localhost:2210/gapines - Connecting...OK. - Sent initrequest. - Connection accepted by v3 target. - ID : 81/81 - Name : Simple2ZOOM Universal Gateway/GFS/YAZ - Version: 1.03/1.128/3.0.34 - Options: search present delSet triggerResourceCtrl scan sort namedResultSets - Elapsed: 0.010718 - Z> format marcxml - Z> find dc.title=zone and dc.author=king - Sent searchRequest. - Received SearchResponse. - Search was a success. - Number of hits: 0, setno 4 - records returned: 0 - Elapsed: 0.611432 - Z> find dead zone - Sent searchRequest. - Received SearchResponse. - Search was a success. - Number of hits: 4, setno 5 - records returned: 0 - Elapsed: 1.555461 - Z> show 1 - Sent presentRequest (1+1). - Records: 1 - []Record type: XML - <record xmlns:... (rest of record deliberately truncated) - + To test the Z39.50 server, we can use yaz-client again: + +yaz-client +Z> open localhost:2210/gapines +Connecting...OK. +Sent initrequest. +Connection accepted by v3 target. +ID : 81/81 +Name : Simple2ZOOM Universal Gateway/GFS/YAZ +Version: 1.03/1.128/3.0.34 +Options: search present delSet triggerResourceCtrl scan sort namedResultSets +Elapsed: 0.010718 +Z> format marcxml +Z> find dc.title=zone and dc.author=king +Sent searchRequest. +Received SearchResponse. +Search was a success. +Number of hits: 0, setno 4 +records returned: 0 +Elapsed: 0.611432 +Z> find dead zone +Sent searchRequest. +Received SearchResponse. +Search was a success. +Number of hits: 4, setno 5 +records returned: 0 +Elapsed: 1.555461 +Z> show 1 +Sent presentRequest (1+1). +Records: 1 +[]Record type: XML +<record xmlns:... (rest of record deliberately truncated) +
-- 2.43.2