Table of Contents

Release Name: 2.83

Release Date: 24 November 2009

Released: Windows, GNU/Linux, Mac OS/X and Source distributions of Greenstone v2.83

This is a release designed to be used with the new edition of "How to build a digital library".

Installation Instructions

Binary distribution

Upon downloading the installer, run the executable: On Windows and Mac you need to double-click it to launch the installation dialog, on Linux you first need to set the downloaded executable's permissions to executable before you can run it from the terminal. It may take some time for the Greenstone installation dialog to appear. Once the installation dialog displays, you generally need to keep pressing the Next button until it is finished. However, when it asks for the location to install Greenstone in, make sure to choose a location on your file system for which you have access privileges.

When the installation process is finished, you can run the Greenstone Server or the Greenstone Librarian Interface (GLI):

1. On Windows, the included Greenstone Server can be launched from the shortcut in the Start menu. On Mac and Linux, use a terminal (in Macs this is found under Applications > Utilities > Terminal) to go into the Greenstone installation directory and run

./gs2-server.sh

The small Greenstone Server Interface (GSI) dialog will display. Pressing its Enter Library button will open a browser onto your Greenstone Digital Library home page.(*)

Note: The Windows version of Greenstone includes two server applications: server.exe and an apache web server. (Linux and Mac versions of Greenstone include only the apache web server). By default, the server.exe application is launched when you use the Windows Start menu shortcut to launch the server. To use the apache web server included with the Windows version of Greenstone, you would first have to rename the server.exe executable found in your Greenstone installation folder. Then you can run the apache web server by double-clicking the gs2-server.bat file that's also located in your Greenstone installation folder (or you can use the MS-DOS prompt to run this batch file).

By default, your Greenstone pages served using the apache web server will not be viewable from other machines. To change this, go to File > Settings in the Greenstone Server Interface dialog, and tick "Allow external connections". Click OK to save the settings, then press the Restart Library button. (**)

2. The Greenstone Librarian Interface (GLI) can be run from the Windows Start menu. On Mac and Linux, use a terminal to go into the Greenstone installation directory and run

./gli/gli.sh

First, as in (1) above, the Greenstone Server Interface (GSI) dialog will appear. Eventually the Greenstone Librarian Interface (GLI) dialog will appear. Refer to the Greenstone tutorials for examples of using the GLI to create collections of documents. Once you have finished creating a collection, you can preview it by pressing the Preview button from GLI's Create tab. It will open your Greenstone collection in the web browser.(*) (**)

(*) If the web page displays a "Forbidden" message instead, go back to the GSI dialog, and use its File > Settings menu to change the Address Resolution method to one of the other options there. Then press the Restart Library Button in the main GSI dialog and see whether the browser page it opens now is the Greenstone home page. Otherwise try another Address Resolution option from the GSI dialog's Settings menu and see whether the pages are visible now.

(**) If you have your own external web server that you wish to use, then in your Greenstone installation directory, rename the folder apache-httpd to something else. Alternatively, you can rename the file gs2-server.sh (if on Linux/Mac) or gs2-server.bat (if on Windows) to something else.

3. The Client-GLI is the version of the Greenstone Librarian Interface that can be run on different machine from the one that is running the Greenstone server. To be able to run the Client-GLI application, you will need Java 1.4.2 or greater installed and you will need to have:

If you follow Java's installation instructions, they will direct you on how to add the Java installation's bin folder to your system's PATH environment variable and how to set the JAVA_HOME environment variable.

If on Windows, you can run client-GLI from its shortcut in the Start Menu. On Linux and Mac systems, you would use a terminal to go into your Greenstone installation folder and then run

./gli/client-gli.sh

When the client-GLI starts up, a small dialog appears asking you to enter the URL of the remote Greenstone server's gliserver.pl file. This URL generally has the form: http://<host>:<port>/greenstone/cgi-bin/gliserver.pl, where you have to fill in the host and port values for the remote Greenstone server. After clicking OK, the client-GLI application window will appear. Client-GLI looks and works just like the GLI, except that most of the document processing takes place on the remote machine where the Greenstone server is running.

