kuemerle5 Posted June 3, 2011 Report Share Posted June 3, 2011 Not really the biggest of issues but an issue nonetheless i suppose. So I recently installed Drupal 7 and attempted to add some images but received some fatal errors. Like: Warning: imagecreatefromjpeg(): 'public://Jellyfish.jpg' is not a valid JPEG file in image_gd_load() (line 237 of/home/happyplace/public_html/somesite.org/modules/system/image.gd.inc) Warning: imagecreatefromjpeg(): gd-jpeg: JPEG library reports unrecoverable error: in image_gd_load() (line 237 of/home/happyplace/public_html/somesite.org/modules/system/image.gd.inc) Okay, so maybe the Drupal code is broken. So I tried switching over to ImageMagick for processing. Same type of errors are happening ("unable to generate the derived image" most likely similar to the invalid JPEG error from earlier). At this point, I get the feeling it may not be Drupal's fault. *Throw hands up in air* Then I get the idea to switch the Drupal install over to PHP 52 (it was running 53) and lo and behold, everything is working! So I'm thinking maybe the PHP 53 binary or image modules were compiled incorrectly? Who knows... Just thought I'd put that out there. Not a big deal, but PHP 53 does have better performance and I would prefer to use it. Also, feel free to answer my poll! Just a little something I thought would be a good idea. Not for school or official research or anything. Quote Link to comment Share on other sites More sharing options...
Adam Posted June 4, 2011 Report Share Posted June 4, 2011 Not really the biggest of issues but an issue nonetheless i suppose. So I recently installed Drupal 7 and attempted to add some images but received some fatal errors. Like: Warning: imagecreatefromjpeg(): 'public://Jellyfish.jpg' is not a valid JPEG file in image_gd_load() (line 237 of/home/happyplace/public_html/somesite.org/modules/system/image.gd.inc) Warning: imagecreatefromjpeg(): gd-jpeg: JPEG library reports unrecoverable error: in image_gd_load() (line 237 of/home/happyplace/public_html/somesite.org/modules/system/image.gd.inc) Okay, so maybe the Drupal code is broken. So I tried switching over to ImageMagick for processing. Same type of errors are happening ("unable to generate the derived image" most likely similar to the invalid JPEG error from earlier). At this point, I get the feeling it may not be Drupal's fault. *Throw hands up in air* Then I get the idea to switch the Drupal install over to PHP 52 (it was running 53) and lo and behold, everything is working! So I'm thinking maybe the PHP 53 binary or image modules were compiled incorrectly? Who knows... Just thought I'd put that out there. Not a big deal, but PHP 53 does have better performance and I would prefer to use it. Also, feel free to answer my poll! Just a little something I thought would be a good idea. Not for school or official research or anything. I have the same exact problem! Except I'm running WP. All of my themes that use timthumb.php doesn't work. And I am using php 5.3. Quote Link to comment Share on other sites More sharing options...
SnakEyez Posted June 4, 2011 Report Share Posted June 4, 2011 There are posts about this on the Drupal forums. One person suggested a new jpglib resulted in a conflict and some people say that the images ended up being corrupted locally and the library was refusing them. Quote Link to comment Share on other sites More sharing options...
Michael D. Posted June 28, 2011 Report Share Posted June 28, 2011 Not really the biggest of issues but an issue nonetheless i suppose. So I recently installed Drupal 7 and attempted to add some images but received some fatal errors. Like: Warning: imagecreatefromjpeg(): 'public://Jellyfish.jpg' is not a valid JPEG file in image_gd_load() (line 237 of/home/happyplace/public_html/somesite.org/modules/system/image.gd.inc) Warning: imagecreatefromjpeg(): gd-jpeg: JPEG library reports unrecoverable error: in image_gd_load() (line 237 of/home/happyplace/public_html/somesite.org/modules/system/image.gd.inc) Okay, so maybe the Drupal code is broken. So I tried switching over to ImageMagick for processing. Same type of errors are happening ("unable to generate the derived image" most likely similar to the invalid JPEG error from earlier). At this point, I get the feeling it may not be Drupal's fault. *Throw hands up in air* Then I get the idea to switch the Drupal install over to PHP 52 (it was running 53) and lo and behold, everything is working! So I'm thinking maybe the PHP 53 binary or image modules were compiled incorrectly? Who knows... Just thought I'd put that out there. Not a big deal, but PHP 53 does have better performance and I would prefer to use it. Also, feel free to answer my poll! Just a little something I thought would be a good idea. Not for school or official research or anything.If you haven't, do open a ticket for this so we can look into it. If you did open a ticket, let me know the ticket ID. Quote Link to comment Share on other sites More sharing options...
Michael D. Posted June 28, 2011 Report Share Posted June 28, 2011 I made some changes to the server you're on for PHP53, so give it another try and let me know. If not, open a ticket and ask for me (Michael Denney). Quote Link to comment Share on other sites More sharing options...
kuemerle5 Posted June 28, 2011 Author Report Share Posted June 28, 2011 Sure thing. I'll set up a Drupal sandbox (maybe even try to reproduce Adam's problem with WordPress as well) in the next few hours and I'll post the results here Quote Link to comment Share on other sites More sharing options...
Michael D. Posted June 28, 2011 Report Share Posted June 28, 2011 Sure thing. I'll set up a Drupal sandbox (maybe even try to reproduce Adam's problem with WordPress as well) in the next few hours and I'll post the results here The issue was indeed a change in LibJPEG and we had to rebuild GD/ImageMagick for it but it *should* be working now. I know it's working in 5.2 but I don't have any test sites to try with 5.3. Quote Link to comment Share on other sites More sharing options...
kuemerle5 Posted June 28, 2011 Author Report Share Posted June 28, 2011 Well, it looks like I'm getting the same problem:Warning: imagecreatefromjpeg(): gd-jpeg: JPEG library reports unrecoverable error: in image_gd_load() (line 237 of /home/happy_meal/public_html/sb/modules/system/image.gd.inc). Warning: imagecreatefromjpeg(): 'public://Blue hills.jpg' is not a valid JPEG file in image_gd_load() (line 237 of /home/happy_meal/public_html/sb/modules/system/image.gd.inc). This time, I'll try and debug a little bit more. I'll set up a PHP error log and see what's happening in there and I'll post this issue in Drupal's issue tracker. Again, I will post what I find in hopes that this pesky bug get fixed. Quote Link to comment Share on other sites More sharing options...
Michael D. Posted June 28, 2011 Report Share Posted June 28, 2011 I'm trying one more thing, I'll update this thread momentarily once I'm ready for you to re-try it Quote Link to comment Share on other sites More sharing options...
Michael D. Posted June 28, 2011 Report Share Posted June 28, 2011 Ok, try it now. Quote Link to comment Share on other sites More sharing options...
kuemerle5 Posted June 28, 2011 Author Report Share Posted June 28, 2011 We have a winner! Thanks Mike! Btw, what was the issue? Quote Link to comment Share on other sites More sharing options...
Michael D. Posted June 28, 2011 Report Share Posted June 28, 2011 Just needed to do a fresh build of php 5.3. I forgot to run "make clean" before running the rebuild last time. Quote Link to comment Share on other sites More sharing options...
kuemerle5 Posted June 28, 2011 Author Report Share Posted June 28, 2011 You learn something new everyday... Quote Link to comment Share on other sites More sharing options...
Yuri Posted February 22, 2012 Report Share Posted February 22, 2012 I know the issue is too old but I'm having the same problem today using Drupal 7 in PHP 5.3 Warning: imagecreatefromjpeg(): gd-jpeg: JPEG library reports unrecoverable error: in image_gd_load() (line 237 of /home/shepherd/public_html/main/modules/system/image.gd.inc). Warning: imagecreatefromjpeg(): 'public://latenightinthezone.jpg' is not a valid JPEG file in image_gd_load() (line 237 of /home/shepherd/public_html/main/modules/system/image.gd.inc). Warning: imagecreatefromjpeg(): gd-jpeg: JPEG library reports unrecoverable error: in image_gd_load() (line 237 of /home/shepherd/public_html/main/modules/system/image.gd.inc). Warning: imagecreatefromjpeg(): 'public://latenightinthezone.jpg' is not a valid JPEG file in image_gd_load() (line 237 of /home/shepherd/public_html/main/modules/system/image.gd.inc). Quote Link to comment Share on other sites More sharing options...
Michael D. Posted February 22, 2012 Report Share Posted February 22, 2012 The same as response #4 above, if you haven't opened a ticket - please do so. Quote Link to comment Share on other sites More sharing options...
Michael D. Posted February 22, 2012 Report Share Posted February 22, 2012 This has been fixed on the Cypress server (I tested to make sure). Quote Link to comment Share on other sites More sharing options...
Yuri Posted February 22, 2012 Report Share Posted February 22, 2012 Thanks, It's now working, I'll submit a ticket next time.This has been fixed on the Cypress server (I tested to make sure). Quote Link to comment Share on other sites More sharing options...
Michael D. Posted February 23, 2012 Report Share Posted February 23, 2012 You're welcome to ask here, as others may have an answer. But if somebody asks a question and is advised previously for the same issue to open a ticket, that's probably the best course of action . Quote Link to comment Share on other sites More sharing options...
Michael D. Posted May 29, 2012 Report Share Posted May 29, 2012 Oh, and in case anybody is wondering what the issue itself was. It had to do with GD+LibJPEG and mismatched versions. It was a side-effect of something custom that we've done on our servers but it's quite possible for it to happen at another provider as well. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.