Jump to content

Topic on Project:Support desk

[Solved]uploading file getting error "Error creating thumbnail: /bin/bash: /usr/bin/convert: Is a directory"

9
Asafm14567 (talkcontribs)

Hello everyone

i created the folder /usr/bin/convert as ImageMagick requires it as it states in the "localsettings.php" file now i can thumbnail jpeg files

when i try to thumbnail a png file it gives me this error Error creating thumbnail: /bin/bash: /usr/bin/convert: Is a directory

i dont understand why when i didnt have the folder i couldnt at all when i got the folder it says the folder exist but does nothing

i added // Override the default with a bundle of filetypes: $wgFileExtensions = array(

   'png', 'gif', 'jpg', 'jpeg', 'jp2', 'webp', 'ppt', 'pdf', 'psd',
   'mp3', 'xls', 'xlsx', 'swf', 'doc','docx', 'odt', 'odc', 'odp',
   'odg', 'mpp'
   );

to make sure all the extension are supported and still the same thing

thanks in advance

Ciencia Al Poder (talkcontribs)

I don't see anywhere in LocalSetttings.php a text stating that you must create a directory named /usr/bin/convert

See Manual:Image thumbnailing. You may need to install ImageMagick on the server

Asafm14567 (talkcontribs)

the default settings for $wgImageMagickConvertCommand asks for the path /usr/bin/convert

but how do i insall imagemagick on the server i dont see any manuals of it

after i added /usr/bin/convert i can thumbnail only jpeg fails all the rest give me the error Error creating thumbnail: /bin/bash: /usr/bin/convert: Is a directory error 126

Asafm14567 (talkcontribs)
Clump (talkcontribs)

"convert" is not a directory, it is a command provided by ImageMagick. The $wgImageMagickConvertCommand should give the full path of the convert command, and it is usually installed in /usr/bin, so that is why it is usually set to "/usr/bin/convert".

Remove the /usr/bin/convert directory you made and install ImageMagick. The link Ciencia provided tells you where to go for that, or look for it in whatever package manager your system is using.

jpegs are being converted by something else, perhaps GD as part of your PHP install, as that same linked page explains.

Asafm14567 (talkcontribs)

thanks alot

Asafm14567 (talkcontribs)
Asafm14567 (talkcontribs)
Soumya.sadanandan (talkcontribs)

Same error-- resolved by installing Imagemagik and pointing to the ImageMagick/bin/convert folder in localsettings.php