Ошибка Nextcloud: «Не установлен PHP-модуль GD»

Print Friendly, PDF & Email

Задача:

устранить ошибку «Не установлен PHP-модуль GD.»

---------------------------------------------------------------

После обновления php до версии 8.0 и системы до FreeBSD 13.0 появилась ошибка.

Смотрим что из нужного установлено

root@cloud:/usr/local/www/nextcloud # pkg info gd
pkg: No package(s) matching gd
root@cloud:/usr/local/www/nextcloud #

Смотрим что доступно для устаноки

root@cloud:/usr/local/www/nextcloud # pkg search gd | grep php
php73-gd-7.3.31                The gd shared extension for php
php74-gd-7.4.24                The gd shared extension for php
php80-gd-8.0.11                The gd shared extension for php
root@cloud:/usr/local/www/nextcloud #

Устанавливаем

root@cloud:/usr/local/www/nextcloud # pkg install php80-gd-8.0.11
Updating FreeBSD repository catalogue...
FreeBSD repository is up to date.
All repositories are up to date.
The following 5 package(s) will be affected (of 0 checked):

New packages to be INSTALLED:
        jpeg-turbo: 2.0.6
        libgd: 2.3.1,1
        php80-gd: 8.0.11
        tiff: 4.3.0
        webp: 1.2.0

Number of packages to be installed: 5

The process will require 9 MiB more space.
1 MiB to be downloaded.

Proceed with this action? [y/N]: y
[1/4] Fetching php80-gd-8.0.11.txz: 100%   32 KiB  32.6kB/s    00:01
[2/4] Fetching tiff-4.3.0.txz: 100%  846 KiB 866.5kB/s    00:01
[3/4] Fetching libgd-2.3.1,1.txz: 100%  202 KiB 207.1kB/s    00:01
[4/4] Fetching webp-1.2.0.txz: 100%  396 KiB 406.0kB/s    00:01
Checking integrity... done (2 conflicting)
  - jpeg-turbo-2.0.6 conflicts with mozjpeg-4.0.3 on /usr/local/bin/cjpeg
  - jpeg-turbo-2.0.6 conflicts with mozjpeg-4.0.3 on /usr/local/bin/cjpeg
Checking integrity... done (0 conflicting)
Conflicts with the existing packages have been found.
One more solver iteration is needed to resolve them.
The following 6 package(s) will be affected (of 0 checked):

Installed packages to be REMOVED:
        mozjpeg: 4.0.3

New packages to be INSTALLED:
        jpeg-turbo: 2.0.6
        libgd: 2.3.1,1
        php80-gd: 8.0.11
        tiff: 4.3.0
        webp: 1.2.0

Number of packages to be removed: 1
Number of packages to be installed: 5

The process will require 4 MiB more space.

Proceed with this action? [y/N]: y
[1/6] Deinstalling mozjpeg-4.0.3...
[1/6] Deleting files for mozjpeg-4.0.3: 100%
[2/6] Installing jpeg-turbo-2.0.6...
[2/6] Extracting jpeg-turbo-2.0.6: 100%
[3/6] Installing tiff-4.3.0...
[3/6] Extracting tiff-4.3.0: 100%
[4/6] Installing webp-1.2.0...
[4/6] Extracting webp-1.2.0: 100%
[5/6] Installing libgd-2.3.1,1...
[5/6] Extracting libgd-2.3.1,1: 100%
[6/6] Installing php80-gd-8.0.11...
[6/6] Extracting php80-gd-8.0.11: 100%
=====
Message from php80-gd-8.0.11:

--
This file has been added to automatically load the installed extension:
/usr/local/etc/php/ext-20-gd.ini
root@cloud:/usr/local/www/nextcloud #

Перезапускаем nginx и php-fpm

root@cloud:/usr/local/www/nextcloud # service nginx restart
Performing sanity check on nginx configuration:
nginx: the configuration file /usr/local/etc/nginx/nginx.conf syntax is ok
nginx: configuration file /usr/local/etc/nginx/nginx.conf test is successful
Stopping nginx.
Waiting for PIDS: 1163.
Performing sanity check on nginx configuration:
nginx: the configuration file /usr/local/etc/nginx/nginx.conf syntax is ok
nginx: configuration file /usr/local/etc/nginx/nginx.conf test is successful
Starting nginx.
root@cloud:/usr/local/www/nextcloud # service php-fpm restart
Performing sanity check on php-fpm configuration:
[03-Oct-2021 19:43:47] NOTICE: PHP message: PHP Warning:  Missing arginfo for MemcachedServer::run() in Unknown on line 0
[03-Oct-2021 19:43:47] NOTICE: PHP message: PHP Warning:  Missing arginfo for MemcachedServer::on() in Unknown on line 0
[03-Oct-2021 19:43:47] NOTICE: configuration file /usr/local/etc/php-fpm.conf test is successful

Stopping php_fpm.
Waiting for PIDS: 862.
Performing sanity check on php-fpm configuration:
[03-Oct-2021 19:43:47] NOTICE: PHP message: PHP Warning:  Missing arginfo for MemcachedServer::run() in Unknown on line 0
[03-Oct-2021 19:43:47] NOTICE: PHP message: PHP Warning:  Missing arginfo for MemcachedServer::on() in Unknown on line 0
[03-Oct-2021 19:43:47] NOTICE: configuration file /usr/local/etc/php-fpm.conf test is successful

Starting php_fpm.
[03-Oct-2021 19:43:47] NOTICE: PHP message: PHP Warning:  Missing arginfo for MemcachedServer::run() in Unknown on line 0
[03-Oct-2021 19:43:47] NOTICE: PHP message: PHP Warning:  Missing arginfo for MemcachedServer::on() in Unknown on line 0
root@cloud:/usr/local/www/nextcloud #

есть предупреждения, но это тема для нового поста. На данный момент работа nextcloud восстановлена

Помогла статья? Есть возможность отблагодарить автора

QR Link:

QR Code

Читайте также:

Добавить комментарий

Ваш адрес email не будет опубликован. Обязательные поля помечены *