Friday, July 4, 2014

Install Imagick on Linux

Install Imagick on CentOS, fedora or RHEL
If you are using XAMPP, Run
sudo /opt/lampp/bin/pecl install imagick
If you get any error related to /tmp/pear, it means development packages are not installed in your xampp. Download and install latest version of xampp. It comes with devel packages or find and install devel packages of your version of xampp.

If you have installed httpd/mysqld on CentOS, fedora or RHEL, Run
sudo pecl install imagick
Click here and here to resolve error.

If it installs successfully, add line 
extension=imagick.so
in the file php.ini
Restart apache. 

Install Imagick on Ubuntu or Debian
If you are using XAMPP, Run
sudo /opt/lampp/bin/pecl install imagick
If you get any error related to /tmp/pear, it means development packages are not installed in your xampp. Download and install latest version of xampp. It comes with devel packages or find and install devel packages of your version of xampp.
If you have installed apache2/mysql on Ubuntu or Debian, Run
sudo pecl install imagick
Click here and here to resolve error.

If it installs successfully, add line 
extension=imagick.so
in the file php.ini
Restart apache.

PHP Warning: PHP Startup: Unable to load dynamic library '/usr/lib64/php/modules/imagick.so' - liblcms2.so.2: cannot open shared object file: No such file or directory in Unknown on line 0

Not able to install imagick on CentOS, fedora or RHEL
liblcms2.so.2: cannot open shared object file

Install following packages in RHEL, fedora or CentOS
yum install lcms2

mysql Error : Missing system table mysql.proxies_priv

To remove the error, run following command
sudo mysql_upgrade -u root -p
If your system does not identify mysql_upgrade, you can try these two commands.
mysqlcheck --no-defaults --check-upgrade --all-databases --auto-repair
mysql < fix_priv_tables