Source Components and Source Distributions

There's two ways to get Greenstone 2.83's source code in a compressed format (zip or tar.gz file):

1. If you didn't install a Greenstone binary version, you would get the Greenstone Source Distribution which contains the (uncompiled) source code.

2. If you downloaded and installed the Greenstone binary version already, you would only need to top up your installation with the source code by getting the Source Component. You would then unzip this in your Greenstone directory: On Windows, right-clicking on the zip file and choosing to extract its contents to this location should be sufficient. To extract to the correct location on Linux and Mac systems, you would need to use a Terminal to run "tar -xvzf Greenstone-2.83-source-component.tar.gz" from your Greenstone installation directory. Then all the tar.gz file's contents will end up inside the appropriate folders.

To compile the Greenstone source code, you would need

To configure and compile on Mac and Linux machines, open a Terminal and run the following three commands from the Greenstone installation directory (each of them will take some time, but you can skip the first if you downloaded the Source Component):

./configure --enable-apache-httpd
make
make install

If you do not wish to compile up the included apache web server, leave the –enable-apache-httpd out of step 1. (See also the section "Additonal notes to compiling manually" below.)

To compile on Windows,

1. Edit the start of the makegs2.bat file in your Greenstone installation directory to contain

2. Then run the makegs2.bat file from the DOS prompt. Type Y to extract the necessary files. When it asks you what you want to compile, either type 3 to compile up the server.exe web server, or type 4 to compile up the apache web server included with Greenstone.

IMPORTANT NOTE on uninstalling Greenstone 2.83

If you have Greenstone 2.83 installed, and it is installed into a pre-existing folder with no Greenstone subfolder (eg installed directly into My Documents), DO NOT run the uninstaller, as it will delete all the files in that folder. Please manually delete all the Greenstone folders and files.

Further Notes on Installation and Running

Apache Notes

Greenstone binary releases come with Apache precompiled and install it by default into Greenstone/apache-httpd.

Notes for Snow Leopard

These notes were provided by Michael Silver via the mailing list. Copied here in case they help someone else.

Note that you need to replace <GSDL Install Directory> in the directions below with the actual folder you install Greenstone into (e.g., /Users/alexanderkroh/Greenstone/

I'm going to assume (there's that word) that you are using a 64-bit version of Snow Leopard. Intel Macs can have either a 32-bit or 64-bit processor. The processor version can be determined by looking in the "About this Mac" box (in the Apple menu). If it says "Intel Core Solo" or "Intel Core Duo" it is 32-bit. Otherwise, it's 64-bit. (Complete details straight from Apple are available at http://support.apple.com/kb/HT3696 ) If you have a 32-bit OS, there is an additional issue with ImageMagick, but you most likely have a 64-bit version.

If you're not experienced with compiling things, your best bet is to use the binary distribution available from www.greenstone.org. It doesn't sound like you're going to gain anything by compiling from source.

Greenstone uses Perl to do a lot of its magic. Unfortunately, Snow Leopard updated the version of Perl included in the distribution, and the default one (5.10) doesn't work with Greenstone Librarian Interface (GLI). You need to modify the setup.bash file to correct this.

When first installed, GSDL does not include any icons to run the programs - they must be run from the command line. I suggest you run both programs (the server and the GLI) from the terminal window to start with, since you'll be able to see any errors that may occur. The steps are:

After you've verified that the programs run, you'll probably want to create icons to start them since running the programs from the command line is cumbersome. You can create icons to run them by using the Apple Script Editor (AppleScript Editor or Script Editor depending on your OS version). Open the Script Editor.

These files can be run from where they were saved, or dragged into the dock or onto the desktop.

Perl 5.8.9 for Linux

On some newer distributions of Linux (such as Ubuntu), Perl version 5.10.x or later is installed on the system. This can be incompatible with perl scripts run manually or which are run by the Greenstone Librarian Interface (GLI). Perl 5.8.9 is still compatible, and so a version for Linux has been put into a tar.gz and made available at http://www.greenstone.org/bin-linux-perl-5.8.9.tar.gz.

