Nextcloud funktioniert nach php update von 7.2 auf 7.4 nicht mehr.

Auch diese Ausgabe ist in Ordnung.

Ich hatte schon den Verdacht wegen den Fehlen weiter oben, wenn du php7.4-fpm aktivierst, sollte php7.4 deaktiviert sein.
sudo a2dismod php7.4

Die Anleitung ist für php7.4 und nicht php7.4-fpm ;)

Danach sollten dann diese Befehle ohne Fehler durchlaufen:
sudo a2dismod mpm_prefork
sudo a2enmod mpm_event

Sicherheitshalber nochmals alles neu starten.
sudo systemctl restart php7.4-fpm
sudo systemctl restart apache2
 
Wenn du PHP mit Custom PPAs updatest bettelst du um Ärger. Du Hast in #15 selbst eine Liste der von dir aktivierten PHP-Module. Vergleiche die Liste mit den Modulen die das von dir genutzte PPA anbietet. Wenn das PPA nicht alle genutzten Module anbietet würde ich den Rückbau empfehlen (PHP 7.2 aus den Distributions Repos). Die Chance dass du mit der Mischung aus 7.2 und 7.4 Modulen Inkompatiblitäten triffst sind schlicht zu hoch.

Edit: Was @Helge01 betreibt ist wieder Befehle ausführen, ohne zu wissen was Phase ist. a2query -m und a2query -c wäre angebracht (das "wieso" steht in der manpage, also bitte lesen).
 
Zuletzt bearbeitet:
@Piktogramm Normalerweise hast du recht, da aber hier die Vorgaben eindeutig waren, kann man das schon machen.

Vorgabe war php7.4-fpm, dann weiß man eigentlich was alles aktiviert sein muss.
 
Helge01 schrieb:
Auch diese Ausgabe ist in Ordnung.

Ich hatte schon den Verdacht wegen den Fehlen weiter oben, wenn du php7.4-fpm aktivierst, sollte php7.4 deaktiviert sein.
sudo a2dismod php7.4

Die Anleitung ist für php7.4 und nicht php7.4-fpm ;)

Danach sollten dann diese Befehle ohne Fehler durchlaufen:
sudo a2dismod mpm_prefork
sudo a2enmod mpm_event

Sicherheitshalber nochmals alles neu starten.
sudo systemctl restart php7.4-fpm
sudo systemctl restart apache2

Habe ich ausgeführt, hat leider nicht zum Erfolg geführt.
Code:
ncadmin@nextcloud:~$ sudo a2dismod php7.4
[sudo] password for ncadmin:
Module php7.4 already disabled
ncadmin@nextcloud:~$ sudo a2dismod mpm_prefork
Module mpm_prefork already disabled
ncadmin@nextcloud:~$ sudo a2enmod mpm_event
Considering conflict mpm_worker for mpm_event:
Considering conflict mpm_prefork for mpm_event:
Module mpm_event already enabled
ncadmin@nextcloud:~$

Piktogramm schrieb:
Edit: Was @Helge01 betreibt ist wieder Befehle ausführen, ohne zu wissen was Phase ist. a2query -m und a2query -c wäre angebracht (das "wieso" steht in der manpage, also bitte lesen).

Code:
ncadmin@nextcloud:~$ a2query -m
proxy_fcgi (enabled by site administrator)
autoindex (enabled by maintainer script)
authz_host (enabled by maintainer script)
http2 (enabled by site administrator)
authn_core (enabled by maintainer script)
mime (enabled by maintainer script)
deflate (enabled by maintainer script)
authn_file (enabled by maintainer script)
setenvif (enabled by maintainer script)
negotiation (enabled by maintainer script)
filter (enabled by maintainer script)
rewrite (enabled by site administrator)
access_compat (enabled by maintainer script)
headers (enabled by site administrator)
authz_core (enabled by maintainer script)
ssl (enabled by site administrator)
dir (enabled by maintainer script)
alias (enabled by maintainer script)
socache_shmcb (enabled by site administrator)
env (enabled by maintainer script)
mpm_event (enabled by site administrator)
auth_basic (enabled by maintainer script)
proxy (enabled by site administrator)
authz_user (enabled by maintainer script)
reqtimeout (enabled by maintainer script)
ncadmin@nextcloud:~$ a2query -c
other-vhosts-access-log (enabled by maintainer script)
serve-cgi-bin (enabled by maintainer script)
php7.4-fpm (enabled by site administrator)
security (enabled by maintainer script)
localized-error-pages (enabled by maintainer script)
charset (enabled by maintainer script)
ncadmin@nextcloud:~$
 
