Advanced search  

News:

CPG Release 1.6.26
Correct PHP8.2 issues with user and language managers.
Additional fixes for PHP 8.2
Correct PHP8 error with SMF 2.0 bridge.
Correct IPTC supplimental category parsing.
Download and info HERE

Pages: [1]   Go Down

Author Topic: Error executing ImageMagick - Return value: 127  (Read 42921 times)

0 Members and 1 Guest are viewing this topic.

TheWiz01

  • Coppermine newbie
  • Offline Offline
  • Posts: 6
    • http://www.czgames.com
Error executing ImageMagick - Return value: 127
« on: October 07, 2003, 02:30:27 pm »

I know this has been posted and answers have been supplied but this is where I am at.

I installed Copermine and it is working fine. I uploaded IMAGEMAGICK binary to my webhosting company.

I configured Coppermine to set the convert file for /home/czgames/imagemagick/bin/.

I upload some photos and they are not thumbnailing and when I try to get them in an album I get this error message.

I am just learning this so call me a newb all you want. I am just looking for help. I read about the debug in the config.php to enable it.  Do you have to added the line of code?

It states that IMAGEMAGICK is supposed to work without root access to the webserver.  Is this not correct?

Does my webhosting service have to install either GD or IMAGEMAGICK for me?

If I am missing something just guide me and I will get the answer.

 :oops:
Logged

kegobeer

  • Dev Team member
  • Coppermine addict
  • ****
  • Offline Offline
  • Gender: Male
  • Posts: 4637
  • Beer - it does a body good!
    • The Kazebeer Family Website
Error executing ImageMagick - Return value: 127
« Reply #1 on: October 07, 2003, 05:10:29 pm »

ImageMagick must be installed by your webhost.  It is not possible to just upload the binaries.  GD should be enabled already as with newer versions of php come bundled with it.  Write a phpinfo script and run it to see exactly how php is configured.
Code: [Select]
<?php
phpinfo
&#40;&#41;;
?>

Save this as info.php, upload it to your website and run it.  It's not a good idea to keep this around, so after you're done I recommend deleting it or moving it to a protected directory.

If you want more detailed information about how GD and ImageMagick work, check out www.imagemagick.org and www.boutell.com/gd/.  Bear in mind that GD does not have GIF support, so your users can't upload any GIFs.
Logged
Do not send me a private message unless I ask for one.  Make your post public so everyone can benefit.

There are no stupid questions
But there are a LOT of inquisitive idiots

moorey

  • VIP
  • Coppermine frequent poster
  • ***
  • Offline Offline
  • Posts: 404
Error executing ImageMagick - Return value: 127
« Reply #2 on: October 08, 2003, 05:57:20 am »

If it's precompiled binaries for the *right* system, it's possible. Individual users who has shell access and to the dev tools can compile their own, given the space and the right tools - root isn't required.  As for GD, although newer versions of PHP do have GD bundled, it still has to be configured into it; it's not on by default :cry:

What system/OS is the host running?  Did you get the right binaries of IM for it?  And yes, do the php_info() and switch on debug mode.
Logged

TheWiz01

  • Coppermine newbie
  • Offline Offline
  • Posts: 6
    • http://www.czgames.com
Info.php
« Reply #3 on: October 08, 2003, 08:46:37 am »

Quote
kegobeer  

Warning: Unexpected character in input: '\' (ASCII=92) state=1 in /home/czgames/public_html/info.php on line 2

Parse error: parse error in /home/czgames/public_html/info.php on line 2


This is what I received with doing INFO.PHP

Hope this helps


Quote
moorey
If it's precompiled binaries for the *right* system, it's possible. Individual users who has shell access and to the dev tools can compile their own, given the space and the right tools - root isn't required. As for GD, although newer versions of PHP do have GD bundled, it still has to be configured into it; it's not on by default  

What system/OS is the host running? Did you get the right binaries of IM for it? And yes, do the php_info() and switch on debug mode.


I guesss I need to know the the binaries. I do not have root access to setup the files in question.

Here is the server setup