If you are running the Greenstone perl scripts (manually or via GLI) on Linux and it complains about perl-related errors, download this tar.gz file, put it into your Greenstone installation folder. Then open a terminal to go into that folder and run

tar -xvzf bin-linux-perl-5.8.9.tar.gz

The above will put perl 5.8.9 inside Greenstone's bin/linux folder.

Next, get the updated setup.bash script and put it in your greenstone installation folder. It tells Greenstone where to first look for an installation of Perl (instead of defaulting to the system version).

To make sure your Greenstone installation subsequently uses this Perl and not the default one installed on your machine, you will first need to use your terminal to go into the Greenstone installation directory and run

source setup.bash

before running any perl scripts manually and before running GLI. If you run scripts manually (from the command line), run them as:

perl -S <scriptname> <any arguments>

Additional notes to compiling manually

On Windows, use a DOS prompt to go into your Greenstone installation folder. You will need Visual C++ (of Visual Studio) and the Windows/Microsoft Platform SDK installed. FIRST run the Platform SDK's SetEnv.Cmd. THEN run Visual C++'s vcvars32.bat (or vsvars32.bat). Now you can compile manually:

nmake /f win32.mak
nmake /f win32.mak LOCAL_LIBRARY=1
nmake /f win32.mak APACHE_HTTPD=1
nmake /f win32.mak clean

On Linux and Mac, configuring and compiling generally takes the form:

./configure
make
make install
./configure --disable-accentfold

As stated in the installation instructions, to compile the included apache web server, the configure step needs to be:

./configure --enable-apache-httpd
make clean

To clean all the files generated during both compilation AND configuration (all config files, other intermediate files and binaries), you would run the following instead:

make distclean

Additional notes to running Greenstone on Windows

On Windows, running the Greenstone Librarian Interface (GLI) or the Greenstone Server Interface (GSI) manually from a DOS prompt could be useful in diagnosing anything that goes wrong as it keeps any messages that were displayed during program execution visible in the DOS window.

To run GLI or GSI from the DOS prompt, first go into your Greenstone installation directory and then

gs2-server.bat
gli\gli.bat

Notes on using a Terminal or DOS prompt

On Macs, the Terminal is an application that can be found under Applications > Utilities > Terminal.

On Windows, you can start up a DOS prompt by going to Start > Run and then typing cmd.

To go to your Greenstone installation directory using your terminal, you would type:

cd <here you'd type the full path to your Greenstone installation folder>

On Windows you would use backslashes (\) and on Linux and Mac, you would use forward slashes (/) in file paths.

