Welcome to Geeklog Monday, July 26 2021 @ 03:54 pm EDT

Geeklog Forums

Media Gallery: "error converting uploaded file"


Status: offline

mstewart

Forum User
Newbie
Registered: 09/07/07
Posts: 13
All the sudden, Im getting this error when uploading files an all 3 of my Geeklog sites.
In my Geeklog error log I am getting:
10/23/07 09:47:53 - MG Upload: Error creating thumbnail
10/23/07 09:47:53 - MG Upload: Problem uploading a media object

I am able to pass the imagemagik test when I do the command:
convert logo: logo.gif
imdisplay logo.gif

I can not think of anything I have done lately on the system to make it stop working. It has been working for months.
The thumbnail rebuild admin function seems to work.

I had this problem before.
http://www.geeklog.net/forum/viewtopic.php?showtopic=77237

Thoughts?
Mike
 Quote

Status: offline

mevans

Forum User
Full Member
Registered: 08/02/04
Posts: 393
Location:Texas
Mike,

First, let's turn on verbose logging in Media Gallery. See Media Gallery Wiki - Troubleshooting for details.

Second, give me a clue on the type of media you are uploading? Do all uploads fail now, or just a specific set of files?

The verbose logging in Geeklog's error log should give us some more clues.

Thanks!
Mark
 Quote

Status: offline

mstewart

Forum User
Newbie
Registered: 09/07/07
Posts: 13
Turned error logging on. Upload a zip file works. jpg gives error. Here is the log.
10/23/07 10:13:35 - MG Upload: Entering MG_getFile()
10/23/07 10:13:35 - MG Upload: Filename to process: C:\WINDOWS\TEMP\php22.tmp
10/23/07 10:13:36 - MG Upload: getID3 analyzing file: C:\WINDOWS\TEMP\php22.tmp
10/23/07 10:13:36 - MG Upload: getID3 found mime_type: image/jpeg
10/23/07 10:13:36 - MG Upload: found mime type of jpg
10/23/07 10:13:36 - MG Upload: PHP detected mime type is : image/pjpeg
10/23/07 10:13:36 - MG Upload: Stored filename is : 9_boshears07lurch.jpg
10/23/07 10:13:36 - MG Upload: Mime Type: image/jpeg
10/23/07 10:13:36 - MG Upload: About to move/copy file
10/23/07 10:13:36 - MG Upload: Calling MG_convertImage()
10/23/07 10:13:36 - MG Upload: Entering MG_convertImage()
10/23/07 10:13:36 - MG Upload: Creating thumbnail image
10/23/07 10:13:36 - MG Upload: Converting using ImageMagick src = c:/Inetpub/teamrvgeek/public_html/mediagallery/mediaobjects/orig/9/9_boshears07lurch.jpg mimetype = image/jpeg
10/23/07 10:13:36 - MG Upload: Executing: "c:/imagemagick/convert" -verbose -flatten -quality 85 -size 200x200 c:/Inetpub/teamrvgeek/public_html/mediagallery/mediaobjects/orig/9/9_boshears07lurch.jpg -geometry 200x200 +profile "*" c:/Inetpub/teamrvgeek/public_html/mediagallery/mediaobjects/tn/9/9_boshears07lurch.jpg
10/23/07 10:13:36 - MG Upload: Verbose Command Output
10/23/07 10:13:36 - c:/Inetpub/teamrvgeek/public_html/mediagallery/mediaobjects/orig/9/9_boshears07lurch.jpg JPEG 640x480=>320x240 320x240+0+0 DirectClass 8-bit 58.1523kb

10/23/07 10:13:36 - MG Upload: Error creating thumbnail
10/23/07 10:13:36 - MG Upload: Problem uploading a media object
 Quote

Status: offline

mevans

Forum User
Full Member
Registered: 08/02/04
Posts: 393
Location:Texas
ImageMagick is returning a non-zero return code which means there was some type of error.

Can you put that file on your server and run the following command in a DOS box and let's see if we get some additional output or messages. Obviously change SOURCEFILE.jpg to the actual name of the jpg image and THUMBNAILFILE.jpg to the name of the generated thumbnail.

PHP Formatted Code

"c:/imagemagick/convert" -verbose -flatten -quality 85 -size 200x200 SOURCEFILE.jpg -geometry 200x200 +profile "*" THUMBNAILFILE.jpg
 


Let's see if we can get a little more info out of ImageMagick with this command.

Thanks!
Mark
 Quote

Status: offline

mstewart

Forum User
Newbie
Registered: 09/07/07
Posts: 13
Got the following

convert -verbose -flatten -quality 85 -size 2
00x200 boshears07lurch.jpg -geometry 200x200 +profile "*" boshears07lurch.jpg
Invalid Parameter - -flatten

Mike
 Quote

Status: offline

mevans

Forum User
Full Member
Registered: 08/02/04
Posts: 393
Location:Texas
There we go, for some reason your ImageMagick installation no longer likes the flatten parameter. It is odd that it worked for all this time and just now broke. It would imply that your ImageMagick install has changed.

There are probably a couple of options you can pursue. Either upgrade your ImageMagick to the latest version for Windows, which should support the -flatten command line option or edit lib-upload.php and remove all the -flatten from the command (there are several).

Thanks!
mark


 Quote

Status: offline

mstewart

Forum User
Newbie
Registered: 09/07/07
Posts: 13
Well the upgrade to 6.3.6 from 6.3.5 seemed to have fixed the problem.
It does not make sense why the flatten stopped working. But who am I to question.
I have done absolutely no upgrades to the box in months.

Thanks again for your help. Im back in business.
Best,
Mike
 Quote

All times are EDT. The time is now 03:54 pm.

  • Normal Topic
  • Sticky Topic
  • Locked Topic
  • New Post
  • Sticky Topic W/ New Post
  • Locked Topic W/ New Post
  •  View Anonymous Posts
  •  Able to post
  •  Filtered HTML Allowed
  •  Censored Content