General server information:
Operating system Linux
Service Status Click to View
Kernel version 2.4.20-20.7
Apache version 1.3.28 (Unix)
PERL version 5.6.1
Path to PERL /usr/bin/perl
Path to sendmail /usr/sbin/sendmail
Installed Perl Modules Click to View
PHP version 4.3.2
MySQL version 4.0.15-standard
cPanel Build 8.4.0-STABLE 92
Theme cPanel X v2.2.4  
Documentation Click to View
Logged

moorey

  • VIP
  • Coppermine frequent poster
  • ***
  • Offline Offline
  • Posts: 404
Re: Info.php
« Reply #4 on: October 08, 2003, 09:58:53 am »

Quote from: "TheWiz01"
Quote
kegobeer  

Warning: Unexpected character in input: '\' (ASCII=92) state=1 in /home/czgames/public_html/info.php on line 2

Parse error: parse error in /home/czgames/public_html/info.php on line 2


This is what I received with doing INFO.PHP


 :?:  There's only about a dozens of letters to be copied off KB here, how come there's a '\' in your info.php?

Quote from: "TheWiz01"

I guesss I need to know the the binaries. I do not have root access to setup the files in question.

Here is the server setup

General server information:
Operating system Linux
Service Status Click to View
Kernel version 2.4.20-20.7
Apache version 1.3.28 (Unix)
PERL version 5.6.1
Path to PERL /usr/bin/perl
Path to sendmail /usr/sbin/sendmail
Installed Perl Modules Click to View
PHP version 4.3.2
MySQL version 4.0.15-standard
cPanel Build 8.4.0-STABLE 92
Theme cPanel X v2.2.4  
Documentation Click to View


As I've said, you do not need root to install it.  Go to imagemagick.org and look for the binaries for linux if you don't want to compile it. Either way, no root is required.
Logged

TheWiz01

  • Coppermine newbie
  • Offline Offline
  • Posts: 6
    • http://www.czgames.com
Gertting Closer???
« Reply #5 on: October 08, 2003, 10:38:33 am »

Quote
moorey
 There's only about a dozens of letters to be copied off KB here, how come there's a '\' in your info.php?


i copied exactly what you asked and put the file in my root directory on my webserver directory and pulled this info when requesting it through my browser.

Quote
moorey

As I've said, you do not need root to install it. Go to imagemagick.org and look for the binaries for linux if you don't want to compile it. Either way, no root is required


I understand that i do not need root to do this either.i need advice of what type of directory and files I need to upload to my webserver. i think I can figure out how to link the directories to the other program, COPPERMINE.

Their instructions are very confusing...

I have looked at the linux binaries. there are many different zip files for linux solutions and for Unix

I know I have to upload a set of files in a directory but that is what i am looking for advice.

After they are uploaded I just need to know which file the program is looking for.  Coppermine as for the file directory but are they actually looking for the file.

I understand I am misunderstanding 2 sets of instructions but I am looking for advice as to how to combine them into one.  

Coppermine asks for the directory path and I think I can handle this answer if necessary. ***wink,wink***

The big questions i have is what directory or files I need to upload to my webserver and which directory or file i need to direct COPPERMINE too...
Logged

moorey

  • VIP
  • Coppermine frequent poster
  • ***
  • Offline Offline
  • Posts: 404
Error executing ImageMagick - Return value: 127
« Reply #6 on: October 09, 2003, 05:17:03 am »

