Etwas maskiert/entfernt PHP7.4-FPM

Etwas maskiert/entfernt PHP7.4-FPM

Ich verwende LAMP mit php7.4-fpm auf dem Ubuntu-Server 20.04.

Ich habe gerade das neuste Update/Upgrade durchgeführt und bestätigt, dass alles richtig funktioniert:

● php7.4-fpm.service - The PHP 7.4 FastCGI Process Manager
     Loaded: loaded (/lib/systemd/system/php7.4-fpm.service; enabled; vendor preset: enabled)
     Active: active (running) since Fri 2022-08-26 00:50:45 CST; 7min ago
       Docs: man:php-fpm7.4(8)
   Main PID: 120871 (php-fpm7.4)
     Status: "Processes active: 0, idle: 2, Requests: 24, slow: 0, Traffic: 0.1req/sec"
      Tasks: 3 (limit: 4380)
     Memory: 80.8M
     CGroup: /system.slice/php7.4-fpm.service
             ├─120871 php-fpm: master process (/etc/php/7.4/fpm/php-fpm.conf)
             ├─120892 php-fpm: pool www
             └─120893 php-fpm: pool www

Dann, mehrere Minuten später ... stoppt meine Nextcloud-Installation plötzlich die Synchronisierung, also überprüfe ich den Status von php-fpm erneut und erhalte:

● php7.4-fpm.service
     Loaded: masked (Reason: Unit php7.4-fpm.service is masked.)
     Active: inactive (dead) since Fri 2022-08-26 01:07:14 CST; 5min ago
   Main PID: 120871 (code=exited, status=0/SUCCESS)
     Status: "Processes active: 0, idle: 2, Requests: 44, slow: 0, Traffic: 0req/sec"

Aug 26 01:07:14 admin.example.com systemd[1]: Stopping The PHP 7.4 FastCGI Process Manager...
Aug 26 01:07:14 admin.example.com systemd[1]: php7.4-fpm.service: Succeeded.
Aug 26 01:07:14 admin.example.com systemd[1]: Stopped The PHP 7.4 FastCGI Process Manager.
Warning: journal has been rotated since unit was started, output may be incomplete.`

Und existiert buchstäblich /lib/systemd/system/php7.4-fpm.servicenicht mehr

# stat /lib/systemd/system/php7.4-fpm.service
stat: cannot stat '/lib/systemd/system/php7.4-fpm.service': No such file or directory

Ich habe überprüft syslog, was passiert ist, als der Dienst laut Zeitstempel maskiert wurde … und im Protokoll steht einfach nichts, was erklärt, was passiert ist:

Aug 26 01:07:14 admin systemd[1]: Stopped The PHP 7.4 FastCGI Process Manager.
Aug 26 01:07:14 admin systemd[1]: php7.4-fpm.service: Succeeded.
Aug 26 01:07:14 admin systemd[1]: Stopping The PHP 7.4 FastCGI Process Manager...
Aug 26 01:07:14 admin systemd[1]: Configuration file /etc/systemd/system/gitea.service is marked world-inaccessible. This has no effect as configuration data is accessible via APIs without restrictions. Proceeding anyway.
Aug 26 01:07:14 admin systemd[1]: Reloading.
Aug 26 01:07:14 admin php7.4-fpm: php_invoke prerm: Disabled module readline for PHP 7.4 fpm sapi
Aug 26 01:07:14 admin php7.4-fpm: php_invoke prerm: Disabled module pspell for PHP 7.4 fpm sapi
Aug 26 01:07:14 admin php7.4-fpm: php_invoke prerm: Disabled module ctype for PHP 7.4 fpm sapi
Aug 26 01:07:14 admin php7.4-fpm: php_invoke prerm: Disabled module redis for PHP 7.4 fpm sapi
Aug 26 01:07:14 admin php7.4-fpm: php_invoke prerm: Disabled module dom for PHP 7.4 fpm sapi
Aug 26 01:07:14 admin php7.4-fpm: php_invoke prerm: Disabled module soap for PHP 7.4 fpm sapi
Aug 26 01:07:14 admin php7.4-fpm: php_invoke prerm: Disabled module iconv for PHP 7.4 fpm sapi
Aug 26 01:07:14 admin php7.4-fpm: php_invoke prerm: Disabled module apcu_bc for PHP 7.4 fpm sapi
Aug 26 01:07:14 admin php7.4-fpm: php_invoke prerm: Disabled module phar for PHP 7.4 fpm sapi
Aug 26 01:07:14 admin php7.4-fpm: php_invoke prerm: Disabled module mysqlnd for PHP 7.4 fpm sapi
Aug 26 01:07:14 admin php7.4-fpm: php_invoke prerm: Disabled module imap for PHP 7.4 fpm sapi
Aug 26 01:07:14 admin php7.4-fpm: php_invoke prerm: Disabled module xsl for PHP 7.4 fpm sapi
Aug 26 01:07:14 admin php7.4-fpm: php_invoke prerm: Disabled module sysvshm for PHP 7.4 fpm sapi

Aktualisieren: Wenn ich versuche, php7.4-fpm mit zu demaskieren systemctl unmask php7.4-fpm, passieren zwei Dinge:

  1. /etc/systemd/system/php7.4-fpm.servicewird entfernt. /etc/systemd/system/php7.4-fpm.serviceist ein symbolischer Link zu /dev/null

  2. php7.4-fpm.service wird gestartet mitinit.d

● php7.4-fpm.service - LSB: starts php7.4-fpm
     Loaded: loaded (/etc/init.d/php7.4-fpm; generated)
     Active: active (exited) since Fri 2022-08-26 09:09:10 CST; 6min ago
       Docs: man:systemd-sysv-generator(8)
      Tasks: 0 (limit: 4380)
     Memory: 0B
     CGroup: /system.slice/php7.4-fpm.service

Wenn ich versuche, php7.4fpm neu zu installieren, apt-get install --reinstall php7.4-fpmerhalte ich:

root@admin:~# apt-get install --reinstall php7.4-fpm
Reading package lists... Done
Building dependency tree       
Reading state information... Done
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:

The following packages have unmet dependencies:
 php7.4-fpm : Depends: php7.4-common (= 7.4.3-4ubuntu2.12) but 7.4.3-4ubuntu2.13 is to be installed
E: Unable to correct problems, you have held broken packages.

Alle oben genannten Schritte basieren auf diesem Beitrag: https://askubuntu.com/questions/804946/systemctl-how-to-unmask

Ich hänge derzeit mit defekten Paketen fest

Ja, ich habe versucht:
apt install -f
dpkg --configure -a

Nichts hilft..

Antwort1

Bei diesem Problem scheint es sich grundsätzlich um ein Verpackungsproblem mit den Upstream-Ubuntu-Repos zu handeln, für dessen Behebung die Betreuer wahrscheinlich einige Zeit benötigen.

The following packages have unmet dependencies:
 php7.4-fpm : Depends: php7.4-common (= 7.4.3-4ubuntu2.12) but 7.4.3-4ubuntu2.13 is to be installed
E: Unable to correct problems, you have held broken packages.

In der Zwischenzeit scheint die einzige Lösung für dieses Problem darin zu bestehen,-Vor-Sie führen das neueste PHP-Update durch ... stellen Sie sicher, dass dieses Repo auf Ihrem Computer installiert ist:

sudo add-apt-repository ppa:ondrej/php

Wenn dieses Repo vor Ihrem Update installiert wird, können Sie den oben genannten Albtraum vermeiden.

verwandte Informationen