Installing Opcache in Ubuntu 20.04 for Apache and Nginx
The guide below describes how to install Opcache on Ubuntu 20.04 with Apache or Nginx web server installed
We will do everything with the console in a few seconds.
We log into the console and release packages:
Sinstallation method for Apache
1 | apt-get update |
The next step is to install Opcache:
1 | apt-get install php-opcache -y |
The guide below describes how to install Opcache on Ubuntu
edit file
1 | nano /etc/php/7.4/apache2/php.ini |
and add at the end
1 2 3 4 | opcache.enable=1 opcache.memory_consumption=128 opcache.max_accelerated_files=3000 opcache.revalidate_freq=200 |
We are reloading the Apache server
1 | systemctl restart apache2 |
How to install Nginx
We update the repository
1 | apt-get update |
We install the opcache package
1 | apt-get install php-opcache php-fpm -y |
We're editing php.ini
1 | nano /etc/php/7.4/fpm/php.ini |
We add at the end:
1 2 3 4 | opcache.enable=1 opcache.memory_consumption=128 opcache.max_accelerated_files=3000 opcache.revalidate_freq=200 |
We restart the service:
1 | systemctl restart nginx |
1 | systemctl restart php7.4-fpm |
Related entries:
Changing the time zone Debian systems, Ubuntu Centos
Conversion Magento admin password from the database
Applies a transparent background
Disabling package updates from Yum in Centos and AlmaLinux
LibreOffice is a powerful office suite and the successor to OpenOffice 5.24 sudo apt install kubuntu-desktop 21.10