Quote
ftp> pwd
257 "/pub/ImageMagick/binaries"
ftp> ls
227 Entering Passive Mode (66,192,180,107,66,166)
150 Here comes the directory listing.
-rw-r--r--    1 20       20        6309669 Aug 18 22:29 ImageMagick-5.5.7-Q16-windows-dll.exe
-rw-r--r--    1 20       20       19722720 Aug 18 22:37 ImageMagick-5.5.7-Q16-windows-static.exe
-rw-r--r--    1 20       20        6304217 Aug 18 22:39 ImageMagick-5.5.7-Q8-windows-dll.exe
-rw-r--r--    1 20       20       19682965 Aug 18 22:47 ImageMagick-5.5.7-Q8-windows-static.exe
-rw-rw-r--    1 20       20       13338230 Oct 07 20:22 ImageMagick-alphaev6-unknown-linux-gnu.tar.gz
-rw-rw-r--    1 20       20        5234514 Oct 07 22:10 ImageMagick-i386-unknown-freebsd4.6.tar.gz
-rw-r--r--    1 20       20        6305895 Oct 07 21:56 ImageMagick-i686-pc-cygwin.tar.gz
-rw-rw-r--    1 20       20        7601335 Oct 07 19:31 ImageMagick-i686-pc-linux-gnu.tar.gz
-rw-r--r--    1 20       20        8111571 Oct 07 19:32 ImageMagick-powerpc-apple-darwin6.8.tar.gz
-rw-rw-r--    1 20       20        5157633 May 23 17:59 ImageMagick-powerpc-apple-macos9.2.sit
-rw-r--r--    1 20       20        3157413 Oct 07 20:36 ImageMagick-sparc-sun-solaris2.8.tar.gz
-rw-r--r--    1 20       20        2458552 Oct 07 20:36 ImageMagick-sparc-sun-solaris2.9.tar.gz
226 Directory send OK.
ftp>


Am pretty sure the one you need is this one: ImageMagick-i686-pc-linux-gnu.tar.gz

Question is, do you have shell access? Can you telnet or ssh to the server or just plain ftp?

The steps are rather different - easier if you shell access though.
Logged

TheWiz01

  • Coppermine newbie
  • Offline Offline
  • Posts: 6
    • http://www.czgames.com
Just FTP Access
« Reply #7 on: October 09, 2003, 05:30:24 am »

Do you require shell access to load ImageMagick?  If you do I am screwed. I just have FTP access.

I don't have the most responsive webhosting company either.
Logged

moorey

  • VIP
  • Coppermine frequent poster
  • ***
  • Offline Offline
  • Posts: 404
Re: Just FTP Access
« Reply #8 on: October 09, 2003, 05:45:25 am »

Quote from: "TheWiz01"
Do you require shell access to load ImageMagick?  If you do I am screwed. I just have FTP access.

I don't have the most responsive webhosting company either.


Nope, it'll just make your life easier basically. So, on to the steps assuming you're on Windows, find your fav program to untar and gunzip the files (ie WinRAR). I'm using a Mac so I'll assume a lot of the steps.

1- Download ftp://ftp.imagemagick.org/pub/ImageMagick/binaries/ImageMagick-i686-pc-linux-gnu.tar.gz

2. Use your unzip program to extract to a folder on your desktop.

3. FTP all the contents to your home directory.

4. Search for the path to the "convert" utility and remember that. CHMOD the file to 755

5. Use that path for CPG's setting's ("path to the convert utility"). ie /home/czgames/imagemagick/bin/

If all still fails, I suggest you do the php_info() and get that working. Give us some output or a link to it.

Try it again.
HTH
Logged

TheWiz01

  • Coppermine newbie
  • Offline Offline
  • Posts: 6
    • http://www.czgames.com
Error executing ImageMagick - Return value: 127
« Reply #9 on: October 09, 2003, 06:27:41 am »

Moorey,

You are getting me so close I can taste it.

New error

Error executing ImageMagick - Return value: 127


Cmd line :
/home/czgames//public_html/ImageMagic/bin/convert -quality 80 -antialias -geometry 100x75 'albums/jamesandallenbday/MVC-001F.JPG' 'albums/jamesandallenbday/thumb_MVC-001F.JPG'



The convert program said:
/home/czgames//public_html/ImageMagic/bin/convert: error while loading shared libraries: libMagick.so.6: cannot open shared object file: No such file or directory


I found this file in the lib directory I tried to CHMOD with 755 and 777 to see if it would work.  No luck.....

Does it have to be moved to another directory??

Please, just a liitle guidance on PHP() INFO.  I do follow instructions very well...
Logged

moorey

  • VIP
  • Coppermine frequent poster
  • ***
  • Offline Offline
  • Posts: 404
Error executing ImageMagick - Return value: 127
« Reply #10 on: October 09, 2003, 07:47:51 am »

Hmm curious.  Can you verify that the host is running an x86 machine?  Like an Intel or something?

If it is, try making a copy of libMagick.so.6 to /home/czgames/public_html/ImageMagic/bin/

