How To Install php-pecl-apcu on CentOS 7
Introduction
In this tutorial we learn how to install php-pecl-apcu
on CentOS 7.
What is php-pecl-apcu
APCu is userland caching preparation for the deployment of Zend OPcache as the primary solution to opcode caching in future versions of PHP. APCu has a revised and simplified codebase, by the time the PECL release is available, every part of APCu being used will have received review and where necessary or appropriate, changes. Simplifying and documenting the API of APCu completely removes the barrier to maintenance and development of APCu in the future, and additionally allows us to make optimizations not possible previously because of APC’s inherent complexity. APCu only supports userland caching (and dumping) of variables, providing an upgrade path for the future. When O+ takes over, many will be tempted to use 3rd party solutions to userland caching, possibly even distributed solutions; this would be a grave error. The tried and tested APC codebase provides far superior support for local storage of PHP variables.
We can use yum
or dnf
to install php-pecl-apcu
on CentOS 7. In this tutorial we discuss both methods but you only need to choose one of method to install php-pecl-apcu.
Install php-pecl-apcu on CentOS 7 Using yum
Update yum database with yum
using the following command.
sudo yum makecache
After updating yum database, We can install php-pecl-apcu
using yum
by running the following command:
sudo yum -y install php-pecl-apcu
Install php-pecl-apcu on CentOS 7 Using dnf
If you don’t have dnf installed you can install DNF on CentOS 7 first.
Update yum database with dnf
using the following command.
sudo dnf makecache
After updating yum database, We can install php-pecl-apcu
using dnf
by running the following command:
sudo dnf -y install php-pecl-apcu
How To Uninstall php-pecl-apcu on CentOS 7
To uninstall only the php-pecl-apcu
package we can use the following command:
sudo dnf remove php-pecl-apcu
References
Summary
In this tutorial we learn how to install php-pecl-apcu
on CentOS 7 using yum
and dnf
.