[svn latest] 500 Internal Server Error

apeironian

Joined: 2004-11-15
Posts: 32
Posted: Fri, 2006-09-08 16:09

Here's a doozey for you guys -

I've been getting this error on and off, while performing various tasks in my Gallery. The latest occurence happens when I rotate a certain image. I receive the browser error:


Internal Server Error
The server encountered an internal error or misconfiguration and was unable to complete your request.
Please contact the server administrator,

and inform them of the time the error occurred, and anything you might have done that may have caused the error.
More information about this error may be available in the server error log.
Additionally, a 404 Not Found error was encountered while trying to use an ErrorDocument to handle the request.

so I looked at the http log on the webserver, and it contained:


[Fri Sep 08 06:23:06 2006] [error] [client xxxxxxxxxx] Premature end of script headers: php.cgi, referer: http://apeironian.com/gallery/main.php?g2_view=core.ItemAdmin&g2_subView=core.ItemEdit&g2_itemId=14806&g2_editPlugin=ItemEditRotateAndScalePhoto&g2_navId=x2f9f3808
[Fri Sep 08 06:23:06 2006] [error] [client xxxxxxxxxx] File does not exist: /home/clervi/apeironian.com/internal_error.html, referer: http://apeironian.com/gallery/main.php?g2_view=core.ItemAdmin&g2_subView=core.ItemEdit&g2_itemId=14806&g2_editPlugin=ItemEditRotateAndScalePhoto&g2_navId=x2f9f3808

As you can see, my web host runs PHP in cgi mode. Not sure how this affects things.

After I get this error, I reload the page and see that the image has in fact been rotated, but a new thumbnail has not been generated. Instead, the full-size image is being used as the thumbnail. On some occasions, getting this error while either modifying or uploading a new photo causes an album to be unviewable (I received this same error when I try to view the album). The only way I can then view the album is if I navigate directly to the "corrupted" image and delete it.

Does anyone have an idea of what could be causing this problem? Is there a chance that it's not Gallery that's causing it, but the way my web host has things set up? Could this be a case of an error while calling the "convert" binary when uploading (resize for thumbnail) or rotating an image?

Any troubleshooting help is greatly appreciated!

Mike

----------------------------------------------------
UPDATE: I think this may have something to do with lock timeouts, because I tried to do a similar operation, and instead of getting a 500 Internal error, I got a Gallery lock timeout error page. Supposedly my ISP uses NFS for storage, so I have been trying to use DB locking, but I've had about equal success with using file locking. Does this seem significant?

----------------------------------------------------
UPDATE 2: I get this error when manually adding an image from the web browser also - although the image is successfully added and thumbnail is correctly created when I reload the page.

This is freaking me out man.


Gallery version = 2.2-svn core 1.1.16
PHP version = 4.4.2 cgi
Webserver = Apache/2.0.54 (Unix) PHP/4.4.2 mod_ssl/2.0.54 OpenSSL/0.9.7e mod_fastcgi/2.4.2 DAV/2 SVN/1.1.4
Database = mysql 5.0.18-standard-log, lock.system=database
Toolkits = ArchiveUpload, Exif, Getid3, NetPBM, SquareThumb, Thumbnail, ImageMagick, Ffmpeg, LinkItemToolkit
Acceleration = partial/900, partial/900
Operating system = Linux jerky 2.4.32-grsec+f6b+gr217+nfs+a32+fuse23+++opt+c6+gr2b-v6.192 #1 SMP Wed Dec 14 17:06:16 PST 2005 i686
Default theme = carbon
gettext = enabled
Locale = en_US
Browser = Mozilla/5.0 (Macintosh; U; PPC Mac OS X Mach-O; en-US; rv:1.8.0.6) Gecko/20060728 Firefox/1.5.0.6