|
Post by stryker on Jul 20, 2007 1:51:52 GMT -5
Hi,
I've had two cracks at the upgrade now, but unfortunately have failed the same way twice. When you try to bring up gm.cgi for the first time this error is displayed:
Software error:
Can't locate Gm_Constants.pm in @inc (@inc contains: libs /usr/share/awstats/lib /usr/share/awstats/plugins /usr/lib/perl5/site_perl/5.8.8/i386-linux-thread-multi /usr/lib/perl5/site_perl/5.8.7/i386-linux-thread-multi /usr/lib/perl5/site_perl/5.8.6/i386-linux-thread-multi /usr/lib/perl5/site_perl/5.8.5/i386-linux-thread-multi /usr/lib/perl5/site_perl/5.8.8 /usr/lib/perl5/site_perl/5.8.7 /usr/lib/perl5/site_perl/5.8.6 /usr/lib/perl5/site_perl/5.8.5 /usr/lib/perl5/site_perl /usr/lib/perl5/vendor_perl/5.8.8/i386-linux-thread-multi /usr/lib/perl5/vendor_perl/5.8.7/i386-linux-thread-multi /usr/lib/perl5/vendor_perl/5.8.6/i386-linux-thread-multi /usr/lib/perl5/vendor_perl/5.8.5/i386-linux-thread-multi /usr/lib/perl5/vendor_perl/5.8.8 /usr/lib/perl5/vendor_perl/5.8.7 /usr/lib/perl5/vendor_perl/5.8.6 /usr/lib/perl5/vendor_perl/5.8.5 /usr/lib/perl5/vendor_perl /usr/lib/perl5/5.8.8/i386-linux-thread-multi /usr/lib/perl5/5.8.8 .) at /var/www/cgi-bin/gm.cgi line 49. BEGIN failed--compilation aborted at /var/www/cgi-bin/gm.cgi line 49.
For help, please send mail to the webmaster (root@localhost), giving this error message and the time and date of the error.
Gm-Constants.pm is located in cgi-bin/libs and is chmod'd to 644, and at 9.8KB size as the archive - I can view it so it's extracted okay. It's present so any hints why might it not be found by the script ?
Thanks Geoff
|
|
|
Post by Carlos Phelps on Jul 20, 2007 8:18:35 GMT -5
|
|
|
Post by stryker on Jul 21, 2007 0:55:35 GMT -5
Thanks Carlos. You're a champion for digging up that thread - I'd not found it in my searches. I've had a play with adding the -wt and then just -t since I read the -w is now depreciated without avail. I tried ./libs and /var/www/cgi-bin/libs in the use lib 'libs'; line but that only resulted in the same error with a different first item that @inc contains rather than libs. I can view the contents of Gm-Constants.pm but this error seems to indicate it just can't locate the file in any place it's been told to find it rather than there's anything particularly wrong with it. Also, riddle me this: gm.cgi from 1.7.2 started with the same sequence of statements. But it worked without error on this machine up to my upgrade attempts I know I must be staring right through the reason. Thanks in advance for any other thoughts on the matter. Cheers! Geoff update: I rolled back to my backup copy of 1.7.2 to find the same error appears now. I do wonder what I've broken!further information: Perl v5.8.8 on Fedora Core 6 with Apache 2.2.4. Sorry I omitted that in the first post.
|
|
|
Post by coldstone on Jul 23, 2007 13:40:38 GMT -5
Could your web host have recently implemented the force Taint? That would explain why your 1.7.2 would break as well.
I would talk to you web host to see if they know of a workaround, or at least to make them aware of the problem they are causing. While I understand their position, since you are the customer, they should be willing to accommodate you somehow.
Also, could you post the new error you get when you added the '-t' to the perl path and then did 'require "./gm-library.cgi";'?
|
|
|
Post by stryker on Jul 23, 2007 20:39:29 GMT -5
Hi Coldstone,
Thanks so much for your response. The bad news is the web host in this case is a Fedora PC that sits in my bedroom. As far as I know, nothing has changed on this system aside from routine patches (and I only put the 'as far as I know...' caveat in front since it's possible I've broken something without knowing). Typically this box just sits and hums and we setup the blog so my family can share photos and stories.
The script doesn't get to the require, it bombs out at the Gm-Constants line which is earlier. Here is the error with the standard script: Software error:
Can't locate Gm_Constants.pm in @inc (@inc contains: libs /usr/share/awstats/lib /usr/share/awstats/plugins /usr/lib/perl5/site_perl/5.8.8/i386-linux-thread-multi /usr/lib/perl5/site_perl/5.8.7/i386-linux-thread-multi /usr/lib/perl5/site_perl/5.8.6/i386-linux-thread-multi /usr/lib/perl5/site_perl/5.8.5/i386-linux-thread-multi /usr/lib/perl5/site_perl/5.8.8 /usr/lib/perl5/site_perl/5.8.7 /usr/lib/perl5/site_perl/5.8.6 /usr/lib/perl5/site_perl/5.8.5 /usr/lib/perl5/site_perl /usr/lib/perl5/vendor_perl/5.8.8/i386-linux-thread-multi /usr/lib/perl5/vendor_perl/5.8.7/i386-linux-thread-multi /usr/lib/perl5/vendor_perl/5.8.6/i386-linux-thread-multi /usr/lib/perl5/vendor_perl/5.8.5/i386-linux-thread-multi /usr/lib/perl5/vendor_perl/5.8.8 /usr/lib/perl5/vendor_perl/5.8.7 /usr/lib/perl5/vendor_perl/5.8.6 /usr/lib/perl5/vendor_perl/5.8.5 /usr/lib/perl5/vendor_perl /usr/lib/perl5/5.8.8/i386-linux-thread-multi /usr/lib/perl5/5.8.8 .) at /var/www/cgi-bin/gm.cgi line 49. BEGIN failed--compilation aborted at /var/www/cgi-bin/gm.cgi line 49.
For help, please send mail to the webmaster (root@localhost), giving this error message and the time and date of the error.
And here's what it shows using the -t flag: Software error:
Can't locate Gm_Constants.pm in @inc (@inc contains: libs /usr/lib/perl5/site_perl/5.8.8/i386-linux-thread-multi /usr/lib/perl5/site_perl/5.8.7/i386-linux-thread-multi /usr/lib/perl5/site_perl/5.8.6/i386-linux-thread-multi /usr/lib/perl5/site_perl/5.8.5/i386-linux-thread-multi /usr/lib/perl5/site_perl/5.8.8 /usr/lib/perl5/site_perl/5.8.7 /usr/lib/perl5/site_perl/5.8.6 /usr/lib/perl5/site_perl/5.8.5 /usr/lib/perl5/site_perl /usr/lib/perl5/vendor_perl/5.8.8/i386-linux-thread-multi /usr/lib/perl5/vendor_perl/5.8.7/i386-linux-thread-multi /usr/lib/perl5/vendor_perl/5.8.6/i386-linux-thread-multi /usr/lib/perl5/vendor_perl/5.8.5/i386-linux-thread-multi /usr/lib/perl5/vendor_perl/5.8.8 /usr/lib/perl5/vendor_perl/5.8.7 /usr/lib/perl5/vendor_perl/5.8.6 /usr/lib/perl5/vendor_perl/5.8.5 /usr/lib/perl5/vendor_perl /usr/lib/perl5/5.8.8/i386-linux-thread-multi /usr/lib/perl5/5.8.8) at /var/www/cgi-bin/gm.cgi line 49. BEGIN failed--compilation aborted at /var/www/cgi-bin/gm.cgi line 49.
For help, please send mail to the webmaster (root@localhost), giving this error message and the time and date of the error.
Are the differences meaningful?
Thanks again guys for your advice and help, Geoff
|
|
|
Post by coldstone on Jul 26, 2007 14:09:15 GMT -5
Whats weird is that I just noticed that 'libs' is in your path (first item) so it should be able to pick up the Gm_Constants.pm file.
I just wanted to verify your setup. You have the libs and lang directories in the '/var/www/cgi-bin/' directory? And you didn't modify any of the files in 'libs' directory?
My apologies for this drawing out, we are so close. I was also wondering, can you try doing a fresh install and see if that works or if you get the same errors?
|
|
|
Post by stryker on Jul 26, 2007 18:06:19 GMT -5
Agreed it's strange!
I've been reading these past few nights to see if there's anything that may have changed in the last few patches for Apache that could have stumped this. I don't see anything.
Also I typically look to SELinux but it's still running in permissive mode so I don't see anything down that path to cause this either.
To do the update I first copied /var/www/cgi-bin and /var/www/html to a backup location. I then expanded the update and copied cgi-bin over /var/www/cgi-bin...this gave me all the new files in /var/www/cgi-bin/lang and /var/www/cgi-bin/libs. I then chmod'd as per the instructions; ran http://myservername/cgi-bin/gm.cgi and hit the error you see here.
It had seemed rather straightforward, and the old version was running right up to the update I believe. Though it's clear it's something about my box that's breaking it since the old script is broken now too.
I've not modified any of the files in the lang or libs directory but have viewed them. The only file I've been messing with has been gm.cgi but I continually have the original to copy back over the top when I'm done.
Incidentally I did download the full version 1.7.3 from both primary sites but the file won't expand. Something about an incompatible format. Therefore at this stage I've not gone for a clean installation.
Since the @inc path does change (after the libs entry) when the -t flag is invoked I presume Taint mode is not being forced on outside our control. And as you say, the libs directory is right there in the path though the . directory is not.
I guess I could try copying the contents of libs to one of the other directories in this path. Last night I've patched up FC6 to the latest set of updates and this did include changes to Apache again...the weekend is time for playing once more.
As ever, thanks for your advice and thoughts on this. Cheers! Geoff
|
|
|
Post by coldstone on Jul 27, 2007 15:47:55 GMT -5
Hmm, that is not good, I tried just now and had trouble with the tar.gz on the first site. I was able to successfully extract from the .zips on both sites. Let me know if the fresh install works.
Otherewise, in the 'use libs' statement, rather than a local path, you could try the fully qualified path like "use lib '/usr/www/libs';. Maybe there is something has an issue with the local path
|
|
|
Post by stryker on Jul 28, 2007 5:46:56 GMT -5
hi coldstone, and thanks for persevering ;D
Using the fully qualified path got me past the first error...here's the new batch: Software error:
Can't locate Gm_Utils.pm in @inc (@inc contains: libs /var/www/cgi-bin /var/www/cgi-bin/libs /usr/share/awstats/lib /usr/share/awstats/plugins /usr/lib/perl5/site_perl/5.8.8/i386-linux-thread-multi /usr/lib/perl5/site_perl/5.8.7/i386-linux-thread-multi /usr/lib/perl5/site_perl/5.8.6/i386-linux-thread-multi /usr/lib/perl5/site_perl/5.8.5/i386-linux-thread-multi /usr/lib/perl5/site_perl/5.8.8 /usr/lib/perl5/site_perl/5.8.7 /usr/lib/perl5/site_perl/5.8.6 /usr/lib/perl5/site_perl/5.8.5 /usr/lib/perl5/site_perl /usr/lib/perl5/vendor_perl/5.8.8/i386-linux-thread-multi /usr/lib/perl5/vendor_perl/5.8.7/i386-linux-thread-multi /usr/lib/perl5/vendor_perl/5.8.6/i386-linux-thread-multi /usr/lib/perl5/vendor_perl/5.8.5/i386-linux-thread-multi /usr/lib/perl5/vendor_perl/5.8.8 /usr/lib/perl5/vendor_perl/5.8.7 /usr/lib/perl5/vendor_perl/5.8.6 /usr/lib/perl5/vendor_perl/5.8.5 /usr/lib/perl5/vendor_perl /usr/lib/perl5/5.8.8/i386-linux-thread-multi /usr/lib/perl5/5.8.8 .) at /var/www/cgi-bin/gm-library.cgi line 20. BEGIN failed--compilation aborted at /var/www/cgi-bin/gm-library.cgi line 20.
For help, please send mail to the webmaster (root@localhost), giving this error message and the time and date of the error. Software error:
[Sat Jul 28 20:40:52 2007] gm.cgi: Can't locate Gm_Utils.pm in @inc (@inc contains: libs /var/www/cgi-bin /var/www/cgi-bin/libs /usr/share/awstats/lib /usr/share/awstats/plugins /usr/lib/perl5/site_perl/5.8.8/i386-linux-thread-multi /usr/lib/perl5/site_perl/5.8.7/i386-linux-thread-multi /usr/lib/perl5/site_perl/5.8.6/i386-linux-thread-multi /usr/lib/perl5/site_perl/5.8.5/i386-linux-thread-multi /usr/lib/perl5/site_perl/5.8.8 /usr/lib/perl5/site_perl/5.8.7 /usr/lib/perl5/site_perl/5.8.6 /usr/lib/perl5/site_perl/5.8.5 /usr/lib/perl5/site_perl /usr/lib/perl5/vendor_perl/5.8.8/i386-linux-thread-multi /usr/lib/perl5/vendor_perl/5.8.7/i386-linux-thread-multi /usr/lib/perl5/vendor_perl/5.8.6/i386-linux-thread-multi /usr/lib/perl5/vendor_perl/5.8.5/i386-linux-thread-multi /usr/lib/perl5/vendor_perl/5.8.8 /usr/lib/perl5/vendor_perl/5.8.7 /usr/lib/perl5/vendor_perl/5.8.6 /usr/lib/perl5/vendor_perl/5.8.5 /usr/lib/perl5/vendor_perl /usr/lib/perl5/5.8.8/i386-linux-thread-multi /usr/lib/perl5/5.8.8 .) at /var/www/cgi-bin/gm-library.cgi line 20. [Sat Jul 28 20:40:52 2007] gm.cgi: BEGIN failed--compilation aborted at /var/www/cgi-bin/gm-library.cgi line 20. Compilation failed in require at /var/www/cgi-bin/gm.cgi line 51.
For help, please send mail to the webmaster (root@localhost), giving this error message and the time and date of the error.
So does this suggest I should edit all the use lib lines in every gm script to include a fully qualified path?
Thanks Geoff
|
|
|
Post by stryker on Jul 28, 2007 6:42:24 GMT -5
So does this suggest I should edit all the use lib lines in every gm script to include a fully qualified path? For the record, I tried this. I ended up getting the first error again - that Gm-Constants.pm wasn't located but this time with /var/www/cgi-bin/libs as the first entry in the @inc list. Strange. Next I've tried a fresh install from the zip file...same error I get when trying the upgrade. This could seriously induce headaches. What to try next - pull Apache out and try again?
|
|
|
Post by stryker on Jul 31, 2007 5:56:07 GMT -5
It's closure time.As you'd expect, the source of this problem was staring me in the face all along. The hint today came with the help of a fresh set of eyes. Permissions. All it came down to was the permissions on the lang and libs subdirectories were set to 644 like their contents. Changing this to 755 in both cases has the scripts running. The error messages unfortunately made this problem look more complex than it ever was. And each time I reinstalled the script I was overzealously chmodding the directories...checking back in the installation instructions tonight there is of course no such direction. Thanks Carlos & coldstone for your patient assistance. I knew I'd broken it but those cryptic errors were sending us all on a wild goose chase. At least I've had a good read about Perl and Apache now We're back up running, and updated to 1.7.3 Cheers, and thanx! Geoff
|
|
|
Post by coldstone on Jul 31, 2007 15:06:24 GMT -5
Thanks very much for posting the solution back. That is excellent news.
I would have to share the blame on this one too, rewriting the install documentation has been a todo for awhile now. Currently I think it might be confusing as to what those directories should be chmod'ed and you are right, they should be 755.
|
|
|
Post by jesper on Aug 8, 2007 14:42:51 GMT -5
Permissions. All it came down to was the permissions on the lang and libs subdirectories were set to 644 like their contents. Changing this to 755 in both cases has the scripts running. Thank you. I fell in the same trap.
|
|
|
Post by stryker on Aug 8, 2007 22:19:08 GMT -5
No, thank you. I don't feel so bad now somehow ;D
|
|