If it's not, find out the exact OS and system. IMO though, that error is not exactly a good sign - you may be required to compile your own (or ask your host to give you shell access or compile for you) or you could try the alphaev6-unknown version (doubtful).

As for phpinfo, create a new plain text file called php_info.php
Type exactly this in the file:
Quote
<?php
phpinfo();
?>


Upload it in ASCII mode to your public_html folder. Then view it through the browser.
Logged

TheWiz01

  • Coppermine newbie
  • Offline Offline
  • Posts: 6
    • http://www.czgames.com
Error executing ImageMagick - Return value: 127
« Reply #11 on: October 09, 2003, 08:25:21 am »

I posted this before about the server info in CPANEL

Quote
TheWiz01 wrote:

I guesss I need to know the the binaries. I do not have root access to setup the files in question.

Here is the server setup

General server information:
Operating system Linux
Service Status Click to View
Kernel version 2.4.20-20.7
Apache version 1.3.28 (Unix)
PERL version 5.6.1
Path to PERL /usr/bin/perl
Path to sendmail /usr/sbin/sendmail
Installed Perl Modules Click to View
PHP version 4.3.2
MySQL version 4.0.15-standard
cPanel Build 8.4.0-STABLE 92
Theme cPanel X v2.2.4
Documentation Click to View


I did learn something and that the server is running GD 2 on it.  Not to change from IMAGEMAGICK but I tried to select this because GD 1 or 2 would not work.  I would get a message stating that GD is not on the server. I know it is.  Setting up IMAGEMAGICK asks for the path of the file but GD does not.  What default path does it use and can I change it???

Quote
Moorey
If it is, try making a copy of libMagick.so.6 to /home/czgames/public_html/ImageMagic/bin/

I tried copying it here and also in a file called share.  I changed the CHMOD to 755 for all files copied, they default to 644.  Still getting the error message

I am trying the other flavors for linux and seeing if there is any other items I am overlooking....

Any ideas on the GD?
Logged

moorey

  • VIP
  • Coppermine frequent poster
  • ***
  • Offline Offline
  • Posts: 404
Error executing ImageMagick - Return value: 127
« Reply #12 on: October 09, 2003, 10:09:34 am »

I know you did post it before, but from the info does not show what distro of linux it is. There are heaps of linux distros out there, for different platforms (x86, xbox, PDA, sun, ibm etc etc). The binaries are different for each of these platforms.

If your host has GD installed (any later versions), you don't have to specify the path to it. CPG will autodetect it as GD is installed as an extension (lack of a better description) to PHP.

Get phpinfo() going and you'd most likely have to settle this with your host.
Logged

spurblade

  • Coppermine newbie
  • Offline Offline
  • Posts: 3
Re: Error executing ImageMagick - Return value: 127
« Reply #13 on: November 05, 2004, 11:16:20 am »

Read several posting regarding this, but can't find the right answer. Maybe somebody can help me on this


USER:
------------------
Array
(
    [ID] => 8b94f0999786f54c7be48e8c03c2aaad
    [am] => 1
)

==========================
USER DATA:
------------------
Array
(
    [user_id] => 1
    [user_group] => 1
    [user_active] => YES
    [user_name] => spurblade2002
    [user_password] => eric4175
    [user_lastvisit] => 2004-11-05 13:40:15
    [user_regdate] => 2004-11-05 11:35:53
    [user_group_list] =>
    [user_email] =>
    [user_website] =>
    [user_location] =>
    [user_interests] =>
    [user_occupation] =>
    [user_actkey] =>
    [disk_max] => 2048
    [disk_min] => 2048
    [can_rate_pictures] => 1
    [can_send_ecards] => 1
    [ufc_max] => 0
    [ufc_min] => 0
    [custom_user_upload] => 1
    [num_file_upload] => 5
    [num_URI_upload] => 3
    [can_post_comments] => 1
    [can_upload_pictures] => 1
    [can_create_albums] => 1
    [has_admin_access] => 1
    [pub_upl_need_approval] => 0
    [priv_upl_need_approval] => 0
    [group_name] => Administrators
    [upload_form_config] => 0
    [group_quota] => 2048
    [can_see_all_albums] => 1
    [group_id] => 1
    [groups] => Array
        (
            [1] => 1
        )

)

