Need help?

Our experts have had an average response time of 12.14 minutes in September 2021 to fix urgent issues.

We will keep your servers stable, secure, and fast at all times for one fixed price.

Imagick php install – How to install the extension easily

by | Feb 7, 2021

Looking forward to Imagick php install? We can help you.

We can use Imagick to create and modify images using the ImageMagick library. It is the most popular PHP extension.

Here, at Bobcares, as part of our Server Management Services, we assist our customers with several PHP queries.

Today, let’s get into the details on how our Support Engineers help in the installation of Imagick.

 

What is Imagick

Imagick is the popular PHP extension used for helping ImageMagick software.

Here, ImageMagick is the software to create edit convert, and/or manipulate images with the help of Imagick PHP extension.

We can use ImageMagick without Imagick. However, we need both Imagick and ImageMagick installed to run it within the PHP code.

Now let’s see how our Support Engineers install Imagick.

 

Imagick php install

At Bobcares, with more than a decade of expertise in managing servers, we see many customers requesting to install Imagick.

Now, let’s see how our Support Engineers help them with the installation of Imagick.

  1. Initially, we login to the server and then run the following command.
    apt-get install php-imagick
  2. To verify the Imagick extension we run:
    php -m | grep imagick
  3. Finally, we restart the Apache service. Otherwise, we won’t be able to use the Imagick class in users’ PHP code. We use the following command to restart the Apache service:
    service apache2 restart

Once we finish the installation, we add an info page to verify the Imagick PHP extension.

For instance, the PHP page with Imagick extension appears as follows.

Imagick php install

Thus, we installed the Imagick successfully.

 

Common installation errors

Now that we have seen how the installation works, our Support Techs gives an insight into a few common errors it might cause.

  • ERROR: `/tmp/pear/temp/imagick/configure –with-imagick’ failed

Some of our customers came across this error while trying to install Imagick using the command:

pecl install imagick
...

checking ImageMagick MagickWand API configuration program... found in /usr/bin/Wand-config checking if ImageMagick version is at least 6.2.4... configure: error: no. You need at least Imagemagick version 6.2.4 to use Imagick. ERROR: `/tmp/pear/temp/imagick/configure --with-imagick' failed

It was found that using “pecl install imagick-beta, also sometimes result in the same error.

In order to resolve this, we follow the below steps:

  1. Initially, we remove the imagemagick if it is already present.
    apt-get remove graphicsmagick-libmagick-dev-compat imagemagick imagemagick-common
    apt-get autoremove
  2. Then we install libmagickwand-dev:
    apt-get install libmagickwand-dev
  3. Finally, install Imagick via pecl:
    pecl install imagick-beta
  • Error: cannot download “pecl/imagick”

While installing the Imagick module in whm, one of our customers came across the following error:

downloading imagick-3.0.1.tgz ...
Starting to download imagick-3.0.1.tgz (Unknown size)
....done: 3,582 bytes
Could not get contents of package "/root/tmp/pear/cache/imagick-3.0.1.tgz". Invalid tgz file.
Download of "pecl/imagick" succeeded, but it is not a valid package archive
Error: cannot download "pecl/imagick"
Download failed
install failed
The imagick.so object is not in /usr/local/lib/php/extensions/no-debug-non-zts-20090626

This may mostly be due to http://pecl.php.net being down. Hence, as an alternative, install it as follows:

apt-get install php-imagick
php -m | grep imagick
service apache2 restart

[Need assistance with the installation? – We can you.]

 

Conclusion

In short, Imagick is the most popular PHP extension which helps to create edit convert, and/or manipulates images. Today, we saw how our Support Engineers help the customer in installing the Imagick PHP extension.

PREVENT YOUR SERVER FROM CRASHING!

Never again lose customers to poor server speed! Let us help you.

Our server experts will monitor & maintain your server 24/7 so that it remains lightning fast and secure.

GET STARTED

var google_conversion_label = "owonCMyG5nEQ0aD71QM";

0 Comments

Submit a Comment

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

Privacy Preference Center

Necessary

Necessary cookies help make a website usable by enabling basic functions like page navigation and access to secure areas of the website. The website cannot function properly without these cookies.

PHPSESSID - Preserves user session state across page requests.

gdpr[consent_types] - Used to store user consents.

gdpr[allowed_cookies] - Used to store user allowed cookies.

PHPSESSID, gdpr[consent_types], gdpr[allowed_cookies]
PHPSESSID
WHMCSpKDlPzh2chML

Statistics

Statistic cookies help website owners to understand how visitors interact with websites by collecting and reporting information anonymously.

_ga - Preserves user session state across page requests.

_gat - Used by Google Analytics to throttle request rate

_gid - Registers a unique ID that is used to generate statistical data on how you use the website.

smartlookCookie - Used to collect user device and location information of the site visitors to improve the websites User Experience.

_ga, _gat, _gid
_ga, _gat, _gid
smartlookCookie

Marketing

Marketing cookies are used to track visitors across websites. The intention is to display ads that are relevant and engaging for the individual user and thereby more valuable for publishers and third party advertisers.

IDE - Used by Google DoubleClick to register and report the website user's actions after viewing or clicking one of the advertiser's ads with the purpose of measuring the efficacy of an ad and to present targeted ads to the user.

test_cookie - Used to check if the user's browser supports cookies.

1P_JAR - Google cookie. These cookies are used to collect website statistics and track conversion rates.

NID - Registers a unique ID that identifies a returning user's device. The ID is used for serving ads that are most relevant to the user.

DV - Google ad personalisation

IDE, test_cookie, 1P_JAR, NID, DV, NID
IDE, test_cookie
1P_JAR, NID, DV
NID
hblid

Security

These are essential site cookies, used by the google reCAPTCHA. These cookies use an unique identifier to verify if a visitor is human or a bot.

SID, APISID, HSID, NID, PREF
SID, APISID, HSID, NID, PREF