Can't install Image::Magick perl module on WHM 11.36

Max Zmushko

Registered
Apr 10, 2013
2
0
1
cPanel Access Level
Root Administrator
Hello,
I'm moving from a shared hosting to a dedicated server and faced a trouble with ImageMagick. All of my scripts using Image::Magick perl module stoped working.
I was able to locate an error:
Code:
[Wed Apr 10 11:27:27 2013] [error] [client ......] Can't locate Image/Magick.pm in @INC (@INC contains: /usr/local/lib/perl5/5.8.8/x86_64-linux /usr/local/lib/perl5/5.8.8 /usr/local/lib/perl5/site_perl/5.8.8/x86_64-linux /usr/local/lib/perl5/site_perl/5.8.8 /usr/local/lib/perl5/site_perl .) at FileLoader.cgi line 13.
[Wed Apr 10 11:27:27 2013] [error] [client ......] BEGIN failed--compilation aborted at FileLoader.cgi line 13.
[Wed Apr 10 11:27:27 2013] [error] [client ......] Premature end of script headers: FileLoader.cgi
Following cPanel & WHM 11.36 Release Notes
I've installed ImageMagick and ImageMagick perl bindings yum packages

rpm -qa listing:
Code:
@cloud [~]# rpm -qa | grep ImageMagick
ImageMagick-c++-6.2.8.0-15.el5_8
ImageMagick-c++-6.2.8.0-15.el5_8
ImageMagick-6.2.8.0-15.el5_8
ImageMagick-c++-devel-6.2.8.0-15.el5_8
ImageMagick-devel-6.2.8.0-15.el5_8
ImageMagick-c++-devel-6.2.8.0-15.el5_8
ImageMagick-perl-6.2.8.0-15.el5_8
ImageMagick-6.2.8.0-15.el5_8
cpanel-ImageMagick-6.8.0-1.cp1136
ImageMagick-devel-6.2.8.0-15.el5_8
I've also tried to add lines to my scripts
Code:
#!/bin/sh                                                                                                                                                                                               
 eval 'if [ -x /usr/local/cpanel/3rdparty/bin/perl ]; then exec /usr/local/cpanel/3rdparty/bin/perl -x -- $0 ${1+"[email protected]"}; else exec /usr/bin/perl -x $0 ${1+"[email protected]"}; fi;'
   if 0;
#!/usr/bin/perl
But all this haven't solved the problem

Any help will be much apreciated
 

Phincy

Member
Feb 11, 2012
16
0
51
cPanel Access Level
Root Administrator
Hi Max,
it looks like the script is not checking the correct location for the file Magick.pm. Can you show me the output of the following command here.

--
rpm -ql ImageMagick-perl | grep Magick.pm
--


In my test server, the Magick.pm is located at "/usr/lib64/perl5/vendor_perl/Image/Magick.pm". It is an x86_64 server with cpanel 11.36.

I believe simply copying the Magick.pm as obtained from the command I mentioned above to any of the locations specified by @INC should so the job.

eg. /usr/local/lib/perl5/5.8.8/x86_64-linux

Hope this helps.
 
Last edited:

Max Zmushko

Registered
Apr 10, 2013
2
0
1
cPanel Access Level
Root Administrator
Hello Phincy,

Code:
rpm -ql ImageMagick-perl | grep Magick.pm 

/usr/lib64/perl5/vendor_perl/5.8.8/x86_64-linux-thread-multi/Image/Magick.pm
I have copied Image folder to /usr/local/lib/perl5/5.8.8/x86_64-linux/ and now I am getting new issue:

Code:
@cloud [~]# perl -we 'use Image::Magick; print "HI"'
Can't find 'boot_Image__Magick' symbol in /usr/lib64/libMagick.so
 at -e line 1.
Compilation failed in require at -e line 1.
BEGIN failed--compilation aborted at -e line 1.

[email protected] [~]# rpm -qf /usr/lib64/libMagick.so
ImageMagick-devel-6.2.8.0-15.el5_8
 

lldeepakll

Well-Known Member
May 20, 2012
85
3
58
India
cPanel Access Level
Root Administrator
Hi,

I am facing below error while installing "Image::Magick" using install a perl module option in whm (11.36).
----------------------------------------------------------------
Running install for module 'Image::Magick'

The module Image::Magick isn't available on CPAN.

Either the module has not yet been uploaded to CPAN, or it is
temporary unavailable. Please contact the author to find out
more about the status. Try 'i Image::Magick'.
----------------------------------------------------------------

Please suggest the exact way to install Image::Magick

Thanks