source: documentation/trunk/manuals/xml-source/en/Install_en.xml@ 25088

Last change on this file since 25088 was 16346, checked in by anna, 16 years ago

Added a subsection about installing Greenstone on Vista.

  • Property svn:keywords set to Author Date Id Revision
File size: 73.5 KB
Line 
1<?xml version="1.0" encoding="UTF-8"?>
2<!DOCTYPE Manual [
3 <!ENTITY nbsp "&#160;">
4 <!ENTITY rarr "&#8594;">
5 <!ENTITY mdash "&#8212;">
6 <!ENTITY copy "&#169;">
7]>
8<Manual id="Install" lang="en">
9<Heading>
10<Text id="1">GREENSTONE DIGITAL LIBRARY</Text>
11</Heading>
12<Title>
13<Text id="2">INSTALLER'S GUIDE</Text>
14</Title>
15<Author>
16<Text id="3">Ian H. Witten and Stefan Boddie</Text>
17</Author>
18<Affiliation>
19<Text id="4">Department of Computer Science <br/>University of Waikato, New Zealand</Text>
20</Affiliation>
21<SupplementaryText>
22<Text id="manual_index">Back to manual index</Text>
23<Text id="top_index">Back to top index</Text>
24</SupplementaryText>
25<Text id="5">Greenstone is a suite of software for building and distributing digital library collections. It provides a new way of organizing information and publishing it on the Internet or on CD-ROM. Greenstone is produced by the New Zealand Digital Library Project at the University of Waikato, and developed and distributed in cooperation with UNESCO and the Human Info NGO. It is open-source software, available from <i>http://greenstone.org</i> under the terms of the Gnu General Public License.</Text>
26<Comment>
27<Text id="6">We want to ensure that this software works well for you. Please report any problems to <i>[email protected]</i></Text>
28</Comment>
29<Version>
30<Text id="7">Greenstone gsdl-2.50</Text>
31</Version>
32<Date>
33<Text id="8">March 2004</Text>
34</Date>
35<Section id="about_this_manual">
36<Title>
37<Text id="9">About this manual</Text>
38</Title>
39<Content>
40<Text id="10">This document explains how to install Greenstone so that you can run it on your own computer. It also describes how to obtain associated software that is freely available—the Apache Webserver and Perl. We have striven to make the installation procedure as simple as it possibly can be.</Text>
41<Text id="11">The software runs on different platforms, and in different configurations. Consequently there are many issues that affect (or might affect) the installation procedure. Section <CrossRef target="Chapter" ref="versions_of_greenstone"/> mentions some questions that you will need to consider before installing Greenstone. Section <CrossRef target="Chapter" ref="installation_procedure"/> details the installation procedure for all the different versions; you need only read the part that relates to your operating system. Section <CrossRef target="Chapter" ref="greenstone_collections"/> describes the demonstration digital library collections that are included in the distribution. Section <CrossRef target="Chapter" ref="setting_up_webserver"/> explains how to set up common webservers, Apache and Microsoft PWS/IIS, to work with Greenstone. Section <CrossRef target="Chapter" ref="configuring_your_site"/> describes various Greenstone configuration options, and Section <CrossRef target="Chapter" ref="personalizing"/> shows how to make a personalized home page for your digital library installation. Finally, an Appendix <CrossRef target="Chapter" ref="appendix_associated_software"/> lists pieces of associated software and how to obtain them.</Text>
42</Content>
43</Section>
44<Section id="companion_documents">
45<Title>
46<Text id="12">Companion documents</Text>
47</Title>
48<Content>
49<Text id="13">The complete set of Greenstone documents include five volumes:</Text>
50<BulletList>
51<Bullet>
52<Text id="14">Greenstone Digital Library Installer's Guide <i>(this document)</i></Text>
53</Bullet>
54<Bullet>
55<Text id="15">Greenstone Digital Library User's Guide</Text>
56</Bullet>
57<Bullet>
58<Text id="16">Greenstone Digital Library Developer's Guide</Text>
59</Bullet>
60<Bullet>
61<Text id="17">Greenstone Digital Library: From Paper to Collection</Text>
62</Bullet>
63<Bullet>
64<Text id="18">Greenstone Digital Library: Using the Organizer</Text>
65</Bullet>
66</BulletList>
67</Content>
68</Section>
69<Section id="copyright">
70<Title>
71<Text id="copyright-title">Copyright</Text>
72</Title>
73<Content>
74<Text id="right-text-1">Copyright &copy; 2002 2003 2004 2005 2006 2007 by the <Link url="http://www.nzdl.org">New Zealand Digital Library Project</Link> at <Link url="http://www.waikato.ac.nz">the University of Waikato</Link>, New Zealand.</Text>
75<Text id="right-text-2">Permission is granted to copy, distribute and/or modify this document under the terms of the <Link url="http://www.gnu.org/licenses/fdl.html">GNU Free Documentation License</Link>, Version 1.2 or any later version published by the Free Software Foundation; with no Invariant Sections, no Front-Cover Texts, and no Back-Cover Texts. A copy of the license is included in the section entitled <Link url="http://greenstonewiki.cs.waikato.ac.nz/wiki/gsdoc/GNUFDL.html">“GNU Free Documentation License.”</Link></Text>
76</Content>
77</Section>
78<Section id="acknowledgements">
79<Title>
80<Text id="19">Acknowledgements</Text>
81</Title>
82<Content>
83<Text id="20">The Greenstone software is a collaborative effort between many people. Rodger McNab and Stefan Boddie are the principal architects and implementors. Contributions have been made by David Bainbridge, George Buchanan, Hong Chen, Michael Dewsnip, Katherine Don, Elke Duncker, Carl Gutwin, Geoff Holmes, Dana McKay, John McPherson, Craig Nevill-Manning, Dynal Patel, Gordon Paynter, Bernhard Pfahringer, Todd Reed, Bill Rogers, John Thompson, and Stuart Yeates. Other members of the New Zealand Digital Library project provided advice and inspiration in the design of the system: Mark Apperley, Sally Jo Cunningham, Matt Jones, Steve Jones, Te Taka Keegan, Michel Loots, Malika Mahoui, Gary Marsden, Dave Nichols and Lloyd Smith. We would also like to acknowledge all those who have contributed to the GNU-licensed packages included in this distribution: MG, GDBM, PDFTOHTML, PERL, WGET, WVWARE and XLHTML.</Text>
84</Content>
85</Section>
86<Chapter id="versions_of_greenstone">
87<Title>
88<Text id="21">Versions of Greenstone</Text>
89</Title>
90<Content>
91<Text id="22">The Greenstone software runs on different platforms, and in different configurations, as summarized in Figure <CrossRef target="Figure" ref="different_options"/>.</Text>
92<Figure id="different_options">
93<Title>
94<Text id="23">The different options for Windows and Unix versions of Greenstone</Text>
95</Title>
96<File width="542" height="264" url="images/Install_Fig_1.gif"/>
97</Figure>
98<Text id="24">There are many issues that affect (or might affect) the installation procedure. Before reading on, you should consider these questions:</Text>
99<BulletList>
100<Bullet>
101<Text id="25">Are you using Windows or Unix?</Text>
102</Bullet>
103<Bullet>
104<Text id="26">If Windows, are you using Windows 3.1/3.11 or a more recent version? Although you can view collections on 3.1/3.11 machines, and serve other computers on the same network, you cannot build new collections. The full Greenstone software runs on 95/98/Me, and NT/2000.</Text>
105</Bullet>
106<Bullet>
107<Text id="27">If Unix, are you using Linux or another version of Unix? For Linux, a binary version of the complete system is provided which is easy to install. For other types of Unix you will have to install the source code and compile it. This may require you to install some additional software on your machine.</Text>
108</Bullet>
109<Bullet>
110<Text id="28">If Windows NT/2000 or Unix, can you log in as the system “administrator” or “root”? This may be required to configure a webserver appropriately for Greenstone.</Text>
111</Bullet>
112<Bullet>
113<Text id="29">Do you want the source code? If you are using Windows or Linux, you can just install binaries. But you may want the source code as well—it's in the Greenstone distribution.</Text>
114</Bullet>
115<Bullet>
116<Text id="30">Do you want to build new digital library collections? If so, you need to have Perl, which is freely available for both Windows and Unix.</Text>
117</Bullet>
118<Bullet>
119<Text id="31">Is your computer running a webserver? The Greenstone software comes with a Windows webserver. However, if you are already running a Web server, you may want to stay with it. For Unix, you need to run a webserver.</Text>
120</Bullet>
121<Bullet>
122<Text id="32">Do you know how to reconfigure your webserver? If you don't use the Greenstone webserver, you will have to reconfigure your existing one slightly to recognize the Greenstone software.</Text>
123</Bullet>
124</BulletList>
125</Content>
126</Chapter>
127<Chapter id="installation_procedure">
128<Title>
129<Text id="33">The Installation Procedure</Text>
130</Title>
131<Content>
132<Text id="34">Versions of Greenstone are available for both Windows and Unix, as binaries and in source code form. The Greenstone user interface uses a Web browser: Netscape Navigator or Internet Explorer (version 4.0 or greater in both cases) are both suitable. In case you don't already have a Web browser, Windows versions of Netscape are provided on the CD-ROM.</Text>
133<Section id="windows">
134<Title>
135<Text id="35">Windows</Text>
136</Title>
137<Content>
138<Text id="36">If you are a Unix user, please skip ahead to Section <CrossRef target="Section" ref="unix"/>. For Windows users, if you want just a simple, straightforward installation, go through the following “simple installation” procedure. The Greenstone system occupies about 40 Mb of disk space. For Windows Vista user, go to the <CrossRef target="Subsection" ref="vista"/> for more instructions on getting Greenstone running on Vista.</Text>
139<Text id="37">If you choose anything other than the default setup, you will have to decide whether you want to install the binary code or the source code. If in doubt, choose the binary code. The installation procedure is the same for both. The following sections tell you more about the options you will be presented with.</Text>
140<Text id="38">When you've finished installation you should skip ahead to Section <CrossRef target="Section" ref="how_to_find_greenstone"/>.</Text>
141<Subsection id="simple_installation">
142<Title>
143<Text id="39">Simple installation</Text>
144</Title>
145<Content>
146<Text id="40">To install the Windows version from the CD-ROM, insert the disk into the drive (e.g. into <i>D:</i>). If the installation procedure does not start automatically after about 20 seconds, click on the <i>Start</i> menu, select <i>Run</i> and type <i>D:\setup.exe</i>, where “ <i>D</i> ” is the letter that identifies your CD-ROM drive. For Windows 3.1, select <i>Run</i> from the “File manager” and type <i>D:\Windows\win3.1\setup.exe</i>.</Text>
147<Text id="41">For the simplest installation, just accept the default at each point by clicking the <i>Next</i> button. That's all you need to do! Greenstone is installed in the directory <i>C:\Program Files\gsdl</i>.</Text>
148<Text id="42">Once installation is complete, to start your Greenstone system click on the <i>Start</i> button, open the <i>Program</i> menu, and select <i>Greenstone Digital Library</i>. This brings up a dialogue box: just click <i>Enter Library.</i> This automatically starts your Internet browser and loads the Greenstone Digital Library home page, which should look something like the example in Figure <CrossRef target="Figure" ref="your_greenstone_home_page"/>. You enter the Greenstone Demo collection by clicking on its icon.</Text>
149<Figure id="your_greenstone_home_page">
150<Title>
151<Text id="43">Your Greenstone home page</Text>
152</Title>
153<File width="395" height="327" url="images/Install_Fig_2.png"/>
154</Figure>
155</Content>
156</Subsection>
157<Subsection id="windows_binaries">
158<Title>
159<Text id="44">Windows binaries</Text>
160</Title>
161<Content>
162<Text id="45">There are two separate Windows binary programs on the CD-ROM: the <i>Local Library</i> and the <i>Web Library</i>. The default installation described above selects the Local Library version. We strongly recommend that you use this version. The Web Library, which is much harder to set up, is only necessary if you already run a web server and want to use it for Greenstone. Despite its modest name, the Local Library offers a complete, self-contained, web-serving capability.</Text>
163<Text id="46">Local Library. This enables any Windows computer to serve pre-built Greenstone collections. The Greenstone Demo collection will automatically be installed; you can also install the other collections on the CD-ROM (Section <CrossRef target="Chapter" ref="greenstone_collections"/>). The Local Library software is the same as that used on CD-ROMs produced by the Greenstone system.</Text>
164<Text id="47">The Local Library is intended for use on standalone computers or computers that do not already have webserver software. It contains a small built-in webserver so that other computers on the same network can also access the library. (However, the webserver has limited configurability.)</Text>
165<Text id="48">The Local Library software automatically determines whether your computer has network software installed or is connected to a network. It operates correctly under any combinations of these conditions. However, there are two possible problems that may be encountered. Greenstone may</Text>
166<BulletList>
167<Bullet>
168<Text id="49">cause an unwanted telephone dialup operation;</Text>
169</Bullet>
170<Bullet>
171<Text id="50">fail to run because network software is installed, but installed incorrectly.</Text>
172</Bullet>
173</BulletList>
174<Text id="51">A restricted version of the Local Library is supplied which is intended for use in these situations. The restricted version only works with Netscape (not Internet Explorer). When you invoke the Local Library version of Greenstone, the dialogue box contains a button that allows you to use the restricted version instead. Unless the above problems arise, you should always use the standard version.</Text>
175<Text id="52"><b>Web Library</b>. This enables any computer with an existing webserver to serve pre-built Greenstone collections. As with the Local Library above, the Greenstone Demo collection will automatically be installed. You can also install the other collections on the CD-ROM (see Section <CrossRef target="Chapter" ref="greenstone_collections"/>).</Text>
176<Text id="53">The Web Library differs from the Local Library because it is intended for computers that already have webserver software.</Text>
177<Text id="54">To run the Web Library, you also need</Text>
178<BulletList>
179<Bullet>
180<Text id="55">Webserver software. One possibility is Apache (see Appendix <CrossRef target="Chapter" ref="appendix_associated_software"/>).</Text>
181</Bullet>
182<Bullet>
183<Text id="56"><b>The Collector</b>. This component, which is included in both the Local Library and the Web Library, allows you to build collections containing material of your choice. (You will not be able to use the Collector on a Windows 3.1/3.11 machine.)</Text>
184</Bullet>
185</BulletList>
186</Content>
187</Subsection>
188<Subsection id="windows_webserver_configuration">
189<Title>
190<Text id="57">Windows webserver configuration (Web Library version only)</Text>
191</Title>
192<Content>
193<Text id="58">An advantage of the Local Library version of Greenstone is that it runs “out of the box” and does not require any special configuration. For the Web Library version, however, you will have to make some adjustments to your webserver setup.</Text>
194<Text id="59">If you already have a webserver, some small changes have to be made to its configuration to make your Greenstone installation operate. The install script explains what these are for the Apache webserver—see Section <CrossRef target="Section" ref="pws_and_iis_webservers"/> for instructions for configuring the PWS and IIS webservers. You may need help from a system administrator to reconfigure an existing webserver—they should be able to understand the instructions printed by the install script.</Text>
195<Text id="60">If you do not already have a webserver, you will have to install one. (See the Appendix <CrossRef target="Chapter" ref="appendix_associated_software"/> for information on the Apache webserver.) Then you will have to configure it appropriately. Section <CrossRef target="Chapter" ref="setting_up_webserver"/> gives a detailed account of the parts of a webserver installation that affect Greenstone, and how they need to be altered. It comes down to including half a dozen or so lines in a configuration file.</Text>
196</Content>
197</Subsection>
198<Subsection id="windows_source">
199<Title>
200<Text id="61">Windows source</Text>
201</Title>
202<Content>
203<Text id="62">The Greenstone source code occupies 50 Mb of disk space, but to compile it you will need about 90 Mb. To compile the source on Windows you need</Text>
204<BulletList>
205<Bullet>
206<Text id="63">The Microsoft Visual C++ compiler. (We are currently sorting out some minor problems in compiling Greenstone with various Windows ports of GNU GCC.)</Text>
207</Bullet>
208</BulletList>
209<Text id="64">(You do not need GDBM, the Gnu database manager, because it is included in the Greenstone source distribution.)</Text>
210<Text id="65">It is unlikely that you will be able to compile Greenstone on a Windows 3.1/3.11 machine.</Text>
211<Text id="66">In the event that you recompile Greenstone and wish to use the recompiled version to create CD-ROMs, you should note that code produced by recent versions of the Visual C++ compiler does not run under Windows 3.1/3.11, although there is no problem with later Windows systems (95, 98, Me, NT, 2000). If you want your CD-ROMs to operate on early Windows machines, you will need a different version of the compiler. Moreover, Greenstone uses STL, the C++ standard template library, and although these compilers sometimes come with STL, the provided version does not always work properly. Hence to recompile Greenstone in such a way that it produces CD-ROMs that work on early versions of Windows, you need</Text>
212<BulletList>
213<Bullet>
214<Text id="67">The Microsoft Visual C++ compiler, Version 4.0 or 4.2.</Text>
215</Bullet>
216<Bullet>
217<Text id="68">An external version of STL, the C++ standard template library. STL is packaged with Greenstone for use with these compiler versions.</Text>
218</Bullet>
219</BulletList>
220<Text id="69">Note that the Windows installation procedure does not attempt to compile Greenstone for you if you choose to install the source code. For platform- and compiler-specific instructions on compiling Greenstone, see the <i>Install.txt</i> document which is placed in the top-level Greenstone directory (<i>C:\Program Files\gsdl</i> by default) during the installation procedure.</Text>
221</Content>
222</Subsection>
223<Subsection id="vista">
224<Title>
225<Text id="v-1">Windows Vista</Text>
226</Title>
227<Content>
228<Text id="v-1">If you are using Windows Vista, you need to run the Greenstone installer as an administrator. If you have problems running GLI, it could be because access is denied. Here is a solution thanks to Amanda Hahn.</Text>
229<Text id="v-3">Running Greenstone in XP compatibility mode does not work. Instead, you MUST change the permissions for the entire greenstone folder otherwise you will keep being told "Access is denied." You must also be an administrator to change this property.</Text>
230<Text id="v-4">Below are the steps to change the permissions:</Text>
231<NumberedList>
232<NumberedItem>
233<Text id="v-5">Right click on the entire Greenstone program folder (normally under <i>Program Files</i>).</Text>
234</NumberedItem>
235<NumberedItem>
236<Text id="v-6">Click <i>Properties</i>. Then Click on the <i>Security</i> tab.</Text>
237</NumberedItem>
238<NumberedItem>
239<Text id="v-8">Under <i>Group or User Names</i>, click on <i>Users</i>, then click <i>Edit</i>.</Text>
240</NumberedItem>
241<NumberedItem>
242<Text id="v-10">Click on <i>Users</i> again.</Text>
243</NumberedItem>
244<NumberedItem>
245<Text id="v-11">Click the checkbox in the window beneath that says <i>Full control</i> in the <i>Allow</i> column.</Text>
246</NumberedItem>
247<NumberedItem>
248<Text id="v-12">Here you MUST hit <i>Apply</i>. If you just hit <i>OK</i> the properties won't change. Then hit <i>OK</i>.</Text>
249</NumberedItem>
250</NumberedList>
251</Content>
252</Subsection>
253</Content>
254</Section>
255<Section id="unix">
256<Title>
257<Text id="70">Unix</Text>
258</Title>
259<Content>
260<Text id="71">This section is written for Unix users. (Windows users should skip ahead to Section <CrossRef target="Section" ref="how_to_find_greenstone"/>.) You need to choose whether to install the binary code or the source code. The binary code occupies about 50 Mb of disk space; the source code requires about 160 Mb to compile.</Text>
261<Subsection id="unix_binaries">
262<Title>
263<Text id="72">Unix binaries</Text>
264</Title>
265<Content>
266<Text id="73">The binary code requires an Intel x86-based Linux distribution which includes ELF binary support. Distributions that meet these requirements include:</Text>
267<BulletList>
268<Bullet>
269<Text id="74">RedHat 5.1</Text>
270</Bullet>
271<Bullet>
272<Text id="75">SuSE Linux 6.1</Text>
273</Bullet>
274<Bullet>
275<Text id="76">Debian 2.1</Text>
276</Bullet>
277<Bullet>
278<Text id="77">Slackware 4.0</Text>
279</Bullet>
280</BulletList>
281<Text id="78">More recent versions of these distributions should also work.</Text>
282<Text id="79">You will need a webserver: we recommend Apache. We also strongly recommend you to install your webserver <i>before</i> installing Greenstone—this will make it much easier to answer the questions that are asked during the Greenstone installation procedure. If you want to build new digital library collections, you will also need Perl if this is not already on your system. To check, open a terminal window, type <i>perl —v</i>, and see if a message appears specifying, amongst other things, the version number. For most versions of Linux, Perl is installed by default. The Appendix <CrossRef target="Chapter" ref="appendix_associated_software"/> gives information on how to obtain Apache and Perl.</Text>
283</Content>
284</Subsection>
285<Subsection id="unix_source">
286<Title>
287<Text id="80">Unix source</Text>
288</Title>
289<Content>
290<Text id="81">The source code is the same for Unix as for Windows. It has been compiled and tested on Linux, Solaris, and Macintosh OS/X; it should be a fairly routine matter to port it to other flavors of Unix.</Text>
291<Text id="82">To compile the Greenstone source code on Unix, you need</Text>
292<BulletList>
293<Bullet>
294<Text id="83">GCC, the Gnu C++ compiler.</Text>
295</Bullet>
296<Bullet>
297<Text id="84">GDBM, the Gnu database manager.</Text>
298</Bullet>
299</BulletList>
300<Text id="85">To run the Greenstone software, you also need a Web server and Perl, as described above under <i>Unix binaries</i>.</Text>
301</Content>
302</Subsection>
303<Subsection id="unix_installation">
304<Title>
305<Text id="86">Unix installation</Text>
306</Title>
307<Content>
308<Text id="87">To install the Unix version from the CD-ROM, insert the disk into the drive, and type</Text>
309<Table class="hidden" id="table_commands">
310<Title/>
311<TableContent>
312<tr>
313<th width="151">
314<CodeLine>mount /cdrom</CodeLine>
315</th>
316<th width="246">
317<Text id="88">mount the CD-ROM device (this command may differ from one system to another; for example on OS/X you <i>cd</i> to the <i>/Volumes</i> directory and then to the appropriate subdirectory for the CD-ROM)</Text>
318</th>
319</tr>
320<tr>
321<th width="151">
322<CodeLine>cd /cdrom</CodeLine>
323</th>
324<th width="246">
325<Text id="89">change directory to the CD-ROM's top level</Text>
326</th>
327</tr>
328<tr>
329<th width="151">
330<CodeLine>cd Unix</CodeLine>
331</th>
332<th width="246">
333<Text id="90">change directory to where the Unix install script resides</Text>
334</th>
335</tr>
336<tr>
337<th width="151">
338<CodeLine>sh Install.sh</CodeLine>
339</th>
340<th width="246">
341<Text id="91">begin the installation process (an explicit <i>sh</i> is used because many installations forbid you to execute programs directly from CD-ROM)</Text>
342</th>
343</tr>
344</TableContent>
345</Table>
346<Text id="92">The final command begins an interactive dialogue which requests the information that is needed to install Greenstone on your system, and gives detailed feedback on what is happening.</Text>
347<Text id="93">The installation procedure begins by asking you which directory to install Greenstone into. The first file placed there is the “uninstall” program that cleans up any partial installation, should you encounter problems or terminate the installation prematurely. Next you choose whether you want to install binaries or source code. You are then asked some questions about your webserver setup. You need to have a valid cgi executable directory (normally called “cgi-bin” on Unix systems); you can either create a new one or use your existing one. If you create a new one, you will need to enter this information in your webserver's configuration file. In either case you need to enter the web address of the cgi directory. The installation dialogue will guide you through all these choices. It is important to set the file permissions correctly on certain directories, and you are prompted for the necessary information. Finally, you are prompted for a password for the “administrator” user <i>admin</i>.</Text>
348<Text id="94">By default, all Greenstone software is installed in the directory <i>/usr/local/gsdl</i> if it is the root user who is doing the installation, and into the directory ~<i>/gsdl</i> otherwise (where “~” is the user's home directory).</Text>
349<Text id="95">Installing the binaries takes just a few minutes, enough time for you to answer the appropriate questions. If you install the source code, the installation script will compile it, which takes from ten minutes to an hour or so, depending on the speed of your processor.</Text>
350<Text id="96">To uninstall the software, type</Text>
351<CodeLine>cd ~/gsdl</CodeLine>
352<Text id="97">or <i>/usr/local/gsdl</i> if it was the root user who installed Greenstone</Text>
353<CodeLine>sh Uni nstall.sh</CodeLine>
354<Text id="98">During the installation procedure you will be asked whether you want to install any Greenstone collections. The Greenstone Demo collection is installed automatically; other collections on the CD-ROM are described in Section <CrossRef target="Chapter" ref="greenstone_collections"/>.</Text>
355</Content>
356</Subsection>
357<Subsection id="unix_webserver_configuration">
358<Title>
359<Text id="99">Unix webserver configuration</Text>
360</Title>
361<Content>
362<Text id="100">If you already have a webserver, some small changes will have to be made to its configuration to make your Greenstone installation operate. The install script explains what these are. You will probably need help from your system administrator to reconfigure the webserver—he or she should be able to understand the instructions output by the install script. For your convenience, the output of the install script is written to a file called INSTALL_RECORD in the directory into which you installed Greenstone.</Text>
363<Text id="101">If you do not already have a webserver, you will have to install one. The Appendix <CrossRef target="Chapter" ref="appendix_associated_software"/> gives information on Apache. Then you will have to configure it appropriately. Section <CrossRef target="Chapter" ref="setting_up_webserver"/> gives a detailed account of the parts of an Apache webserver installation that affect Greenstone, and how they need to be altered. It comes down to including half a dozen or so lines in a configuration file.</Text>
364<Text id="102">You do not need to be the Unix “root” user to go through the installation procedure above. When it comes to configuring an existing Apache server, however, you may need “root” privileges—it all depends on how Apache is set up. If you install Apache yourself, you can do it as a user without “root” privileges. If you need to work your way around an uncooperative system administrator, you can always install a second Apache webserver on your computer—even if one exists already.</Text>
365</Content>
366</Subsection>
367</Content>
368</Section>
369<Section id="how_to_find_greenstone">
370<Title>
371<Text id="103">How to find Greenstone</Text>
372</Title>
373<Content>
374<Subsection id="local_library_windows_only">
375<Title>
376<Text id="104">Local library (Windows only)</Text>
377</Title>
378<Content>
379<Text id="105">If you are using the Local Library, simply run the <i>Greenstone</i> program from the <i>Start</i> menu. This automatically opens a dialog box that starts your Internet browser and loads the Greenstone Digital Library home page. The Greenstone Demo collection should be accessible from this page. The dialog box contais a <i>File</i> menu item that allows you to change the default browser used by Greenstone. It doesn't matter whether you use Netscape or Internet Explorer, except that if you are running on Windows 2000, we recommend that you use Internet Explorer.</Text>
380</Content>
381</Subsection>
382<Subsection id="web_library_windows_and_unix">
383<Title>
384<Text id="106">Web library (Windows and Unix)</Text>
385</Title>
386<Content>
387<Text id="107">If you are using the Web Library, once you have installed the software and configured the webserver, use this URL to enter your Greenstone system:</Text>
388<Text id="108"><i>http://localhost/gsdl/cgi-bin/library</i></Text>
389<Text id="109">The Greenstone Demo collection should be accessible from this page.</Text>
390</Content>
391</Subsection>
392<Subsection id="the_collector">
393<Title>
394<Text id="110">The Collector</Text>
395</Title>
396<Content>
397<Text id="111">A link to the Collector is provided on the digital library home page.</Text>
398</Content>
399</Subsection>
400<Subsection id="administration">
401<Title>
402<Text id="112">Administration</Text>
403</Title>
404<Content>
405<Text id="113">A link to the Administration pages is provided on the digital library home page. The “administrator” user is called <i>admin</i>, with a password that you specified during the installation process. The administrator is authorized to add new users, and to build collections.</Text>
406</Content>
407</Subsection>
408</Content>
409</Section>
410<Section id="the_greenstone_librarian_interface_(gli)">
411<Title>
412<Text id="114">The Greenstone Librarian Interface (GLI)</Text>
413</Title>
414<Content>
415<Text id="115">The Greenstone Librarian Interface (GLI) is a tool to assist you with building digital libraries using Greenstone. It gives you access to Greenstone's collection-building functionality from an easy-to-use “point and click” interface.</Text>
416<Text id="116">GLI is installed automatically with all distributions of Greenstone. It is placed in the subdirectory <i>gli</i> of the top-level Greenstone directory (<i>C:\Program Files\gsdl\gli</i> by default). Note that it runs in conjunction with Greenstone and will not work properly unless it is placed in a subdirectory of your Greenstone installation. If you have downloaded one of the Greenstone distributions, this will be the case.</Text>
417<Text id="117">To use the GLI, your computer needs to have the Java Runtime Environment. If it doesn't, the installer will offer to install a version that is included on the CD-ROM. On Unix, you will also need to ensure that Perl is installed (for Windows, Perl is already included in the Greenstone software). Please report any problems you have running or using the Librarian Interface to <u>[email protected]</u>.</Text>
418<Subsection id="running_under_windows">
419<Title>
420<Text id="118">Running under Windows</Text>
421</Title>
422<Content>
423<Text id="119">To run GLI under Windows, browse to the <i>gli</i> folder in your Greenstone installation (e.g. using Windows Explorer), and double-click on the file called <i>gli.bat</i>. This file checks that Greenstone, the Java Runtime Environment, and Perl are all installed, and starts the Greenstone Librarian Interface.</Text>
424</Content>
425</Subsection>
426<Subsection id="running_under_unix">
427<Title>
428<Text id="120">Running under Unix</Text>
429</Title>
430<Content>
431<Text id="121">To run GLI under Unix, change to the <i>gli</i> directory in your Greenstone installation, then run the <i>gli.sh</i> script. This script checks that Greenstone, the Java Runtime Environment, and Perl are all installed and on your search path, and starts the Greenstone Librarian Interface.</Text>
432</Content>
433</Subsection>
434<Subsection id="getting_help">
435<Title>
436<Text id="122">Getting help</Text>
437</Title>
438<Content>
439<Text id="123">The Greenstone Librarian Interface has extensive on-line help facilities. You get help by clicking the <i>Help</i> button at the top right of the screen. This opens up the text to a section that relates to what you are doing—which of the GLI panels you are on. You can click around the help text to learn what you need to know. Use it.</Text>
440</Content>
441</Subsection>
442<Subsection id="compiling_gli">
443<Title>
444<Text id="124">Compiling the Greenstone Librarian Interface</Text>
445</Title>
446<Content>
447<Text id="125">If you have downloaded the Greenstone source distribution, you will have the Java source code of the Librarian Interface. To compile it, your computer needs to have a Java Development Kit. The Appendix <CrossRef target="Chapter" ref="appendix_associated_software"/> gives information on how to obtain this. To compile the source code, run the <i>makegli.bat</i>(Windows) or <i>makegli.sh</i>(Unix) files. Once compiled, you can run GLI as described above.</Text>
448</Content>
449</Subsection>
450</Content>
451</Section>
452<Section id="testing_and_troubleshooting">
453<Title>
454<Text id="126">Testing and troubleshooting</Text>
455</Title>
456<Content>
457<Text id="127">To test Greenstone, point your Web browser at the Greenstone home page and explore the Demo collection and any other collections that you have installed. Don't worry—you can't break anything. Click liberally: most images that appear on the screen are clickable. If you hold the mouse stationary over an image, most browsers will soon pop up a message that tells you what will happen if you click. Experiment! Choose common words like “the” and “and” to search for—that should evoke some responses, and nothing will break.For more information, see the <i>Greenstone Digital Library User's Guide</i>.</Text>
458<Subsection id="troubleshooting">
459<Title>
460<Text id="128">Troubleshooting</Text>
461</Title>
462<Content>
463<Table id="table_troubleshooting">
464<Title/>
465<TableContent>
466<tr>
467<th width="132"/>
468<th width="151">
469<Text id="129">Problem</Text>
470</th>
471<th width="246">
472<Text id="130">Try this</Text>
473</th>
474</tr>
475<tr>
476<th width="132">
477<Text id="131">Local Library (Windows only)</Text>
478</th>
479<th width="151">
480<Text id="132">When I start Greenstone my computer asks me to dial up my Internet Service Provider.</Text>
481</th>
482<th width="246">
483<Text id="133">Push the <i>Cancel</i> button in the dialog box. This usually solves the problem.</Text>
484</th>
485</tr>
486<tr>
487<th width="132"/>
488<th width="151">
489<Text id="134">When I start Greenstone my computer <i>still</i> asks me to dial up my Internet Service Provider.</Text>
490</th>
491<th width="246">
492<Text id="135">Choose the “Restricted version” when you run Greenstone. This version only works with Netscape.</Text>
493</th>
494</tr>
495<tr>
496<th width="132"/>
497<th width="151">
498<Text id="136">When I point my browser at the digital library, it can't find that page.</Text>
499</th>
500<th width="246">
501<Text id="137">Check your Internet Proxy settings and turn proxies off (use <i>Edit preferences</i> on Netscape or <i>Internet options</i> on Explorer).</Text>
502</th>
503</tr>
504<tr>
505<th width="132"/>
506<th width="151">
507<Text id="138">The Collector seems to be working very slowly!</Text>
508</th>
509<th width="246">
510<Text id="139">Are you using Netscape under Windows 2000? If so, try using Internet Explorer instead—on Windows 2000 (only) there seems to be some incompatibility with Netscape.</Text>
511</th>
512</tr>
513<tr>
514<th width="132">
515<Text id="142">Web Library (Windows and Unix)</Text>
516</th>
517<th width="151">
518<Text id="143">When I start Apache, it quits immediately.</Text>
519</th>
520<th width="246">
521<Text id="144">Add a <i>ServerName localhost</i> directive to the Apache configuration file (see Section <CrossRef target="Section" ref="apache_web_server"/>).</Text>
522</th>
523</tr>
524<tr>
525<th width="132"/>
526<th width="151">
527<Text id="145">When I point my browser at the digital library, it displays garbage—a binary file.</Text>
528</th>
529<th width="246">
530<Text id="146">Check the <i>ScriptAlias</i> directive in the Apache configuration file, making sure it comes before the <i>Alias</i> directive (see Sections 4.2 and 4.3).</Text>
531</th>
532</tr>
533<tr>
534<th width="132"/>
535<th width="151">
536<Text id="147">I get the Greenstone home page (Figure <CrossRef target="Figure" ref="your_greenstone_home_page"/>), but the Demo collection icon does not appear.</Text>
537</th>
538<th width="246">
539<Text id="148">Run the program <i>library</i> (in the cgi-bin directory) from the DOS (or shell) prompt to generate debugging information that will help you locate the problem.</Text>
540</th>
541</tr>
542<tr>
543<th width="132">
544<Text id="149">Both versions</Text>
545</th>
546<th width="151">
547<Text id="150">When I point my browser at the digital library, it can't find that page.</Text>
548</th>
549<th width="246">
550<Text id="151">Try using 127.0.0.1 in place of <i>localhost</i>. This reserved IP number is defined to be a “loopback” to your local computer.</Text>
551</th>
552</tr>
553<tr>
554<th width="132"/>
555<th width="151">
556<Text id="152">My browser complains that it can't find <i>main.cfg</i>.</Text>
557</th>
558<th width="246">
559<Text id="153">Check that the Greenstone files exist and are world-readable. If you are using the Web library, try running the <i>library</i> program from the command line. If it runs OK, the problem is with file permissions (see Section <CrossRef target="Section" ref="file_permissions"/>). If not, the <i>gsdlhome</i> variable is probably set incorrectly in the <i>gsdlsite.cfg</i> configuration file (see Section <CrossRef target="Section" ref="gsdlsite_configuration_file"/>).</Text>
560</th>
561</tr>
562<tr>
563<th width="132"/>
564<th width="151">
565<Text id="154">I'm having trouble using the Collector.</Text>
566</th>
567<th width="246">
568<Text id="155">Read the <i>Greenstone Digital Library User's Guide</i>, Section <CrossRef external="User" lang="en" target="Chapter" ref="making_greenstone_collections"/>.</Text>
569</th>
570</tr>
571<tr>
572<th width="132"/>
573<th width="151">
574<Text id="156">I've added a new user but they can't seem to log in.</Text>
575</th>
576<th width="246">
577<Text id="157">Check that the directory <i>C:\Program Files\gsdl\etc</i> and all its contents are globally writeable (see Section <CrossRef target="Section" ref="file_permissions"/>).</Text>
578</th>
579</tr>
580</TableContent>
581</Table>
582</Content>
583</Subsection>
584</Content>
585</Section>
586<Section id="learn_more">
587<Title>
588<Text id="158">To learn more</Text>
589</Title>
590<Content>
591<Text id="159">To learn more about the innards of your Greenstone installation, consult the <i>Greenstone Digital Library Developer's Guide</i>. It includes (for example) details of the directory structure that has been created, and information about how to configure your Greenstone site.</Text>
592</Content>
593</Section>
594</Content>
595</Chapter>
596<Chapter id="greenstone_collections">
597<Title>
598<Text id="160">Greenstone Collections</Text>
599</Title>
600<Content>
601<Text id="161">Several demonstration Greenstone collections are included on the CD-ROM. If you have Web access, many others can be downloaded, in either pre-built or unbuilt form, from the New Zealand Digital Library Project website (<i>nzdl.org</i>).</Text>
602<Text id="162">The Greenstone Demo collection is a small subset of the Humanity Development Library (HDL), a polished collection. It illustrates that relatively rich browsing capabilities can be provided (so long as suitable metadata is available). It is included automatically when the software is installed.</Text>
603<Text id="163">Greenstone also comes with some well-documented example collections whose “about” page describes how they are constructed. They demonstrate various capabilities of Greenstone. The install dialogue will ask you whether you want to include them in your Greenstone installation; the approximate amount of disk space needed for each collection is shown below.</Text>
604<Table class="hidden" id="table_collections">
605<Title/>
606<TableContent>
607<tr>
608<th width="60">
609<Text id="164"><i>demo</i></Text>
610</th>
611<th width="182">
612<Text id="165">Greenstone Demo<br/>(7 Mb)</Text>
613</th>
614<th width="294">
615<Text id="166">A small subset of the HDL. If you clone this collection, the full facilities will only appear if your new files provide appropriate metadata information.</Text>
616</th>
617</tr>
618<tr>
619<th width="60">
620<Text id="167"><i>dls-e</i></Text>
621</th>
622<th width="182">
623<Text id="168">Development Library Subset collection<br/>(150 Mb)</Text>
624</th>
625<th width="294">
626<Text id="169">Like the Greenstone Demo, this is a subset of the HDL—but much larger. It contains 250 publications—books, reports and magazines—in various areas of human development (the full HDL contains 1,230 publications). It has the same structure as the Greenstone Demo. It's fairly complex, and if you're just starting out you might prefer to look at some other collections first (e.g. <i>MSWord and PDF demonstration</i>, the <i>Greenstone Archives</i>, or the <i>Simple image collection</i>).</Text>
627</th>
628</tr>
629<tr>
630<th width="60">
631<Text id="170"><i>wrdpdf-e</i></Text>
632</th>
633<th width="182">
634<Text id="171">MSWord and PDF demonstration<br/>(4 Mb)</Text>
635</th>
636<th width="294">
637<Text id="172">This contains a few documents in PDF, MSWord, RTF, and Postscript formats, demonstrating the ability to build collections from documents in different formats. The collection configuration file is very simple.</Text>
638</th>
639</tr>
640<tr>
641<th width="60">
642<Text id="173"><i>gsarch-e</i></Text>
643</th>
644<th width="182">
645<Text id="174">Greenstone Archives collection<br/>(5 Mb)</Text>
646</th>
647<th width="294">
648<Text id="175">A collection of email messages from the Greenstone mailing list archives, this uses the Email plugin, which parses files in email formats. The collection configuration file is very simple.</Text>
649</th>
650</tr>
651<tr>
652<th width="60">
653<Text id="176"><i>cltbib-e</i></Text>
654</th>
655<th width="182">
656<Text id="177">Bibliography collection<br/>(7 Mb)</Text>
657</th>
658<th width="294">
659<Text id="178">With about 4,000 bibliography entries, this collection incorporates a form-based search interface that allows fielded searching. It is fairly complex.</Text>
660</th>
661</tr>
662<tr>
663<th width="60">
664<Text id="179"><i>cltext-e</i></Text>
665</th>
666<th width="182">
667<Text id="180">Bibliography supplement<br/>(1 Mb)</Text>
668</th>
669<th width="294">
670<Text id="181">This tiny collection of 10 bibliography entries illustrates the "supercollection" facility which searches several collections together, seamlessly. It operates together with the <i>Bibliography</i> collection, and its configuration file is almost the same.</Text>
671</th>
672</tr>
673<tr>
674<th width="60">
675<Text id="182"><i>MARC-e</i></Text>
676</th>
677<th width="182">
678<Text id="183">MARC example<br/>(1 Mb)</Text>
679</th>
680<th width="294">
681<Text id="184">Based on some MARC records from the Library of Congress, this is a simple collection (and does not allow form-based searching).</Text>
682</th>
683</tr>
684<tr>
685<th width="60">
686<Text id="185"><i>oai-e</i></Text>
687</th>
688<th width="182">
689<Text id="186">OAI demo collection<br/>(18 Mb)</Text>
690</th>
691<th width="294">
692<Text id="187">Using the Open Archive Protocol and the <i>Import-From</i> feature, this retrieves metadata from an archive and builds a collection from the records. In this case they are images, so both the OAI and Image plugins are used.</Text>
693</th>
694</tr>
695<tr>
696<th width="60">
697<Text id="188"><i>image-e</i></Text>
698</th>
699<th width="182">
700<Text id="189">Simple image collection<br/>(1 Mb)</Text>
701</th>
702<th width="294">
703<Text id="190">This very basic image collection contains no text and no explicit metadata—which makes it rather unrealistic. The configuration file is about as simple as you can get.</Text>
704</th>
705</tr>
706<tr>
707<th width="60">
708<Text id="191"><i>authen-e</i></Text>
709</th>
710<th width="182">
711<Text id="192">Formatting and authentication demo<br/>(8 Mb)</Text>
712</th>
713<th width="294">
714<Text id="193">With the same material as the original Greenstone demo collection, this shows off two independent features: non-standard document formatting, and controlled access to the documents via user authentication.</Text>
715</th>
716</tr>
717<tr>
718<th width="60">
719<Text id="194"><i>garish</i></Text>
720</th>
721<th width="182">
722<Text id="195">Garish version of demo collection<br/>(8 Mb)</Text>
723</th>
724<th width="294">
725<Text id="196">This collection also contains the same material as the Greenstone demo. Its appearance has been altered to show how the pages generated can be set out differently. It relies on a non-standard macro file that is supplied with Greenstone.</Text>
726</th>
727</tr>
728<tr>
729<th width="60">
730<Text id="197"><i>isis-e</i></Text>
731</th>
732<th width="182">
733<Text id="198">CDS/ISIS example (1 Mb)</Text>
734</th>
735<th width="294">
736<Text id="199">This collection is built from a CDS/ISIS database of about 150 bibliography entries. It uses the ISISPlug plugin, which reads the standard ISIS .mst and .fdt files and converts them to Greenstone metadata.</Text>
737</th>
738</tr>
739</TableContent>
740</Table>
741</Content>
742</Chapter>
743<Chapter id="setting_up_webserver">
744<Title>
745<Text id="200">Setting up the Webserver</Text>
746</Title>
747<Content>
748<Text id="201">In this section we describe how to set up your webserver to work with Greenstone. Note that all this is unnecessary when using the Windows Local Library, because this software works “out of the box” and does not require a webserver.</Text>
749<Text id="202">We discuss both the Apache webserver, which is freely available for both Windows and Unix (see the Appendix <CrossRef target="Chapter" ref="appendix_associated_software"/> for details) and Microsoft's Personal Web Server (PWS) and Internet Information Services (IIS) webserver. PWS is the standard Microsoft server for Windows 95/98; IIS is the standard webserver for Windows 2000 and the forthcoming Win dows XP ; Windows NT can use either. The Apache description applies equally to the Windows Web Library and Unix versions (though we use Windows-style terminology and pathnames); the PWS/IIS section applies only to the Windows Web Library.</Text>
750<Text id="203">Once you have installed your webserver, the next step is to install Greenstone. We will assume that during the install procedure you have taken the default action for each stage by clicking on the <i>Next</i> button. The result is that the directory <i>C:\Program Files\gsdl</i> is created and the Web Library binary is stored there, along with some supporting files.</Text>
751<Text id="204">All webservers use the special URL “localhost” to denote the computer that the webserver is running on. Thus when you install a webserver, you can get at your html documents by typing the URL <i>http://localhost</i> into a browser. If your computer has a domain name set up, this is used instead of localhost to identify your computer from remote sites. Thus on the New Zealand Digital Library's computer, <i>http://nzdl.org</i> and <i>http://localhost</i> are equivalent. If you type <i>http://nzdl.org</i> on your computer you will get the New Zealand Digital Library webserver, whereas if you type <i>http://localhost</i> you will get your own computer's webserver.</Text>
752<Section id="apache_web_server">
753<Title>
754<Text id="205">The Apache web server</Text>
755</Title>
756<Content>
757<Text id="206">The Apache webserver is usually installed in <i>C:\Program Files\Apache Group\Apache</i> and is configured so that the cgi-bin directory is in the subdirectory <i>\cgi-bin</i> and the document root is the subdirectory <i>\htdocs</i>. It is reconfigured by editing the configuration file <i>C:\Program Files\Apache Group\Apache\conf\httpd.conf</i>. This is a text file: it's quite easy to read it to see how things are set up.</Text>
758<Text id="207">Depending on how your computer's networking software is set up, you may have to add this line to Apache's <i>httpd.conf</i> configuration file:</Text>
759<CodeLine>ServerName localhost</CodeLine>
760<Text id="208">If this line is not included, the system attempts to find your server's name. However, there are bugs in some versions of Windows that cause this to fail. In this case, Apache will exit immediately when you start it up. It does display an error message, but it is immediately erased and you probably can't read it.</Text>
761<Subsection id="setting_up_cgi-bin_directory">
762<Title>
763<Text id="209">Setting up the Greenstone cgi-bin directory</Text>
764</Title>
765<Content>
766<Text id="210">Cgi-bin is a directory from which the webserver treats documents as executable programs. Apache's <i>ScriptAlias</i> directive is used to create a cgi-bin directory. Note that this directive can make any directory a cgi executable directory—it doesn't have to be called “cgi-bin”! Conversely, a directory called “cgi-bin” isn't special unless <i>ScriptAlias</i> has been applied to it.</Text>
767<Text id="211">When installed, Apache has a cgi-bin directory of <i>C:\Program Files\Apache Group\Apache\cgi-bin</i>. This means that if presented with the URL <i>http://localhost/cgi-bin/hello</i>, the webserver will attempt to execute a file called <i>hello</i> from within the above directory.</Text>
768<Text id="212">There is one Greenstone program, which is called “library.exe”, that needs to be executed by the webserver; it in turn reads a file called the Greenstone site configuration file, or “gsdlsite.cfg”, which needs to be located in the same directory.</Text>
769<Text id="213">The best way of arranging this is to use Apache's <i>ScriptAlias</i> directive to create a new cgi-bin directory. Here's the excerpt from Apache's <i>httpd.conf</i> configuration file that adds <i>C:\Program Files\gsdl\cgi-bin</i> as an additional cgi-bin directory:</Text>
770<CodeLine>ScriptAlias /gsdl/cgi-bin/ "C:/Program Files/gsdl/cgi-bin/"</CodeLine>
771<CodeLine>&lt;Directory C:/Program Files/gsdl/cgi-bin&gt;</CodeLine>
772<CodeLine> Options None</CodeLine>
773<CodeLine> AllowOverride None</CodeLine>
774<CodeLine>&lt;/Directory&gt;</CodeLine>
775<Text id="214">(It's a curious fact that Apache configuration files use forward slashes in place of standard Windows backslashes.)</Text>
776<Text id="215">This means that any URLs of the form <i>http://localhost/gsdl/cgi-bin</i>... will be sought in the directory <i>C:\Program Files\gsdl\cgi-bin</i>, and executed by the web server. For example, if presented with the URL <i>http://localhost/gsdl/cgi-bin/hello</i>, the web server will attempt to retrieve the file <i>C:\Program Files\gsdl\cgi-bin\hello</i> and execute it. However, the URL <i>http://localhost/cgi-bin/hello</i> looks in Apache's regular <i>cgi-bin</i> directory for the file <i>C:\Program Files\Apache Group\Apache\</i> <i>cgi-bin\hello</i> and executes it, just as it did before.</Text>
777</Content>
778</Subsection>
779<Subsection id="document_root_directory">
780<Title>
781<Text id="216">The document root directory</Text>
782</Title>
783<Content>
784<Text id="217">The document root directory is the root of your webserver's directory structure. When installed, Apache has a document root <i>of C:\Program Files\Apache Group\Apache\htdocs</i>. This means that if presented with the URL <i>http://localhost/hello.html</i>, the webserver will attempt to retrieve a file called <i>hello.html</i> from within the above directory.</Text>
785<Text id="218">Several files within Greenstone need to be read by the webserver. The simplest way to arrange this is to use the <i>Alias</i> directive, which is just like <i>ScriptAlias</i> except that it applies to ordinary web pages, not cgi scripts. Insert these lines into your Apache configuration file, after the <i>ScriptAlias</i> directive, to add <i>C:\Program Files\gsdl</i> as an additional place to look for documents.</Text>
786<CodeLine>Alias /gsdl/ "C:/Program Files/gsdl/"</CodeLine>
787<CodeLine>&lt;Directory C:/Program Files/gsdl&gt;</CodeLine>
788<CodeLine> Options Indexes MultiViews FollowSymLinks</CodeLine>
789<CodeLine> AllowOverride None</CodeLine>
790<CodeLine> Order allow,deny</CodeLine>
791<CodeLine> Allow from all</CodeLine>
792<CodeLine>&lt;/Directory&gt;</CodeLine>
793<Text id="219">This means that any URLs that match the first argument of Alias (gsdl) are sought as files in the place corresponding to the second argument. In other words, URLs of the form <i>http://localhost/gsdl/</i>... will be sought as files in the directory <i>C:\Program Files\gsdl</i>. For example, if presented with the URL <i>http://localhost/gsdl/hello.html</i>, the webserver will attempt to retrieve the file <i>C:\Program Files\gsdl\hello.html</i>. However, the URL <i>http://localhost/hello.html</i> looks in the regular <i>htdocs</i> directory for the file <i>C:\Program Files\Apache Group\Apache\htdocs\hello.html</i>, just as it did before.</Text>
794<Text id="220">Be sure to add the <i>Alias</i> directive after the <i>ScriptAlias</i> directive. Instructing Apache to alias <i>/gsdl</i> before <i>/gsdl/cgi-bin</i> would match the URL <i>/gsdl/cgi-bin/library</i> against the Alias directive rather than the ScriptAlias, and it would be interpreted as a request for a document rather than the result of executing a program. The outcome would be to “display” the binary program file as a page in the Web browser, instead of executing it.</Text>
795</Content>
796</Subsection>
797<Subsection id="security">
798<Title>
799<Text id="221">Security</Text>
800</Title>
801<Content>
802<Text id="222">You should be aware that if the web library version of Greenstone is set up as instructed above, anyone will be allowed to download any file in the <i>gsdl</i> directory structure. This includes the index files and source documents of any collections you make, the user database, usage logs, etc.</Text>
803<Text id="223">If you are concerned about this, you can easily tighten up your webserver configuration to improve security. For the Apache webserver, put these lines into the configuration file instead of those given in the previous subsection:</Text>
804<CodeLine>Alias /gsdl/ "C:/Program Files/gsdl/"</CodeLine>
805<CodeLine>&lt;Directory "C:/Program Files/gsdl"&gt;</CodeLine>
806<CodeLine> Order allow,deny</CodeLine>
807<CodeLine> Deny from all</CodeLine>
808<CodeLine> &lt;FilesMatch</CodeLine>
809<CodeLine>"\.(gif|jpe?g|png|css|mov|mpeg|ps|pdf|doc|rtf|jar|class)$"&gt;</CodeLine>
810<CodeLine> Order allow,deny</CodeLine>
811<CodeLine> Allow from all</CodeLine>
812<CodeLine> &lt;/FilesMatch&gt;</CodeLine>
813<CodeLine>&lt;/Directory&gt;</CodeLine>
814<Text id="224">This means that only files whose extensions match the regular expression in the <i>FilesMatch</i> line may be downloaded.</Text>
815</Content>
816</Subsection>
817</Content>
818</Section>
819<Section id="pws_and_iis_webservers">
820<Title>
821<Text id="225">The PWS and IIS webservers</Text>
822</Title>
823<Content>
824<Text id="226">Although neither PWS nor IIS is installed by default on current Windows systems, they can easily be installed using the “Add/Remove programs” control panel . If they are not already on your Windows distribution CD-ROM you will have to download them from the Microsoft web site (<i>www.microsoft.com</i>).</Text>
825<Text id="227">The setup procedure for Greenstone is identical for both PWS and IIS. Invoke the Personal Web Manager and perform the following actions.</Text>
826<NumberedList>
827<NumberedItem>
828<Text id="228">Select <i>Advanced</i> to get the <i>Advanced Options</i> screen.</Text>
829</NumberedItem>
830<NumberedItem>
831<Text id="229">Select <i>Home</i> and click <i>Add</i>Fill out the fields as follows:</Text>
832<Text id="230"><i>Directory</i> field: <i>C:\Program Files\gsdl</i></Text>
833<Text id="231"><i>Alias</i>field: <i>gsdl</i></Text>
834<Text id="232">Access permissions: <i>Read</i></Text>
835<Text id="233">Application permissions: <i>None</i></Text>
836<Text id="234">Click <i>OK</i></Text>
837<Text id="235">This makes Greenstone files accessible to the webserver.</Text>
838</NumberedItem>
839<NumberedItem>
840<Text id="236">Back in <i>Advanced Options</i>, select <i>gsdl</i> and click <i>Add</i>Fill out the fields as follows:</Text>
841<Text id="237"><i>Directory</i> field: <i>C:\Program Files\gsdl\cgi-bin</i></Text>
842<Text id="238"><i>Alias</i> field: <i>cgi-bin</i></Text>
843<Text id="239">Access permissions: <i>None</i></Text>
844<Text id="240">Application permissions: <i>Execute</i></Text>
845<Text id="241">Click <i>OK</i></Text>
846<Text id="242">This allows the Greenstone program <i>library.exe</i> to be executed by the webserver.</Text>
847</NumberedItem>
848<NumberedItem>
849<Text id="243">Go to the URL <i>http://localhost/gsdl/cgi-bin/library.exe</i></Text>
850<Text id="244">Note: you need to specify the <i>.exe</i> file extension with PWS and IIS.</Text>
851</NumberedItem>
852</NumberedList>
853</Content>
854</Section>
855</Content>
856</Chapter>
857<Chapter id="configuring_your_site">
858<Title>
859<Text id="245">Configuring your Site</Text>
860</Title>
861<Content>
862<Text id="246">For Greenstone to work properly, access permissions for certain files must be set up appropriately. Also, there is a configuration file associated with each Greenstone site. The install procedure creates a generic configuration file based on your installation choices; however its contents can be tailored to cope with different situations. This section explains both of these issues.</Text>
863<Section id="file_permissions">
864<Title>
865<Text id="247">File permissions</Text>
866</Title>
867<Content>
868<Text id="248">This section is irrelevant for Windows 95/98, because these systems don't identify the owners of files.</Text>
869<Text id="249">On Windows NT, 2000 and Unix systems, cgi scripts don't run as normal users, because users can't be identified over the Web. Instead, they run as the user who started up the webserver program (on Windows systems), or as a special user (commonly called <i>nobody</i> on Unix systems). Because of this, all files and directories within <i>C:\Program Files\gsdl</i> need to be globally readable (or at least readable by the cgi-script user, perhaps “<i>nobody</i>”). To test whether file permissions are set up correctly, run the program <i>library.exe</i> from the command line. If the files are in the right places but the permissions are set incorrectly, it will run from the command line—that is, when <i>you</i> execute it—but not from a browser—that is, when the “<i>nobody</i>” user executes it. Another test is to log in as another user to see if the file permissions are specific to your original user account.</Text>
870<Text id="250">To work through a Web browser, all the Greenstone directories must be globally readable. Also, the <i>C:\Program Files\gsdl\etc</i> directory and all its contents must be globally <i>writable</i>. This is the directory into which the library program writes the usage log, error and initialization logs, and various user databases. If you're reluctant to make this directory globally writable, you can set permissions so that just the files <i>errout.txt</i>, <i>initout.txt</i>, <i>key.db</i>, <i>users.db</i>, <i>history.db</i> and <i>usage.txt</i> are writable by the cgi user.</Text>
871<Text id="251">If file permissions are not set up correctly for <i>C:\Program Files\gsdl\etc</i>, you may find that user authentication and search history do not work, and that no usage log (<i>usage.txt</i>) is generated.</Text>
872</Content>
873</Section>
874<Section id="gsdlsite_configuration_file">
875<Title>
876<Text id="252">The gsdlsite.cfg configuration file</Text>
877</Title>
878<Content>
879<Text id="253">The install procedure creates a generic Greenstone site configuration file based on your installation choices. For our installation this file is <i>C:\Program Files\gsdl\cgi-bin\gsdlsite.cfg</i> and its content is:</Text>
880<CodeLine># Site configuration file for Greenstone.</CodeLine>
881<CodeLine># Lines begining with</CodeLine>
882<CodeLine># are comments.</CodeLine>
883<CodeLine># This file should be placed in the same directory as your library</CodeLine>
884<CodeLine># executable file. it should be edited to suit your site.</CodeLine>
885<CodeLine># points to the GSDLHOME directory</CodeLine>
886<CodeLine>gsdlhome “C:/Program Files/gsdl ”</CodeLine>
887<CodeLine># this is the http address of GSDLHOME</CodeLine>
888<CodeLine># if your webservers DocumentRoot is set to $GSDLHOME</CodeLine>
889<CodeLine># then httpprefix can be commented out</CodeLine>
890<CodeLine>httpprefix /gsdl</CodeLine>
891<CodeLine># this is the http address of the directory which</CodeLine>
892<CodeLine># contains the images for the interface.</CodeLine>
893<CodeLine>httpimg /gsdl/images</CodeLine>
894<CodeLine># should contain the http address of this cgi script. This</CodeLine>
895<CodeLine># is not needed if the http server sets the environment variable</CodeLine>
896<CodeLine># SCRIPT_NAME</CodeLine>
897<CodeLine>#gwcgi /cgi-bin/library</CodeLine>
898<CodeLine># maxrequests is the most requests a fastcgi process</CodeLine>
899<CodeLine># will serve before it exits. This can be set to a</CodeLine>
900<CodeLine># low figure (like 1) while debugging and then set</CodeLine>
901<CodeLine># to a high figure (like 10000) when everything is</CodeLine>
902<CodeLine># working well.</CodeLine>
903<CodeLine>#maxrequests 10000</CodeLine>
904<Text id="254">You can customise your installation by editing this file, although you will probably not need to do so.</Text>
905<Text id="255">The <i>gsdlhome</i> line simply points to the <i>C:\Program Files\gsdl</i> directory.</Text>
906<Text id="256"><i>httpprefix</i> is the web address of the directory that Greenstone is installed in. We explained earlier how to create an alias so that URLs of the form <i>http://localhost/gsdl/</i>... are sought in the <i>C:\Program Files\gsdl</i> directory. Putting a line <i>httpprefix/gsdl</i> into the <i>gsdlsite</i> configuration file establishes the same convention for the Greenstone software.</Text>
907<Text id="257"><i>httpimg</i> is the web address of the <i>C:\Program Files\gsdl\images</i> directory, which contains all the gif images used in the interface. In any standard Greenstone installation this will always be <i>httpprefix/images</i>, and the line in the file above is left untouched.</Text>
908<Text id="258"><i>gwcgi</i> is the web address of the library cgi program. This is not required by most webservers (including Apache), and should remain commented out. Don't uncomment it unless you're sure you need to, because that may introduce problems.</Text>
909<Text id="259"><i>maxrequests</i> is only used by versions of Greenstone that are compiled with the “fast-cgi” option on. The standard binary distribution does not include this option because not all webservers are configured to support it. Fastcgi speeds up cgi executions by keeping the main executable in memory between invocations of the software, rather than loading it in from disk each time a web page is requested from the Greenstone software. The trade-off is the amount of memory used, which can grow the longer the program remains in memory. Once <i>maxrequests</i> pages have been generated, the cgi program quits, thereby freeing any accumulated memory. To respond to the next request for a Web page, the cgi program is read in from disk again, and a new cycle of page requests is begun. Most installations use the standard cgi protocol, which means that <i>maxrequests</i> can be safely ignored.</Text>
910</Content>
911</Section>
912</Content>
913</Chapter>
914<Chapter id="personalizing">
915<Title>
916<Text id="260">Personalizing your Installation</Text>
917</Title>
918<Content>
919<Text id="261">Probably the first thing you will want to do once your Greenstone installation is up and running is personalize the home page. The file that generates the Greenstone home page is called <i>home.dm</i>, and is located in the <i>macros</i> subdirectory of the directory into which you installed Greenstone. (The default for Windows systems is <i>C:\Program Files\gsdl</i>.) This is a plain text file that you will have to edit to create a new home page. Instead of editing it, we recommend creating a new file, say <i>yourhome.dm</i>. This will be like <i>home.dm</i> but will define “package home”—which is the bit that does the actual work—in a different way.</Text>
920<Text id="262">When you make a different home page, there must be some way of linking in to the digital library pages so that you can search and browse the collections on your system. The solution that Greenstone adopts is to use “macros”. That's why the home-page file is called “.dm” and not “.html”—it's a “macro” file rather than a regular html file. But don't quail: the macro file basically contains just html, sprinkled with a few mystical incantantations which are explained below. The macro language is a powerful facility, and only a small part of it is described below—see the <i>Greenstone Digital Library Developer's Guide</i> for more information.</Text>
921<Section id="example">
922<Title>
923<Text id="263">Example</Text>
924</Title>
925<Content>
926<Figure id="your_own_greenstone_home_page">
927<Title>
928<Text id="264">Your own Greenstone home page</Text>
929</Title>
930<File width="395" height="227" url="images/Install_Fig_3.png"/>
931</Figure>
932<Text id="265">Figure <CrossRef target="Figure" ref="your_own_greenstone_home_page"/> shows an example of a new digital library home page. Each of the “Click here” links takes you to the appropriate Greenstone facility. This page was generated by the file called <i>yourhome.dm</i> shown in Figure <CrossRef target="Figure" ref="yourhome_dm"/>.</Text>
933<Figure id="yourhome_dm">
934<Title>
935<Text id="266"><i>yourhome.dm</i> used to create Figure <CrossRef target="Figure" ref="your_own_greenstone_home_page"/></Text>
936</Title>
937<CodeLine>package home</CodeLine>
938<CodeLine>_content_ {</CodeLine>
939<CodeLine>&lt;h2&gt;Your own Greenstone home page&lt;/h2&gt;</CodeLine>
940<CodeLine>&lt;ul&gt;</CodeLine>
941<CodeLine>&lt;table&gt;</CodeLine>
942<CodeLine>&lt;tr valign=top&gt;&lt;td&gt;Search page for the demo collection&lt;br&gt;&lt;/td&gt;</CodeLine>
943<CodeLine> &lt;td&gt;&lt;a href="_httpquery_&amp;c=demo"&gt;Click here&lt;/a&gt;&lt;/td&gt;&lt;/tr&gt;</CodeLine>
944<CodeLine>&lt;tr&gt;&lt;td&gt;"About" page for the demo collection&lt;/td&gt;</CodeLine>
945<CodeLine> &lt;td&gt;&lt;a href="_httppageabout_&amp;c=demo"&gt;Click here&lt;/a&gt;&lt;/td&gt;&lt;/tr&gt;</CodeLine>
946<CodeLine>&lt;tr&gt;&lt;td&gt;Preferences page for the demo collection&lt;/td&gt;</CodeLine>
947<CodeLine> &lt;td&gt;&lt;a href="_httppagepref_&amp;c=demo"&gt;Click here&lt;/a&gt;&lt;/td&gt;&lt;/tr&gt;</CodeLine>
948<CodeLine>&lt;tr&gt;&lt;td&gt;Home page&lt;/td&gt;</CodeLine>
949<CodeLine> &lt;td&gt;&lt;a href="_httppagehome_"&gt;Click here&lt;/a&gt;&lt;/td&gt;&lt;/tr&gt;</CodeLine>
950<CodeLine>&lt;tr&gt;&lt;td&gt;Help page&lt;/td&gt;</CodeLine>
951<CodeLine> &lt;td&gt;&lt;a href="_httppagehelp_"&gt;Click here&lt;/a&gt;&lt;/td&gt;&lt;/tr&gt;</CodeLine>
952<CodeLine>&lt;tr&gt;&lt;td&gt;Administration page&lt;/td&gt;</CodeLine>
953<CodeLine> &lt;td&gt;&lt;a href="_httppagestatus_"&gt;Click here&lt;/a&gt;&lt;/td&gt;&lt;/tr&gt;</CodeLine>
954<CodeLine>&lt;tr&gt;&lt;td&gt;The Collector&lt;/td&gt;</CodeLine>
955<CodeLine> &lt;td&gt;&lt;a href="_httppagecollector_"&gt;Click here&lt;/a&gt;&lt;/td&gt;&lt;/tr&gt;</CodeLine>
956<CodeLine>&lt;/table&gt;</CodeLine>
957<CodeLine>&lt;/ul&gt;</CodeLine>
958<CodeLine>}</CodeLine>
959<CodeLine># if you hate the squirly green bar down the left-hand side of the</CodeLine>
960<CodeLine># page, uncomment these lines:</CodeLine>
961<CodeLine># _header_ {</CodeLine>
962<CodeLine># }</CodeLine>
963</Figure>
964<Text id="267">You can use Figure <CrossRef target="Figure" ref="yourhome_dm"/> as a template for creating your own specialized Greenstone home page. Basically, it defines a macro called <i>content</i>. Inside the curly braces is ordinary html. You could insert additional text, along with any html formatting commands, to put the content that you want to see on the page. The text is regular html; if you want you can include hyperlinks and use all the other facilities that html provides.</Text>
965<Text id="268">To make your new home page link in with other digital library pages, you need to use an appropriate magic spell. In this macro language, magic spells are words flanked by underscores. You can see these in Figure <CrossRef target="Figure" ref="yourhome_dm"/>. For example, <i>_httppagehome_</i> takes you to the home page, <i>_httppagehelp_</i> to the help page, and so on. In some cases you need to include a collection name. For example, <i>_httpquery_&amp;c=demo</i> specifies the search page for the demo collection; for other collections you should replace <i>demo</i> by the appropriate collection name.</Text>
966<Text id="269">The definition of the macro called <i>_content_</i> is plain html. Any standard html code may be placed within a macro definition. However, the special characters '{', '}', '\', and '_' must be escaped with a backslash to prevent them from being processed by the macro language interpreter.</Text>
967<Text id="270">Note that the <i>_content_</i> macro definition does not contain any html header or footer. If you want to change the header or footer of your home page, you should define <i>_header_</i> and/or <i>_footer_</i> macros, adding them to the <i>yourhome.dm</i> file in the form</Text>
968<CodeLine>_macroname_ {</CodeLine>
969<CodeLine>...</CodeLine>
970<CodeLine>}</CodeLine>
971<Text id="271">For example, the squirly green bar down the left-hand side of Greenstone pages is defined in the <i>_header_</i> macro, and making this macro null will remove it, as indicated at the end of Figure <CrossRef target="Figure" ref="yourhome_dm"/>.</Text>
972</Content>
973</Section>
974<Section id="how_to_make_it_work">
975<Title>
976<Text id="272">How to make it work</Text>
977</Title>
978<Content>
979<Text id="273">You have to tell Greenstone about the new home page <i>yourhome.dm</i>. The system reads in the macro files that are specified in the main configuration file <i>main.cfg</i>, so if you create a new one you must include it there. Name clashes are handled sensibly: the most recent definition takes precedence.</Text>
980<Text id="274">Thus to make the Greenstone digital library software use the home page in Figure <CrossRef target="Figure" ref="your_own_greenstone_home_page"/> instead of the default, first put the <i>yourhome.dm</i> file in Figure <CrossRef target="Figure" ref="yourhome_dm"/> into the <i>macros</i> directory. Then edit the <i>main.cfg</i> configuration file to replace <i>home.dm</i> with <i>yourhome.dm</i> in the list of macro files that are loaded at startup.</Text>
981</Content>
982</Section>
983<Section id="redirecting_a_url_to_greenstone">
984<Title>
985<Text id="275">Redirecting a URL to Greenstone</Text>
986</Title>
987<Content>
988<Text id="276">You may want to redirect a more convenient URL to your Greenstone cgi program. For example, on our system the URL <i>http://nzdl.org</i> (which is shorthand for <i>http://nzdl.org/index.html)</i> is redirected to <i>http://nzdl.org/cgi-bin/library</i>. The Apache webserver accomplishes this with the <i>Redirect</i> directive. Along with other directives, this goes into the <i>C:\Program Files\Apache Group\Apache\conf\httpd.conf</i> configuration file. To redirect the URL <i>http://www.yourserver.com</i> to <i>http://www.yourserver.com/cgi-bin/library</i>, put this line into <i>httpd.conf</i>:</Text>
989<CodeLine>Redirect /index.html http://www.yourserver.com/cgi-bin/library</CodeLine>
990<Text id="277">Then you will reach your digital library system directly from the URL <i>http://www.yourserver.com</i>. Instead, if you wanted a URL like <i>http://www.yourserver.com/greenstone</i> to be redirected to <i>http://www.yourserver.com/cgi-bin/library</i>, include in the <i>httpd.conf</i> file</Text>
991<CodeLine>Redirect /greenstone http://www.yourserver.com/cgi-bin/library</CodeLine>
992<Text id="278">If your computer doesn't have a domain name (like the “www.yourserver.com” above), just replace <i>www.yourserver.com</i> by <i>localhost</i> in the lines above. So long as the browser is running on the same machine as the webserver—which it surely is if your computer doesn't have a domain name—this has the same effect as the above redirections.</Text>
993<Text id="279">Instead of putting redirect directives into the file <i>httpd.conf</i>, you can equally well put them into a file called <i>.htaccess</i> within your server's document root directory. In fact, doing so has two advantages. First, changes to <i>.htaccess</i> take effect immediately, whereas you have to restart the Apache webserver to see the effect of changes to <i>httpd.conf</i>. Second, on Unix systems you usually have to be logged in as the “root” user to edit <i>httpd.conf</i>, whereas you don't to edit <i>.htaccess</i>.</Text>
994</Content>
995</Section>
996</Content>
997</Chapter>
998<Chapter id="appendix_associated_software">
999<Title>
1000<Text id="280">Appendix Associated Software</Text>
1001</Title>
1002<Content>
1003<Text id="281">Here is how to obtain the software packages mentioned above.</Text>
1004<Section id="apache_webserver">
1005<Title>
1006<Text id="282">Apache Webserver</Text>
1007</Title>
1008<Content>
1009<Text id="283">To run any version of Greenstone apart from the Windows Local Library version, you need an external webserver. Many installations, particularly larger ones, will already have a webserver. If you are using Linux, Apache may be on your installation disk but may not have been selected during the installation procedure. The Apache Webserver from <i>www.apache.org</i> is free, and easy to install.</Text>
1010</Content>
1011</Section>
1012<Section id="perl">
1013<Title>
1014<Text id="284">Perl</Text>
1015</Title>
1016<Content>
1017<Text id="285">Greenstone uses the Perl language when building collections. For Windows, Perl is already included in the Greenstone software. Most Unix systems already have Perl installed, but if not, source code and binaries for a wide range of Unix platforms are freely available at <i>www.perl.com</i>. Perl version 5.0 or higher is needed.</Text>
1018</Content>
1019</Section>
1020<Section id="gcc">
1021<Title>
1022<Text id="286">GCC</Text>
1023</Title>
1024<Content>
1025<Text id="287">The Unix version of Greenstone compiles under the Gnu C++ compiler, GCC. Greenstone makes extensive use of the C++ standard template library (we've found it to be broken on some older versions of GCC; please tell us if you have STL problems). Note that this version of Greenstone does not compile under GCC 3.0.</Text>
1026</Content>
1027</Section>
1028<Section id="gdbm">
1029<Title>
1030<Text id="288">GDBM</Text>
1031</Title>
1032<Content>
1033<Text id="289">All versions of Greenstone use the Gnu Database Manager, GDBM. It is supplied with all Windows versions of Greenstone and installed automatically during the installation procedure. Linux systems already have GDBM, so we do not provide it for Linux. Most other Unix systems have it, but if necessary you can download it from <i>www.gnu.org</i>.</Text>
1034</Content>
1035</Section>
1036<Section id="java_runtime_environment">
1037<Title>
1038<Text id="290">Java runtime environment</Text>
1039</Title>
1040<Content>
1041<Text id="291">To use the Greenstone Librarian Interface, you need a suitable version of the Java Runtime Environment. If you don't already have this, a suitable version is included on the CD-ROM, or you can download the latest version from <u>http://java.sun.com/j2se/downloads.html</u>. Version 1.4.0 or higher is needed.</Text>
1042</Content>
1043</Section>
1044<Section id="java_compiler">
1045<Title>
1046<Text id="292">Java compiler</Text>
1047</Title>
1048<Content>
1049<Text id="293">To compile the source code of the Greenstone Librarian Interface, you must first install a Java Development Kit. You can download the J2SE Software Development Kit from <u>http://java.sun.com/j2se/downloads.html</u>. Version 1.4.0 or higher is needed.</Text>
1050</Content>
1051</Section>
1052</Content>
1053</Chapter>
1054</Manual>
Note: See TracBrowser for help on using the repository browser.