Auch das sieht eigentlich gut aus...
Hast du außer php noch irgendwas geändert?

Sieht man im syslog irgendwas, oder apache error.log?
 
Nicht dass mir das bewusst wäre.. Wie gesagt, wollte nur php7.4 installieren und dann rauf auf 20
 
Piktogramm schrieb:
Wenn du PHP mit Custom PPAs updatest bettelst du um Ärger. Du Hast in #15 selbst eine Liste der von dir aktivierten PHP-Module. Vergleiche die Liste mit den Modulen die das von dir genutzte PPA anbietet. Wenn das PPA nicht alle genutzten Module anbietet würde ich den Rückbau empfehlen (PHP 7.2 aus den Distributions Repos). Die Chance dass du mit der Mischung aus 7.2 und 7.4 Modulen Inkompatiblitäten triffst sind schlicht zu hoch.
 
Helge01 schrieb:
Sieht man im syslog irgendwas, oder apache error.log?

Apache2 error.log
Code:
[Thu Oct 15 06:25:10.921621 2020] [ssl:warn] [pid 1986:tid 140578357152704] AH01909: 127.0.1.1:443:0 server certificate does NOT include an ID which matches the server name
[Thu Oct 15 06:25:10.922164 2020] [mpm_event:notice] [pid 1986:tid 140578357152704] AH00489: Apache/2.4.29 (Ubuntu) OpenSSL/1.1.1g configured -- resuming normal operations
[Thu Oct 15 06:25:10.922172 2020] [core:notice] [pid 1986:tid 140578357152704] AH00094: Command line: '/usr/sbin/apache2'
[Thu Oct 15 09:27:23.854705 2020] [proxy:error] [pid 10741:tid 140577786009344] (2)No such file or directory: AH02454: FCGI: attempt to connect to Unix domain socket /run/php/php7.2-fpm.nextcloud.sock (*) failed
[Thu Oct 15 09:27:23.854772 2020] [proxy_fcgi:error] [pid 10741:tid 140577786009344] [client 192.168.178.10:45027] AH01079: failed to make connection to backend: httpd-UDS
[Thu Oct 15 09:29:14.614330 2020] [proxy:error] [pid 10740:tid 140577934685952] (2)No such file or directory: AH02454: FCGI: attempt to connect to Unix domain socket /run/php/php7.2-fpm.nextcloud.sock (*) failed
[Thu Oct 15 09:29:14.614390 2020] [proxy_fcgi:error] [pid 10740:tid 140577934685952] [client 192.168.178.10:45028] AH01079: failed to make connection to backend: httpd-UDS
[Thu Oct 15 09:50:12.890725 2020] [mpm_event:notice] [pid 1986:tid 140578357152704] AH00491: caught SIGTERM, shutting down
[Thu Oct 15 09:50:44.830619 2020] [ssl:warn] [pid 1933:tid 140446873144256] AH01909: 127.0.1.1:443:0 server certificate does NOT include an ID which matches the server name
[Thu Oct 15 09:50:45.030077 2020] [ssl:warn] [pid 1950:tid 140446873144256] AH01909: 127.0.1.1:443:0 server certificate does NOT include an ID which matches the server name
[Thu Oct 15 09:50:45.031487 2020] [mpm_event:notice] [pid 1950:tid 140446873144256] AH00489: Apache/2.4.29 (Ubuntu) OpenSSL/1.1.1g configured -- resuming normal operations
[Thu Oct 15 09:50:45.031521 2020] [core:notice] [pid 1950:tid 140446873144256] AH00094: Command line: '/usr/sbin/apache2'


Wie würde so ein Rückbau aussehen..?
 
Moin @Weckmann, Apache versucht noch immer mit php7.2-fpm zu kommunizieren. Wie sieht den die VirtualHost aus?
Existiert da so ein ähnlicher Eintrag?
Code:
<FilesMatch \.php$>
     SetHandler "proxy:unix:/run/php/php7.2-fpm.sock|fcgi://localhost/"
</FilesMatch>
Wenn nicht, dann mal danach suchen.
grep -r /run/php/php7.2-fpm /etc/apache2/
grep -r proxy:unix:/run/php/php /etc/apache2/
 
Zuletzt bearbeitet:
Hi, ja der Eintrag existiert

1234.PNG


Code:
<VirtualHost *:443>
    Header add Strict-Transport-Security: "max-age=15768000;includeSubdomains"
    # Header always set Referrer-Policy "strict-origin"
    SSLEngine on

### YOUR SERVER ADDRESS ###
#    ServerAdmin admin@example.com
#    ServerName example.com
#    ServerAlias subdomain.example.com

