Linux - NewbieThis Linux forum is for members that are new to Linux.
Just starting out and have a question?
If it is not in the man pages or the how-to's this is the place!
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
I'm using the Ubuntu 9.04 (Jaunty jackalope) server and am trying to get bugzilla running for internal use only. It seems that everything loaded properly and mysql was setup properly. But when I try to run bugzilla3 from firefox (I'm just doing http://myipaddress/bugzilla) I get the 404 Not Found error that says "The requested URL /usr/lib/cgi-bin/bugzilla3/index.cgi was not found on this server." That directory does exist and index.cgi is there. I'm new to apache things so I may be missing something there? I found that if I do http://myipaddress/cgi-bin/bugzilla3/index.cgi in firefox then bugzilla runs but without a skin/template (not nice looking at all with no formatting). When that worked I also tried changing /var/www/bugzilla/index.html to reference /cgi-bin/bugzilla3/index.cgi instead of /usr/lib/cgi-bin/bugzilla3/index.cgi as it was initially but that still resulted in the same 404 error mentioned above. Does anybody know what is going on here. I suspect this is just me being a newbie, but I'd appreciate some guidance. I've searched loads of forums and haven't found any solutions yet.
Thanks for the help anomie. I don't actually have a httpd.conf file. Ubuntu seems to have changed how they do that. Instead I looked in the sites-available directory (under apache2) and greped on bugzilla3.conf. There is no line with CustomLog in that file. I edited the file looking for variations on that name. There was nothing. So I went to /var/log/apache2 and tailed access.log which showed me my most recent attempt to load the page. The exact line in the log is:
192.168.1.2 - - [09/Sep/2009:15:10:27 +0800] "GET /usr/lib/cgi-bin/bugzilla3/index.cgi HTTP/1.1" 404 283 "-" "Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.9.0.13) Gecko/2009080315 Ubuntu/9.04 (jaunty) Firefox/3.0.13"
In my bugzilla3.conf file it does have the following:
<Directory "/usr/lib/cgi-bin/bugzilla3">
AddHandler cgi-script cgi
DirectoryIndex index.cgi
Options +Indexes +ExecCGI -MultiViews +SymLinksIfOwnerMatch +FollowSymLinks
AllowOverride None
Order allow,deny
Allow from all
</Directory>
I thought that top line is what let me enter http:/serveripaddress/cgi-bin/bugzilla3/index.cgi and have it work (with index.cgi actually under /usr/lib...). But I'm an apache weanie so may be completely wrong about that.
Based on your thoughts I also tried adding a ScriptAlias to the bugzilla3.conf file (and restarting apache) but that didn't seem to do anything. It is certainly possible that I didn't do the ScriptAlias correctly as this was the first time I've learned of this directive.
Any other thoughts you might have on this problem will be appreciated!
I don't actually have a httpd.conf file. Ubuntu seems to have changed how they do that. Instead I looked in the sites-available directory (under apache2) and greped on bugzilla3.conf.
Those crazy Ubuntu devs. (I should have fired up my Ubuntu laptop before suggesting where to look for httpd's config...)
Quote:
Originally Posted by qhhatman
I went to /var/log/apache2 and tailed access.log which showed me my most recent attempt to load the page. The exact line in the log is:
Sure enough, that's a HTTP 404. Could you copy and paste the exact path from that log and then run in your terminal:
Code:
$ file /usr/lib/cgi-bin/bugzilla3/index.cgi
You're doubly sure it is there?
What happens if you (temporarily) rename the index.cgi file to index.cgi.foo? Does your browser show you a directory listing? (It should, based on your Directory setup.)
Result of the file command:
/usr/lib/cgi-bin/bugzilla3/index.cgi: a /usr/bin/perl -wT script text executable
So it really is at that path despite the log entry.
When I rename index.cgi I get the same result, the 404 error, because then it really isn't there.
Previously I mentioned that if if I do http://myipaddress/cgi-bin/bugzilla3/index.cgi in firefox then bugzilla runs but without a skin/template (not nice looking at all with no formatting). While experimenting with all of this I tried creating an account from there. Nothing appeared on the screen indicating success or failure, but the log, interestingly, indicated that the call to the createaccount.cgi succeeded but no skins could be found. Here's the log entires:
So from this it looks like it found some alias somewhere that didn't add the /usr/lib in front of /cgi-bin. I'm not sure why it happened there but won't do the same from my initial browser entry.
that didn't work either. By the way, I do have other sites that I've successfully run from this server, though none of them are setup to run .cgi's from another directory path like bugzilla does. I really appreciate the continued help anomie! It sure is nice to have knowledgeable people like yourself to help us greenhorns.
Here is my full bugzilla3.conf file:
<VirtualHost *:80>
If you find this to be the case with /usr/lib/cgi-bin/bugzilla3 or any of its parents - /usr, /usr/lib, /usr/lib/cgi-bin - then I would remove +SymLinksIfOwnerMatch from your Options directive and try again. It may be that ownership is messed up, and this would be a quick way to test that.
-------
I'd add that it would be very helpful if you added a -
Code:
LogLevel info
- directive to your Apache configuration. Then, check Apache's error log after attempting to view the page again. That may yield some useful clues.
-------
One more thing: remember that you need to restart (gracefully or otherwise) Apache web server after making configuration changes for them to take effect.
Success!
I'm not sure why it didn't work last Friday given the changes. But today I added the LogLevel info command (after checking that the directory's were not links, which they are not) and restarted apache. I had done a graceful restart last Friday but today I just did an "/usr/sbin/apache2ctl -k restart". I also cleared the cache on FF before loading bugzilla. Whatever happened today it worked and I think the AliasScript you advised me about is what did it. Now I just have to get the skins to work. I see from the page source it is looking for the css files in /bugzilla3/skins/standard/*.css, so hopefully I can just add an alias in my bugzilla3.conf file and get the skins to work properly.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.