==========================
Queries:
------------------
Array
(
   
  • => SELECT extension, mime, content FROM cpg123_filetypes;
  • [1] => SELECT * FROM cpg123_users WHERE user_id='1'AND user_active = 'YES' AND user_password != '' AND BINARY MD5(user_password) = '65bda084492d58d7280a4129a5febd5a'
        [2] => SELECT MAX(group_quota) as disk_max, MIN(group_quota) as disk_min, MAX(can_rate_pictures) as can_rate_pictures, MAX(can_send_ecards) as can_send_ecards, MAX(upload_form_config) as ufc_max, MIN(upload_form_config) as ufc_min, MAX(custom_user_upload) as custom_user_upload, MAX(num_file_upload) as num_file_upload, MAX(num_URI_upload) as num_URI_upload, MAX(can_post_comments) as can_post_comments, MAX(can_upload_pictures) as can_upload_pictures, MAX(can_create_albums) as can_create_albums, MAX(has_admin_access) as has_admin_access, MIN(pub_upl_need_approval) as pub_upl_need_approval, MIN( priv_upl_need_approval) as  priv_upl_need_approval FROM cpg123_usergroups WHERE group_id in (1)
        [3] => SELECT group_name FROM  cpg123_usergroups WHERE group_id= 1
        [4] => DELETE FROM cpg123_banned WHERE expiry < 1099647756
        [5] => SELECT * FROM cpg123_banned WHERE ip_addr='202.138.136.130' OR ip_addr='202.138.136.130' OR user_id=1
        [6] => SELECT category FROM cpg123_albums WHERE aid='2'
    )

    ==========================
    GET :
    ------------------
    Array
    (
    )

    ==========================
    POST :
    ------------------
    Array
    (
       
[album] => 2
    [MAX_FILE_SIZE] => 1048576
    [title] =>
    [caption] =>
    [keywords] =>
    [event] => picture
)

==========================
VERSION INFO :
------------------
PHP version: 4.3.9 - OK
------------------
mySQL version: 4.0.22-standard
------------------
Coppermine version: 1.3.2
==========================
Module: gd
------------------
module doesn't exist
==========================
Module: mysql
------------------
Active Persistent Links 0
Active Links 1
Client API version 4.0.22
MYSQL_MODULE_TYPE external
MYSQL_SOCKET /var/lib/mysql/mysql.sock
MYSQL_INCLUDE -I/usr/include/mysql
MYSQL_LIBS -L/usr/lib -lmysqlclient 
==========================
Module: zlib
------------------
ZLib Support enabled
Compiled Version 1.1.4
Linked Version 1.1.4
==========================
Server restrictions (safe mode)?
------------------
Directive | Local Value | Master Value
safe_mode | On | On
safe_mode_exec_dir | no value | no value
safe_mode_gid | Off | Off
safe_mode_include_dir | no value | no value
safe_mode_exec_dir | no value | no value
sql.safe_mode | Off | Off
disable_functions | shell_exec, shell_exec, system | shell_exec, shell_exec, system
file_uploads | On | On
include_path | .:/usr/lib/php:/usr/local/lib/php | .:/usr/lib/php:/usr/local/lib/php
open_basedir | /home/eric1/:/usr/lib/php:/usr/local/lib/php:/tmp | no value
==========================
email
------------------
Directive | Local Value | Master Value
sendmail_from | no value | no value
sendmail_path | /usr/sbin/sendmail  -t -i | /usr/sbin/sendmail  -t -i
SMTP | localhost | localhost
smtp_port | 25 | 25
==========================
Size and Time
------------------
Directive | Local Value | Master Value
max_execution_time | 120 | 120
max_input_time | -1 | -1
upload_max_filesize | 2M | 2M
post_max_size | 55M | 55M
==========================
Page generated in 0.67 seconds - 7 queries in 0.136 seconds - Album set :
Logged

Joachim Müller

  • Dev Team member
  • Coppermine addict
  • ****
  • Offline Offline
  • Gender: Male
  • Posts: 47843
  • aka "GauGau"
    • gaugau.de
Logged
Pages: [1]   Go Up
 

Page created in 0.094 seconds with 18 queries.