[greenstone-users] Ignore previous message - Re: perl/GLI error

From Greenstone Team
DateThu Sep 1 14:43:36 2011
Subject [greenstone-users] Ignore previous message - Re: perl/GLI error
In-Reply-To (4E5D2B47-3060008-lavabit-com)
Ignore the other email I just sent. The links in it appear wrong in my
outbox. Hopefully they'll look right this time.

Hi Tel,

There's some more questions to help us work out what's going wrong.
However, at the end of this e-mail, there's a suggestion that I'm
thinking could resolve your problem.

1. You had set up your Greenstone installation as a remote Greenstone
(GS) server and were trying to connect to it from the client. That could
mean that the perl that the remote GS server finds is different from the
one it would find if run locally. My questions last time were about what
version of perl is found by GS when run locally, which you discovered
was a version 5.8.8.

To find out which perl the remote GS server detects, can you visit your
Greenstone library on the web:
e.g. http://localhost/greenstone/cgi-bin/library.cgi

Though in your case it will not be "localhost".
Then remove the "library.cgi" from the end, replacing it with
gliserver.pl?cmd=check-installation
http://localhost/greenstone/cgi-bin/gliserver.pl?cmd=check-installation

so that you get something like
http://localhost/greenstone/cgi-bin/gliserver.pl?cmd=check-installation

Visiting that URL should produce some output in the browser, displaying
the environment that the remote GS server is running in and which
determine what programs the remote GS has access to. The PATH variable
will be printed out, and contains the location where GS will be looking
for perl.

In your next email, can you copy and paste the output you see on
visiting that URL?

2. From your recent email to me, I know what *version* of perl your
*local* GS finds. And I've just asked you to send me the information
that will tell me *where* the *remote* GS will be looking to find perl.

However, I didn't ask you *where* the perl found by your *local*
Greenstone is. To answer this, you will need to open a terminal (x-term)
on the machine where your Greenstone server is installed. Then type the
following into the x-term:

> which perl

Can you send me the output from the terminal?
In my case, running "which perl" printed out: /usr/bin/perl
I'll use this as an example in step 3 below.

3. If it's the case that your Greenstone works well locally (local GLI
interacts successfully with your local Greenstone server), then the
following may hopefully resolve the perl issues that your remote
Greenstone server is having. This could then allow your remote GLI
client to properly work with your remote GS server.

a. Make sure the remote GS web server is stopped.
b. On the machine where the remote GS is installed, use a file browser
to go to your Greenstone installation folder.
c. There should be a subdirectory called cgi-bin. Inside it, there's a
file called "gsdlsite.cfg". Open this in a text editor.

d. Locate the line in that file that starts with
#perlpath /usr/bin

e. Remove the # sign in front of that line to uncomment it. This
activates the line and tells the remote Greenstone server to use *that*
perl when it runs.

f. Fill in the value for perlpath using the answer you found for
question 2. But lop off any "perl" suffix from it so that you are left
with only the path to the "bin" folder containing the perl executable.
In my example from step 2, "/usr/bin/perl" becomes "/usr/bin", so that
in the case of my example the perpath line in gsdlsite.cfg will read:
perlpath /usr/bin

g. Save the file, restart your remote GS web server and try connecting
your remote GLI client to it once more.
Any luck?


Don't forget to send us the output for questions 1 and 2 (especially if
the above did not resolve it for you).
Regards,
Anupama


Tel wrote:
> dear anupama,
>
> thanks for your reply. here is the info you requested. no worries on
> the delay, any help is appreciated.
>
> -----------------
>
> 1- perl -version
>
> This is perl, v5.8.8 built for i386-linux-thread-multi
>
> Copyright 1987-2006, Larry Wall
>
> Perl may be copied only under the terms of either the Artistic License
> or the
> GNU General Public License, which may be found in the Perl 5 source kit.
>
> Complete documentation for Perl, including FAQ lists, should be found on
> this system using "man perl" or "perldoc perl". If you have access to
> the
> Internet, point your browser at http://www.perl.org/, the Perl Home Page.
>
> 2- cd /usr/local/Greenstone
>
> source setup.bash
>
> Your environment has successfully been set up to run Greenstone
> +Your environment is now setup for the GNOME support library extension
> +Adding in executable path for apache-httpd
>
> perl -version
>
> This is perl, v5.8.8 built for i386-linux-thread-multi
>
> Copyright 1987-2006, Larry Wall
>
> Perl may be copied only under the terms of either the Artistic License
> or the
> GNU General Public License, which may be found in the Perl 5 source kit.
>
> Complete documentation for Perl, including FAQ lists, should be found on
> this system using "man perl" or "perldoc perl". If you have access to
> the
> Internet, point your browser at http://www.perl.org/, the Perl Home Page.
>
> -----------------
>
>
>
>
>
> On 30/8/2011 07:08, ak19 wrote:
>> Hi Tel,
>>
>> This looks like it could be a more serious problem as it seems like a
>> library issue. I'll have to ask other people about it. Will let you
>> know what can be done about it when I find out.
>>
>> 1. What version of Perl is your server machine using?
>> To find out, open a terminal and type (don't type >, it represents
>> the terminal prompt:
>>
>> > perl -version
>>
>> 2. Then, just in case your greenstone is finding a different perl,
>> use a terminal to go into your greenstone 2.84 installation, source
>> setup.bash and run the same command again, as follows:
>>
>> > cd /full/path/to/your/greenstone2.84
>> > source setup.bash
>> > perl -version
>>
>> Can you send me the version number of perl for both questions 1 and 2
>> above?
>>
>> I'll find out what other information we need to work out where things
>> are going wrong. I'm sorry it's taken long for responses, there's
>> just a lot of work to be done before the upcoming release that
>> there's not enough time to look through the mailing list.
>>
>> Regards,
>> Anupama
>
>
>