### SETTINGS ###
    <FilesMatch "\.php$">
        SetHandler "proxy:unix:/run/php/php7.2-fpm.nextcloud.sock|fcgi://localhost"
    </FilesMatch>

    DocumentRoot /var/www/nextcloud

    <Directory /var/www/nextcloud>
    Options Indexes FollowSymLinks
    AllowOverride All
    Require all granted
    Satisfy Any
    </Directory>

    <IfModule mod_dav.c>
    Dav off
    </IfModule>

    <Directory "/mnt/ncdata">
    # just in case if .htaccess gets disabled
    Require all denied
    </Directory>
    
    # The following lines prevent .htaccess and .htpasswd files from being
    # viewed by Web clients.
    <Files ".ht*">
    Require all denied
    </Files>
    
    # Disable HTTP TRACE method.
    TraceEnable off

    # Disable HTTP TRACK method.
    RewriteEngine On
    RewriteCond %{REQUEST_METHOD} ^TRACK
    RewriteRule .* - [R=405,L]

    SetEnv HOME /var/www/nextcloud
    SetEnv HTTP_HOME /var/www/nextcloud

### LOCATION OF CERT FILES ###
    SSLCertificateFile /etc/ssl/certs/ssl-cert-snakeoil.pem
    SSLCertificateKeyFile /etc/ssl/private/ssl-cert-snakeoil.key
</VirtualHost>

Code:
<VirtualHost *:80>

### YOUR SERVER ADDRESS ###
#    ServerAdmin admin@example.com
#    ServerName example.com
#    ServerAlias subdomain.example.com

### SETTINGS ###
    <FilesMatch "\.php$">
        SetHandler "proxy:unix:/run/php/php7.2-fpm.nextcloud.sock|fcgi://localhost"
    </FilesMatch>

    DocumentRoot /var/www/nextcloud

    <Directory /var/www/nextcloud>
    Options Indexes FollowSymLinks
    AllowOverride All
    Require all granted
    Satisfy Any
    </Directory>

    <IfModule mod_dav.c>
    Dav off
    </IfModule>

    <Directory "/mnt/ncdata">
    # just in case if .htaccess gets disabled
    Require all denied
    </Directory>
    
    # The following lines prevent .htaccess and .htpasswd files from being
    # viewed by Web clients.
    <Files ".ht*">
    Require all denied
    </Files>
    
    # Disable HTTP TRACE method.
    TraceEnable off

    # Disable HTTP TRACK method.
    RewriteEngine On
    RewriteCond %{REQUEST_METHOD} ^TRACK
    RewriteRule .* - [R=405,L]

    SetEnv HOME /var/www/nextcloud
    SetEnv HTTP_HOME /var/www/nextcloud

</VirtualHost>

Code:
<VirtualHost *:80>
    # The ServerName directive sets the request scheme, hostname and port that
    # the server uses to identify itself. This is used when creating
    # redirection URLs. In the context of virtual hosts, the ServerName
    # specifies what hostname must appear in the request's Host: header to
    # match this virtual host. For the default virtual host (this file) this
    # value is not decisive as it is used as a last resort host regardless.
    # However, you must set it for any further virtual host explicitly.
    #ServerName www.example.com

    ServerAdmin webmaster@localhost
    DocumentRoot /var/www

    # http://lost.l-w.ca/0x05/apache-mod_proxy_fcgi-and-php-fpm/
   <FilesMatch ".php$">
    <If "-f %{SCRIPT_FILENAME}">
      SetHandler "proxy:unix:/run/php/php7.2-fpm.nextcloud.sock|fcgi://localhost"
   </If>
   </FilesMatch>
    
    # Available loglevels: trace8, ..., trace1, debug, info, notice, warn,
    # error, crit, alert, emerg.
    # It is also possible to configure the loglevel for particular
    # modules, e.g.
    #LogLevel info ssl:warn

    ErrorLog ${APACHE_LOG_DIR}/error.log
    CustomLog ${APACHE_LOG_DIR}/access.log combined

    # For most configuration files from conf-available/, which are
    # enabled or disabled at a global level, it is possible to
    # include a line for only one particular virtual host. For example the
    # following line enables the CGI configuration for this host only
    # after it has been globally disabled with "a2disconf".
    #Include conf-available/serve-cgi-bin.conf
</VirtualHost>

# vim: syntax=apache ts=4 sw=4 sts=4 sr noet
 
Na dann haben wir es doch :)
Bei beiden VirtuaHosts die Zeilen auskommentieren, später kannst du die löschen.
Code:
    #<FilesMatch "\.php$">
    #    SetHandler "proxy:unix:/run/php/php7.2-fpm.nextcloud.sock|fcgi://localhost"
    #</FilesMatch>
