Disclaimer: This guide was automatically translated by AI from the German original. Please verify commands and technical details before using them.
Back to overview: Debian guides
Install the APCu cache:
apt install php-apcu
Edit Nextcloud's config.php:
nano /var/www/html/nextcloud/config/config.php
Add the following line:
'memcache.local' => '\OC\Memcache\APCu',
Open the PHP configuration file:
nano /etc/php/7.4/apache2/php.ini
Add the following lines:
opcache.enable=1
opcache.enable_cli=1
opcache.interned_strings_buffer=8
opcache.max_accelerated_files=10000
opcache.memory_consumption=128
opcache.save_comments=1
opcache.revalidate_freq=1
Restart Apache:
/etc/init.d/apache2 restart
Change the memory_limit setting in the PHP configuration:
nano /etc/php/7.4/apache2/php.ini
Search for memory_limit and change the value from 128M to 512M:
memory_limit = 512M
Restart Apache:
/etc/init.d/apache2 restart
Install the Imagick module for PHP:
sudo apt install php-imagick
If you need uploads of files larger than 1 GB, change the Apache configuration:
Edit the files 000-default.conf and default-ssl.conf under /etc/apache2/sites-available and add the following line before </VirtualHost>:
LimitRequestBody 0
Install the missing PHP modules:
apt install php7.4-bcmath php7.4-gmp -y
Add missing columns in the database:
sudo -u www-data php occ db:add-missing-columns
sudo -u www-data php occ db:add-missing-indices
Install the required package for SVG support:
apt install libmagickcore-6.q16-6-extra
Add the line for default_phone_region:
'default_phone_region' => 'DE',
Restart Apache:
systemctl restart apache2