[greenstone-users] RE: Unresolved IIS6 issue with gliserver.pl

From Samuel Tyszler
DateMon, 12 Mar 2007 11:59:11 -0400
Subject [greenstone-users] RE: Unresolved IIS6 issue with gliserver.pl
In-Reply-To (45F4CD4B-3030303-cs-waikato-ac-nz)

Thank you for getting back to me.

Although I cannot be positive that I am doing that correctly, I added what you said to. No matter what the order the errors persist.

In the Hello World page I switched to text/plain and it works just fine.

The troubleshooting may be suffering a bit because I am not versed in Perl nor a web programmer. I am sure an expert can look at the code while simultaneously testing off an IIS server and probably find a tiny error somewhere. It would be fantastic if a developer were to directly test against our server. I am not the best one to be tweaking the code like this.




From: Katherine Don [mailto:kjdon@cs.waikato.ac.nz]
Sent: Sunday, March 11, 2007 11:47 PM
To: Samuel Tyszler
Cc: Greenstone Users List; David Milne
Subject: Re: Unresolved IIS6 issue with gliserver.pl


Hi Samuel

The check-installation command outputs as content-type text/plain. I wonder if that makes a difference?
Could you modify your hello world to be plain text output and see if it still works?

Your script doesn't output the status header, so its unclear whether a missing status header is the problem.
But you can try outputting it - the place David suggested wasn't actually the right place.
The check-installation commands use generate_ok_message and generate_error methods in cgi-bin/gsdlCGI.pm.
Look for these two methods and add
    $l = 1; # flush STDOUT
    print STDOUT "Status: 200 OK ";
before the  line
print STDOUT "Content-type:text/plain ";
in each one.

I don't know whether order of Status and Content-type makes a difference. You can try changing it.

Does this help at all???


Samuel Tyszler wrote:

Dear Greenstone Team,

I am stuck getting Greenstone to work properly on my IIS 6 server. I have sent several emails on this to both the list and individual team members where appropriate. It seems that I get a response with a possible clue and a request to follow up (which I have done), but then no response back.

It is pretty clear to me that something is wrong with the way the gliserver.pl script outputs headers under IIS. If you look through the thread I have included below you will see that I have tested other code which runs successfully and the Greenstone Library runs as well. I do not have good enough knowledge of the scripting language to fix this. I was hoping to hear back from David, but I have not as yet.

As I have stated below, I am happy to allow the development team access to our server to test any fixes and make them public to the community. We are not the only ones experiencing this issue. I have been contacted privately by another institution seeking a fix.

I hope that someone will be able to work with us to be able to finally and fully resolve this problem. It is keeping us from going live which we need to do soon. We are in a bind.

I truly appreciate any assistance the Greenstone team can render.

Samuel D. Tyszler
Management Information Services
Yeshiva University


Thanks for your response.


Your suggestion didn't work. But it did give me an insight into the issue and inspired me to test this in a different way. I found a "Hello World" type script online and I successfully executed it on the server. So the set up of the web server is ok. Here is the script that runs:




print "Content-type: text/html ";

print <<HTML;



<title>A Simple Perl CGI</title>



<h1>A Simple Perl CGI</h1>

<p>Hello World</p>





You can execute that at 


Attempting to execute fails.


You may have full access to my web server to help diagnose this issue and provide a solution to the community. I just got an email from another user in my position who is also seeking a fix. Mine is not an isolated incident. Contact me off list and I will be happy to provide you with credentials that will allow access.




-----Original Message-----

From: David Milne [mailto:dnk2@cs.waikato.ac.nz]

Sent: Wednesday, February 28, 2007 8:57 PM

To: Samuel Tyszler

Cc: greenstone-users@list.scms.waikato.ac.nz

Subject: Re: [greenstone-users] Greenstone on IIS 6?


Hi Sam,


I dont have an IIS installation so I cant try this out myself.


Could you please have a look at the gliserver.pl script in the cgi-bin directory?

There is a line at the end of the get_script_options method where it outputs the content type. Just before this, try inserting the line:


print STDOUT "Status: 200 OK " ;


then restart the webserver and see how that works. Let me know what happens either way.





Type: image/jpeg
Filename: image001.jpg