Whole server hangs after convert

Questions and postings pertaining to the usage of ImageMagick regardless of the interface. This includes the command-line utilities, as well as the C and C++ APIs. Usage questions are like "How do I use ImageMagick to create drop shadows?".
Post Reply
Coded Monkey
Posts: 3
Joined: 2014-05-01T03:27:54-07:00
Authentication code: 6789

Whole server hangs after convert

Post by Coded Monkey »

Hello, we run the ImageMagick CLI at a variety of websites across our server, recently we rolled it out on a website specifically for printing and they supplied us with the following image: http://www.codedmonkey.com/temp/faultyimage.jpg The client that supplied the image told us it was a JPEG2000-file.

The image get's uploaded with jQuery File Upload and is converted using ImageMagick's convert to automatically create a scaled JPEG-version of the image. Here is where the trouble begins. The whole server stops responding for over a minute, bringing multiple websites down, before eventually showing the correct page with a converted image.

I don't have direct access to the ImageMagick logs, but the output of the action when send to the Apache error log shows

Code: Select all

image not a jpeg file
I've tried multiple things but I can't figure out what's wrong, I've looked at the supported image formats and it states to following:

Code: Select all

     JPEG* JPEG      rw-   Joint Photographic Experts Group JFIF format (62)<br />
      JPG* JPEG      rw-   Joint Photographic Experts Group JFIF format<br />
Is anybody familiar with this issue and what can I do to stop the server from hanging?
Thank you :)
snibgo
Posts: 12159
Joined: 2010-01-23T23:01:33-07:00
Authentication code: 1151
Location: England, UK

Re: Whole server hangs after convert

Post by snibgo »

For me, it takes 8 seconds to:

Code: Select all

convert faultyimage.jpg f.png
It doesn't complain.

This is on IM v6.8.9-0 on Windows 8.1. What version of IM are you running? Information about JPEG library version or whatever might also be useful.
snibgo's IM pages: im.snibgo.com
Coded Monkey
Posts: 3
Joined: 2014-05-01T03:27:54-07:00
Authentication code: 6789

Re: Whole server hangs after convert

Post by Coded Monkey »

Thank you for replying.

The version of ImageMagick i'm running is ImageMagick 6.2.8 05/07/12 Q16
The information I get about libjpeg is: libjpeg.so.62, libjpeg.so.62.0.0

I also just tried

Code: Select all

identify -verbose faultyimage.jpg
and the server hung at this command too, don't know if that helps.

Thank you
snibgo
Posts: 12159
Joined: 2010-01-23T23:01:33-07:00
Authentication code: 1151
Location: England, UK

Re: Whole server hangs after convert

Post by snibgo »

v6.2.8 is old. Very old. Prehistoric. Probably this century, but only just.

The oldest version on my computer is v6.5.8. It is dated 2009. It converts your file without complaint.
snibgo's IM pages: im.snibgo.com
Coded Monkey
Posts: 3
Joined: 2014-05-01T03:27:54-07:00
Authentication code: 6789

Re: Whole server hangs after convert

Post by Coded Monkey »

That sounds like a reasonable explanation, it should have been updated a long time ago like you said but we have a third party to handle our server management that's why it hasn't been done. I really appreciate the quick help, thank you :D
Post Reply