Home » Centos/RHEL » How to install ImageMagick on RHEL/Centos Server

How to install ImageMagick on RHEL/Centos Server

ImageMagick is an free open source simple application tool for any kind of image management that is very useful for creating, editing, converting, displaying image files such as JPEG, GIF, PNG and Photo CD image formats and it is also used for thumbnail or captcha invention.

To install ImageMagick prerequisite php-pear and gcc

# yum install php-pear gcc

Note :: If you already installed then skip this.

#yum install ImageMagick ImageMagick-perl ImageMagick-devel
#pecl install imagick
running: make INSTALL_ROOT=”/var/tmp/pear-build-root8qADaX/install-imagick-3.1.2″ install
Installing shared extensions: /var/tmp/pear-build-root8qADaX/install-imagick-3.1.2/usr/lib64/php/modules/
Installing header files: /var/tmp/pear-build-root8qADaX/install-imagick-3.1.2/usr/include/php/
running: find “/var/tmp/pear-build-root8qADaX/install-imagick-3.1.2” | xargs ls -dils

Build process completed successfully
Installing ‘/usr/lib64/php/modules/imagick.so’
Installing ‘/usr/include/php/ext/imagick/php_imagick.h’
Installing ‘/usr/include/php/ext/imagick/php_imagick_defs.h’
Installing ‘/usr/include/php/ext/imagick/php_imagick_shared.h’
install ok: channel://pecl.php.net/imagick-3.1.2
configuration option “php_ini” is not set to php.ini location
You should add “extension=imagick.so” to php.ini

Now, add the ‘imagick.so‘ extension to ‘/etc/php.ini‘ file.

#echo extension=imagick.so >> /etc/php.ini
# service httpd restart
# php -m | grep imagick

Imagick installation on Ubuntu.

#apt-get install imagemagick
#apt-get install php5-imagick

That’s it.


I am founder and webmaster of www.linuxpcfix.com and working as a Sr. Linux Administrator (Expertise on Linux/Unix & Cloud Server) and have been in the industry from last 7 years.

Leave a Reply

Your email address will not be published. Required fields are marked *


Time limit is exhausted. Please reload the CAPTCHA.

Categorized Tag Cloud