Anschließend Apache neu starten, sudo systemctl restart apache2
 
Helge01 schrieb:
Gibt es ein Fehlermeldung im error.log?

Code:
[Thu Oct 15 15:16:19.706276 2020] [mpm_event:notice] [pid 1950:tid 140446873144256] AH00491: caught SIGTERM, shutting down
[Thu Oct 15 15:16:19.763038 2020] [ssl:warn] [pid 8452:tid 140004282534848] AH01909: 127.0.1.1:443:0 server certificate does NOT include an ID which matches the server name
[Thu Oct 15 15:16:19.771356 2020] [ssl:warn] [pid 8467:tid 140004282534848] AH01909: 127.0.1.1:443:0 server certificate does NOT include an ID which matches the server name
[Thu Oct 15 15:16:19.772277 2020] [mpm_event:notice] [pid 8467:tid 140004282534848] AH00489: Apache/2.4.29 (Ubuntu) OpenSSL/1.1.1g configured -- resuming normal operations
[Thu Oct 15 15:16:19.772368 2020] [core:notice] [pid 8467:tid 140004282534848] AH00094: Command line: '/usr/sbin/apache2'
[Thu Oct 15 15:16:59.513524 2020] [mpm_event:notice] [pid 8467:tid 140004282534848] AH00491: caught SIGTERM, shutting down
[Thu Oct 15 15:17:33.539727 2020] [ssl:warn] [pid 1950:tid 140718284471232] AH01909: 127.0.1.1:443:0 server certificate does NOT include an ID which matches the server name
[Thu Oct 15 15:17:33.547446 2020] [ssl:warn] [pid 1968:tid 140718284471232] AH01909: 127.0.1.1:443:0 server certificate does NOT include an ID which matches the server name
[Thu Oct 15 15:17:33.548651 2020] [mpm_event:notice] [pid 1968:tid 140718284471232] AH00489: Apache/2.4.29 (Ubuntu) OpenSSL/1.1.1g configured -- resuming normal operations
[Thu Oct 15 15:17:33.548685 2020] [core:notice] [pid 1968:tid 140718284471232] AH00094: Command line: '/usr/sbin/apache2'
[Thu Oct 15 15:19:37.048783 2020] [mpm_event:notice] [pid 1968:tid 140718284471232] AH00491: caught SIGTERM, shutting down
[Thu Oct 15 15:19:37.102245 2020] [ssl:warn] [pid 2734:tid 139977568668608] AH01909: 127.0.1.1:443:0 server certificate does NOT include an ID which matches the server name
[Thu Oct 15 15:19:37.108949 2020] [ssl:warn] [pid 2738:tid 139977568668608] AH01909: 127.0.1.1:443:0 server certificate does NOT include an ID which matches the server name
[Thu Oct 15 15:19:37.109849 2020] [mpm_event:notice] [pid 2738:tid 139977568668608] AH00489: Apache/2.4.29 (Ubuntu) OpenSSL/1.1.1g configured -- resuming normal operations
[Thu Oct 15 15:19:37.109876 2020] [core:notice] [pid 2738:tid 139977568668608] AH00094: Command line: '/usr/sbin/apache2'
 
Eigentlich nichts auffälliges. Die Verlinkung von 000-default.conf kannst du eigentlich löschen. Dann kannst du den ServerName auskommentieren und angeben (so wie du die Domain aufrufst). Anschließend Apache neu starten. Im error.log müsste es dann ruhig sein. Das kann es aber mMn nicht sein, normalerweise müsste es jetzt funktionieren.

Ich sehe gerade, dass mit diesen Zertifikaten die du nutzt, vermutlich weiterhin Meldungen im error.log auftauchen.
 
Zuletzt bearbeitet:
Helge01 schrieb:
Eigentlich nichts auffälliges. Die Verlinkung von 000-default.conf kannst du eigentlich löschen. Dann kannst du den ServerName auskommentieren und angeben (so wie du die Domain aufrufst). Anschließend Apache neu starten. Im error.log müsste es dann ruhig sein. Das kann es aber mMn nicht sein, normalerweise müsste es jetzt funktionieren.

Wo kann ich das anpassen?


Mir ist gerade noch aufgefallen, dass diese Meldungen jetzt im error.log erscheinen