On Linux and Mac, to run a shell script (Greenstone's shell scripts are files that end on *.sh or *.bash), you would precede the scriptname with a ./

On Windows, to run a batch script (files that end on *.bat), just type its name out in full.

E.g. on Windows:

cd C:\Greenstone
gs2-server.bat

E.g. on Linux or Mac:

cd /home/me/greenstone
./gs2-server.sh

Using gsicontrol script

The gsicontrol.sh/bat script is used by gs2-server.sh/bat, and provides much functionality: change port number, start and stop the Apache web server, etc. It accepts many parameters like:

web-start web-stop web-restart configure-admin configure-web configure-apache configure-cgi set-port test-gsdlhome web-stop-tested

You can use it as in the following example

Working with Remote Greenstone and the GLI-Client

These instructions are more Greenstone 2.83-specific than the general instructions for setting up Greenstone 2 as a remote server.

The following are steps to follow if you're on Windows. On Linux, you can skip steps 1 and 2, otherwise things are similar. For instance, you'll want to launch *.bash or *.sh script equivalents to the batch files listed. Also, you'll want to use forward slashes (/) instead of the Windows' backward slash (\) when specifying file paths.

1. If the path to your Greenstone installation contains any spaces (i.e. if any of the containing folders wherein your Greenstone is ultimately located contain spaces in their names), please open cgi-bin/gsdlsite.cfg in a plain text editor and make sure that thevalue for GSDLHOME line contains quotes around it. E.g.

gsdlhome "C:\Program Files\Greenstone2"

Save any changes.

2. Rename server.exe in your Greenstone installation folder to something else, say "_server.exe".

This is because you will need to use the included Apache web server for the remote Greenstone. By renaming the default library server in Greenstone 2, Greenstone will next look for the apache web server.

3. Now run the Apache web server included with your Greenstone, by opening a DOS prompt and typing the path to your Greenstone 2 installation and then running the gs2-server script. E.g.

cd C:\Program Files\Greenstone2
gs2-server.bat

Alternatively, you could use Windows Explorer to locate the gs2-server.bat file in your Greenstone2 installation folder and double click that file.

4. A dialog (the Greenstone Server Interface) will display. Press its central Enter Library button.

It will open a browser and take you to a page like: http://localhost/greenstone/cgi-bin/library.cgi

(OR: http://<YOUR-MACHINE-NAME:YOURPORT>/greenstone/cgi-bin/library.cgi where if port were the default 80 it won't be displayed, e.g. http://<YOUR-MACHINE-NAME:YOURPORT>/greenstone/cgi-bin/library.cgi)

5. Replace the "library.cgi" part of the URL in the browser to "gliserver.pl?cmd=check-installation": E.g. http://localhost/greenstone/cgi-bin/gliserver.pl?cmd=check-installation (OR: http://<YOUR-MACHINE-NAME:YOURPORT>/greenstone/cgi-bin/gliserver.pl?cmd=check-installation)

At the end of the browser page, it is imperative that it says something like:

"Installation OK!"

(If not check the error messages.)

6. Once again, open a DOS prompt. Type the following, but make sure to type the path to *your* Greenstone2 installation (the example below uses C:\Program Files\Greenstone2\collect):

cacls "C:\Program Files\Greenstone2\collect" /P Everyone:F

On Linux you would do:

chmod a+rx /my/path/to/my/Greenstone2.83/collect

7. Use the browser to go to your Greenstone home web page again.

8. Enter the username and password for the new user.

9. If you're on a linux machine that required you to install the Perl|5.8.9 bundle, then you would need to do the following additionally:

perlpath /my/linux/path/to/Greenstone2/bin/linux/perl/bin

10. Open a new DOS prompt. Either in this or another machine (assuming you want the Greenstone server on one machine and the client on another), go to the gli folder of your Greenstone 2 installation, and run client-gli.bat. E.g.

cd C:\Program Files\Greenstone2\gli
client-gli.bat

11. A dialog will eventually appear asking you for the URL of the Remote Greenstone server's gliserver.pl file.

12. It will next ask you for a username and password. Type the values you entered for the new user you creatred in step 8.

13. The client-GLI dialog should finally open, and it will look the same as the usual (local) GLI.

Important Changes

2.83 incorporates a few changes and bug fixes since 2.82, including:

<a href=\"_httpcollection_/index/assoc/[archivedir]/doc.pdf#search="_queryterms_"\">

Known Issues and Patches

Windows XP issue<br/> The windows release was compiled on Windows Vista. It appears that some functionality is broken when running on Windows XP, for example, the depositor, and particular commands for oaiserver. Here are 2.83-windows-library.cgi and 2.83-windows-oaiserver.cgi to download which have been compiled on Windows XP. They should be copied into Greenstone's cgi-bin folder, and renamed to library.cgi or oaiserver.cgi, respectively. 2.83-windows-server.exe should be copied into the top Greenstone folder, and renamed to server.exe.

Word document processing on Mac OS<br/> On the Mac, when processing Word documents, you may encounter an error (in Expert mode) like Error executing wv converter: dyld: Library not loaded: /usr/local/lib/libpng.3.dylib If so, please download 2.83-libpng.3.dylib and save to Greenstone/bin/darwin/imagemagick/lib/libpng.3.dylib.

Updated Translations

Thanks to the following people for updated translations since 2.82:

A special thanks to Veronica Liesaputra, a most dedicated Greenstone friend, who has done more than her own work of developing the excellent Realistic Book tool (and plugin to Greenstone). She has lugged round her Mac laptop well beyond the call of duty to help debug and test this release of Greenstone, and spent hours of her time with us over many days, so that 2.83 may work on Mac Tigers as well.