Code:
[Thu Oct 15 15:47:43.226668 2020] [proxy_fcgi:error] [pid 2740:tid 139977019066112] [client 192.168.178.11:45184] AH01071: Got error 'PHP message: PHP Fatal error:  Uncaught Error: Class 'OCA\\DAV\\Connector\\Sabre\\ExceptionLoggerPlugin' not found in /var/www/nextcloud/remote.php:61\nStack trace:\n#0 /var/www/nextcloud/remote.php(169): handleException()\n#1 {main}\n  thrown in /var/www/nextcloud/remote.php on line 61'
[Thu Oct 15 15:47:43.241990 2020] [proxy_fcgi:error] [pid 2741:tid 139976968709888] [client 192.168.178.11:45185] AH01071: Got error 'PHP message: PHP Fatal error:  Uncaught Error: Class 'OCA\\DAV\\Connector\\Sabre\\ExceptionLoggerPlugin' not found in /var/www/nextcloud/remote.php:61\nStack trace:\n#0 /var/www/nextcloud/remote.php(169): handleException()\n#1 {main}\n  thrown in /var/www/nextcloud/remote.php on line 61'
[Thu Oct 15 15:47:43.306679 2020] [proxy_fcgi:error] [pid 2741:tid 139976960317184] [client 192.168.178.11:45186] AH01071: Got error 'PHP message: PHP Fatal error:  Uncaught Error: Class 'OCA\\DAV\\Connector\\Sabre\\ExceptionLoggerPlugin' not found in /var/www/nextcloud/remote.php:61\nStack trace:\n#0 /var/www/nextcloud/remote.php(169): handleException()\n#1 {main}\n  thrown in /var/www/nextcloud/remote.php on line 61'
[Thu Oct 15 15:47:43.397092 2020] [proxy_fcgi:error] [pid 2740:tid 139977010673408] [client 192.168.178.11:45187] AH01071: Got error 'PHP message: PHP Fatal error:  Uncaught Error: Class 'OCA\\DAV\\Connector\\Sabre\\ExceptionLoggerPlugin' not found in /var/www/nextcloud/remote.php:61\nStack trace:\n#0 /var/www/nextcloud/remote.php(169): handleException()\n#1 {main}\n  thrown in /var/www/nextcloud/remote.php on line 61'
 
Zuletzt bearbeitet:
Ich würde erst mal den Server neu starten, anschließend schauen was passiert und mit php -v überprüfen welche Version aktiv ist.
Eventuell kannst du durch Anlegen einer Datei im Nextcloud Verzeichnis schauen was da angezeigt wird.
https://www.internetwerk.de/support/webhosting/php-info-datei-erstellen-und-konfiguration-anzeigen/
Ergänzung ()

Weckmann schrieb:
Dann wollte ich noch auf 20 Updaten und habe das hier ausgeführt
https://www.c-rieger.de/manuelles-nextcloud-18-upgrade/
Jetzt erst gesehen, du hast php und anschließend Nextcloud manuell aktualisiert? Sehr mutig, du hättest deine bestehende Nextcloud Installation mit php7.4 testen können.
 
Zuletzt bearbeitet:
Helge01 schrieb:
Ich würde erst mal den Server neu starten, anschließend schauen was passiert und mit php -v überprüfen welche Version aktiv ist.
Eventuell kannst du durch Anlegen einer Datei im Nextcloud Verzeichnis schauen was da angezeigt wird.
https://www.internetwerk.de/support/webhosting/php-info-datei-erstellen-und-konfiguration-anzeigen/
Ergänzung ()


das habe ich gemacht und php7.4.11 scheint zu laufen

Code:
ncadmin@nextcloud:~$ php -v
PHP 7.4.11 (cli) (built: Oct 10 2020 19:44:50) ( NTS )
Copyright (c) The PHP Group
Zend Engine v3.4.0, Copyright (c) Zend Technologies
    with Zend OPcache v7.4.11, Copyright (c), by Zend Technologies
ncadmin@nextcloud:~$

Jetzt erst gesehen, du hast php und anschließend Nextcloud aktualisiert? Sehr mutig, du hättest deine bestehende Nextcloud Installation mit php7.4 testen können.

Ich habe wie in der Beschreibung beschrieben, dass alte Verzeichnis vorher verschoben.

Code:
und gehen wie folgt vor – wechseln Sie in das Webserververzeichnis:

cd /var/www

Verschieben Sie das bestehende Nextcloudverzeichnis:

mv nextcloud nextcloud19

0987654.PNG


Vielleicht kann ich ja zurück und dann testen
 
Das kannst du machen, nextcloud in nextcloud20 umbenennen und nextcloud19 in nextcloud. Die Berechtigungen sollten ja noch passen. Ich hoffe nur, dass durch die Aktualisierung der Datenbank keine Probleme auftreten.
 
Zurück
Oben