• Gelöst lukashauger

    (@lukashauger)


    Hallo liebe WordPress-Community,

    ich würde gerne bei meiner Website die PHP-Version von 7.4 auf 8.0 (oder auch 8.1 oder 8.2) upgraden. Das Setup ist das folgende:

    Website: https://musikfreizeit.de
    Hosting: Strato AG
    WordPress: Version 6.4.1

    Wenn ich bei Strato die PHP Version von 7.4 auf 8.0, 8.1 oder 8.2 umstelle erscheint statt der Website folgende Fehlermeldung:

    Es gab einen kritischen Fehler auf deiner Website. Bitte überprüfe den Posteingang deiner Website-Administrator-E-Mail-Adresse für weitere Anweisungen.

    Erfahre mehr über die Problembehandlung in WordPress.

    (Kopie Fehlermeldung von http://www.musikfreizeit.de)

    Die betrifft alle Seiten der Website, d.h. auch ein Admin-Zugang oder Änderungen an Einstellungen von WordPress ist dann nicht mehr möglich. Eine E-Mail habe ich leider nicht erhalten. Ich habe glücklicherweise die Möglichkeit die PHP Version wieder zurückzustellen woraufhin alles wieder wie gewohnt funktioniert.

    Ich bitte darum mir zu helfen die Website auf PHP 8.0 upzudaten ohne die obige Fehlermeldung zu erhalten. Im Folgenden gebe ich weitere Details zu Installationen und was ich bereits versucht habe.

    Installierte Plugins:
    – Contact Form 7
    – Duplicator
    – MailChimp
    – Widgets for SiteOrigin
    – WP Staging – Backup Duplicator & Migration
    – WP Super Cache
    Installierte Themes:
    – Advanced Twenty Seventeen Child (aktiv)
    – Twenty Seventeen
    – Twenty Twenty-Four
    Alle Plugins und Themes sind auf die jeweils neueste Version aktualisiert.

    Was ich bereits versucht habe:

    1. Alle Plugins deaktivieren und das Theme auf Twenty Twenty-Four umstellen.
    2. Staging Site mit WP Staging erstellen, auf dieser alle Plugins deinstallieren, das Theme auf Twenty Twenty-Four umstellen, alle anderen Themes deinstallieren, alle Seiten bis auf die Startseite löschen und diese auf 3 Textzeilen reduzieren.
    3. Alle Plugins und Themes in Suchmaschinen eingeben und nach Kompatibilitätsproblemen mit PHP 8 suchen. Ich habe nichts bedenkliches gefunden.

    Alle Versuche haben nichts daran geändert, dass die Website auf PHP 7.4 einwandfrei läuft und auf PHP 8.0, 8.1 und 8.2 nur obige Fehlermeldung ausgibt. Dies trifft ebenfalls auf die Staging Site zu.

    Ich weiß nun leider nicht mehr was ich noch ausprobieren könnte. Ich bin nebenbeibemerkt Neuling auf WordPress und habe die Website nicht selbst erstellt aber jede einzelne Seite auf mögliche Fehlerquellen durchsucht. Über Hinweise, Ideen und Tipps was ich noch probieren könnte freue ich mich sehr!

    Vielen Dank und herzliche Grüße,
    Lukas Hauger

    P.S: Hier der Bericht meiner Website:

    `
    ### wp-core ###
    
    version: 6.4.1
    site_language: de_DE
    user_language: de_DE
    timezone: +00:00
    permalink: /%postname%/
    https_status: true
    multisite: false
    user_registration: 0
    blog_public: 1
    default_comment_status: closed
    environment_type: production
    user_count: 2
    dotorg_communication: true
    
    ### wp-paths-sizes ###
    
    wordpress_path: /mnt/web112/b2/65/51339265/htdocs
    wordpress_size: 2,87 GB (3078855406 bytes)
    uploads_path: /mnt/web112/b2/65/51339265/htdocs/wp-content/uploads
    uploads_size: 1,01 GB (1087079483 bytes)
    themes_path: /mnt/web112/b2/65/51339265/htdocs/wp-content/themes
    themes_size: 5,91 MB (6198560 bytes)
    plugins_path: /mnt/web112/b2/65/51339265/htdocs/wp-content/plugins
    plugins_size: 25,46 MB (26700340 bytes)
    database_size: 24,84 MB (26050560 bytes)
    total_size: 3,93 GB (4224884349 bytes)
    
    ### wp-dropins (1) ###
    
    advanced-cache.php: true
    
    ### wp-active-theme ###
    
    name: Advanced Twenty Seventeen Child (advanced-twenty-seventeen-child)
    version: 1.0
    author: SaturnSolutions
    author_website: http://saturnsolutions.com/
    parent_theme: Twenty Seventeen (twentyseventeen)
    theme_features: core-block-patterns, widgets-block-editor, automatic-feed-links, title-tag, custom-line-height, post-thumbnails, menus, html5, post-formats, custom-logo, customize-selective-refresh-widgets, editor-style, editor-styles, wp-block-styles, responsive-embeds, starter-content, custom-header, widgets
    theme_path: /mnt/web112/b2/65/51339265/htdocs/wp-content/themes/advanced-twenty-seventeen-child
    auto_update: Deaktiviert
    
    ### wp-parent-theme ###
    
    name: Twenty Seventeen (twentyseventeen)
    version: 3.4
    author: Das WordPress-Team
    author_website: https://de.wordpress.org/
    theme_path: /mnt/web112/b2/65/51339265/htdocs/wp-content/themes/twentyseventeen
    auto_update: Deaktiviert
    
    ### wp-themes-inactive (1) ###
    
    Twenty Twenty-Four: version: 1.0, author: Das WordPress-Team, Automatische Aktualisierungen deaktiviert
    
    ### wp-mu-plugins (1) ###
    
    WP STAGING Optimizer: version: 1.5.4, author: WP STAGING
    
    ### wp-plugins-active (6) ###
    
    Contact Form 7: version: 5.8.3, author: Takayuki Miyoshi, Automatische Aktualisierungen aktiviert
    Duplicator: version: 1.5.7.1, author: Duplicator, Automatische Aktualisierungen aktiviert
    MailChimp: version: 1.5.8, author: MailChimp, Automatische Aktualisierungen aktiviert
    Widgets for SiteOrigin: version: 1.4.7, author: WPinked, Automatische Aktualisierungen deaktiviert
    WP STAGING - Backup Duplicator & Migration: version: 3.1.3, author: WP-STAGING, WPStagingBackup, Automatische Aktualisierungen deaktiviert
    WP Super Cache: version: 1.11.0, author: Automattic, Automatische Aktualisierungen deaktiviert
    
    ### wp-media ###
    
    image_editor: WP_Image_Editor_Imagick
    imagick_module_version: 1692
    imagemagick_version: ImageMagick 6.9.12-90 Q16 x86_64 17868 https://legacy.imagemagick.org
    imagick_version: 3.5.1
    file_uploads: 1
    post_max_size: 128M
    upload_max_filesize: 128M
    max_effective_size: 128 MB
    max_file_uploads: 20
    imagick_limits: 
    	imagick::RESOURCETYPE_AREA: 8 GB
    	imagick::RESOURCETYPE_DISK: 9.2233720368548E+18
    	imagick::RESOURCETYPE_FILE: 192
    	imagick::RESOURCETYPE_MAP: 4 GB
    	imagick::RESOURCETYPE_MEMORY: 2 GB
    	imagick::RESOURCETYPE_THREAD: 1
    	imagick::RESOURCETYPE_TIME: 9.2233720368548E+18
    imagemagick_file_formats: 3FR, 3G2, 3GP, A, AAI, AI, APNG, ART, ARW, AVI, AVS, B, BGR, BGRA, BGRO, BMP, BMP2, BMP3, BRF, C, CAL, CALS, CANVAS, CAPTION, CIN, CIP, CLIP, CMYK, CMYKA, CR2, CR3, CRW, CUR, CUT, DATA, DCM, DCR, DCX, DDS, DFONT, DNG, DPX, DXT1, DXT5, EPDF, EPI, EPS, EPS2, EPS3, EPSF, EPSI, EPT, EPT2, EPT3, ERF, FAX, FILE, FITS, FLV, FRACTAL, FTP, FTS, G, G3, G4, GIF, GIF87, GRADIENT, GRAY, GRAYA, GROUP4, H, HALD, HDR, HISTOGRAM, HRZ, HTM, HTML, HTTP, HTTPS, ICB, ICO, ICON, IIQ, INFO, INLINE, IPL, ISOBRL, ISOBRL6, JNG, JNX, JPE, JPEG, JPG, JPS, JSON, K, K25, KDC, LABEL, M, M2V, M4V, MAC, MAGICK, MAP, MASK, MAT, MATTE, MEF, MIFF, MKV, MNG, MONO, MOV, MP4, MPC, MPEG, MPG, MRW, MSL, MSVG, MTV, MVG, NEF, NRW, NULL, O, ORF, OTB, OTF, PAL, PALM, PAM, PANGO, PATTERN, PBM, PCD, PCDS, PCL, PCT, PCX, PDB, PDF, PDFA, PEF, PES, PFA, PFB, PFM, PGM, PGX, PICON, PICT, PIX, PJPEG, PLASMA, PNG, PNG00, PNG24, PNG32, PNG48, PNG64, PNG8, PNM, POCKETMOD, PPM, PS, PS2, PS3, PSB, PSD, PTIF, PWP, R, RADIAL-GRADIENT, RAF, RAS, RAW, RGB, RGBA, RGBO, RGF, RLA, RLE, RMF, RW2, SCR, SCREENSHOT, SCT, SFW, SGI, SHTML, SIX, SIXEL, SPARSE-COLOR, SR2, SRF, STEGANO, SUN, SVG, SVGZ, TEXT, TGA, THUMBNAIL, TIFF, TIFF64, TILE, TIM, TTC, TTF, TXT, UBRL, UBRL6, UIL, UYVY, VDA, VICAR, VID, VIDEO, VIFF, VIPS, VST, WBMP, WEBM, WEBP, WMV, WPG, X3F, XBM, XC, XCF, XPM, XPS, XV, Y, YCbCr, YCbCrA, YUV
    gd_version: bundled (2.1.0 compatible)
    gd_formats: GIF, JPEG, PNG, WebP, BMP
    ghostscript_version: not available
    
    ### wp-server ###
    
    server_architecture: Linux localhost 4.18.0-477.15.1.el8_8.x86_64 #1 SMP Linux localhost 4.18.0-477.15.1.el8_8.x86_64 #1 SMP Linux localhost 4.18.0-477.15.1.el8_8.x86_64 #1 SMP
    httpd_software: Apache/2.4.57 (Unix)
    php_version: 7.4.33 64bit
    php_sapi: cgi-fcgi
    max_input_variables: 4000
    time_limit: 240
    memory_limit: 512M
    max_input_time: 60
    upload_max_filesize: 128M
    php_post_max_size: 128M
    curl_version: 8.4.0 OpenSSL/3.0.10
    suhosin: false
    imagick_availability: true
    pretty_permalinks: true
    htaccess_extra_rules: true
    current: 2023-11-22T15:20:11+00:00
    utc-time: Wednesday, 22-Nov-23 15:20:11 UTC
    server-time: 2023-11-22T15:20:08+00:00
    
    ### wp-database ###
    
    extension: mysqli
    server_version: 5.7.42-log
    client_version: 5.6.45
    max_allowed_packet: 67108864
    max_connections: 3000
    
    ### wp-constants ###
    
    WP_HOME: undefined
    WP_SITEURL: undefined
    WP_CONTENT_DIR: /mnt/web112/b2/65/51339265/htdocs/wp-content
    WP_PLUGIN_DIR: /mnt/web112/b2/65/51339265/htdocs/wp-content/plugins
    WP_MEMORY_LIMIT: 40M
    WP_MAX_MEMORY_LIMIT: 512M
    WP_DEBUG: false
    WP_DEBUG_DISPLAY: true
    WP_DEBUG_LOG: false
    SCRIPT_DEBUG: false
    WP_CACHE: true
    CONCATENATE_SCRIPTS: undefined
    COMPRESS_SCRIPTS: undefined
    COMPRESS_CSS: undefined
    WP_ENVIRONMENT_TYPE: Nicht definiert
    WP_DEVELOPMENT_MODE: undefined
    DB_CHARSET: utf8
    DB_COLLATE: undefined
    
    ### wp-filesystem ###
    
    wordpress: writable
    wp-content: writable
    uploads: writable
    plugins: writable
    themes: writable
    mu-plugins: writable
    
    `

    • Dieses Thema wurde geändert vor 1 Jahr, 3 Monaten von lukashauger.

    Die Seite, für die ich Hilfe brauche: [Anmelden, um den Link zu sehen]

Ansicht von 6 Antworten – 1 bis 6 (von insgesamt 6)
  • Hallo,
    evtl. hängt das Problem mit Einträgen in der wp-config.php zusammen. Poste doch bitte mal den Inhalt der Datei wp-config.php. Zugangsdaten und SALT-Keys solltest du vor dem Absenden aus der Antwort auf jeden Fall löschen. Auf die Datei kannst du per FTP zugreifen.

    Schau doch mal nach, ob im Kundenmenü von Strato „Serverside Security“ aktiviert ist, weil das öfters zu Problemen führt. Eine Anleitung dazu gibt es von Strato. Den „Dienst“ musst du bitte deaktivieren. Evtl. liegt es daran (obwohl ich das nicht glaube).

    Viele Grüße
    Hans-Gerd

    • Diese Antwort wurde geändert vor 1 Jahr, 3 Monaten von Hans-Gerd Gerhards. Grund: Änderung und Ergänzung
    Thread-Starter lukashauger

    (@lukashauger)

    Hallo Hans-Gerd,

    vielen Dank für deine schnelle Rückmeldung und Hilfestellung! Die „Serverside Security“ war aktiviert und habe ich nun deaktiviert. Geändert hat dies am Problem wie von dir erwartet leider nichts.

    Der Zugriff auf die wp-config.php per FTP hat geklappt (via SFTP schlug die Verbindung fehl). Danke auch für den Hinweis auf das Löschen der Zugangsdaten und SALT-Keys. Ich habe diese durch „xxxxx“ ersetzt. Hier die wp-config.php Datei:

    <?php
    /**
     * The base configuration for WordPress
     *
     * The wp-config.php creation script uses this file during the
     * installation. You don't have to use the web site, you can
     * copy this file to "wp-config.php" and fill in the values.
     *
     * This file contains the following configurations:
     *
     * * MySQL settings
     * * Secret keys
     * * Database table prefix
     * * ABSPATH
     *
     * @link https://codex.wordpress.org/Editing_wp-config.php
     *
     * @package WordPress
     */
    
    // ** MySQL settings - You can get this info from your web host ** //
    /** The name of the database for WordPress */
    define('WP_CACHE', true);
    define( 'WPCACHEHOME', '/mnt/web112/b2/65/51339265/htdocs/wp-content/plugins/wp-super-cache/' );
    define('DB_NAME', 'xxxxxxxxx');
    
    /** MySQL database username */
    define('DB_USER', 'xxxxxxxxx');
    
    /** MySQL database password */
    define('DB_PASSWORD', 'xxxxxxxxx');
    
    /** MySQL hostname */
    define('DB_HOST', 'rdbms.strato.de');
    
    /** Database Charset to use in creating database tables. */
    define('DB_CHARSET', 'utf8');
    
    /** The Database Collate type. Don't change this if in doubt. */
    define('DB_COLLATE', '');
    
    /**#@+
     * Authentication Unique Keys and Salts.
     *
     * Change these to different unique phrases!
     * You can generate these using the {@link https://api.wordpress.org/secret-key/1.1/salt/ WordPress.org secret-key service}
     * You can change these at any point in time to invalidate all existing cookies. This will force all users to have to log in again.
     *
     * @since 2.6.0
     */
    define('AUTH_KEY',         'xxxxx');
    define('SECURE_AUTH_KEY',  'xxxxx');
    define('LOGGED_IN_KEY',    'xxxxx');
    define('NONCE_KEY',        'xxxxx');
    define('AUTH_SALT',        'xxxxx');
    define('SECURE_AUTH_SALT', 'xxxxx');
    define('LOGGED_IN_SALT',   'xxxxx');
    define('NONCE_SALT',       'xxxxx');
    /**#@-*/
    
    /**
     * WordPress Database Table prefix.
     *
     * You can have multiple installations in one database if you give each
     * a unique prefix. Only numbers, letters, and underscores please!
     */
    $table_prefix  = 'wp_';
    
    /**
     * For developers: WordPress debugging mode.
     *
     * Change this to true to enable the display of notices during development.
     * It is strongly recommended that plugin and theme developers use WP_DEBUG
     * in their development environments.
     *
     * For information on other constants that can be used for debugging,
     * visit the Codex.
     *
     * @link https://codex.wordpress.org/Debugging_in_WordPress
     */
    define('WP_DEBUG', false);
    
    /* That's all, stop editing! Happy blogging. */
    
    /** Absolute path to the WordPress directory. */
    if ( !defined('ABSPATH') )
    	define('ABSPATH', dirname(__FILE__) . '/');
    
    /** Sets up WordPress vars and included files. */
    require_once(ABSPATH . 'wp-settings.php');
    
    define( 'WP_ALLOW_MULTISITE', true );
    
    define ('FS_METHOD', 'direct');
    
    define( "WP_AUTO_UPDATE_CORE", minor );

    Vielen Dank und liebe Grüße,
    Lukas

    • Diese Antwort wurde geändert vor 1 Jahr, 3 Monaten von Hans-Gerd Gerhards. Grund: DB_NAME habe ich ebenfalls auf xxxxx gesetzt
    Moderator threadi

    (@threadi)

    Die allerletzte Zeile aus der Datei ist syntaktisch fehlerhaft. Überhaupt sind die unteren 3 Zeilen an der falschen Stelle. Diese Zeilen

    define( 'WP_ALLOW_MULTISITE', true );
    
    define ('FS_METHOD', 'direct');
    
    define( "WP_AUTO_UPDATE_CORE", 'minor' );

    müssten vor

    That's all, stop editing!

    eingefügt werden. Achte auf die korrekte Schreibweise von 'minor' an der Stelle.

    Eigentlich sollte dieser Schreibfehler auch bei PHP 7.4 oder älter zu einem Fehler führen. Sollte nach der Korrektur dir weiterhin eine Fehlermeldung angezeigt werden, schau im Error-Log deines Hosters nach was es genau ist. Der Support deines Hosters kann dir helfen dieses zu finden. Alternativ kannst Du auch das Debugging in WordPress aktivieren wie hier beschrieben: https://wordpress.org/documentation/article/debugging-in-wordpress/

    Hallo,
    ich hatte schon die Vermutung, dass genau diese Zeilen für dieses Problem verantwortlich sind. Das Problem ist hier schon einige Male angesprochen worden und hängt mit genau diesem Hoster zusammen. Zumal die Zeile define( 'WP_ALLOW_MULTISITE', true ); gar nicht notwendig wäre, weil du gar keine Multisite hast (siehe im Website-Bericht: multisite: false).

    Ärgerlich dabei ist, dass dieser Hoster dann auch selbst in solchen Fällen in der Regel auf den Support von WordPress verweist und nicht zumindest hier im Forum über entsprechende Antworten dafür sorgt, dass solche Dinge bei seinen Usern wieder korrigiert werden.

    Mehr Infos zu dieser ganzen Geschichte findest du z. B. in dem folgenden Beitrag.

    Die von @threadi vorgeschlagene Vorgehensweise wäre auch mein Vorschlag in dem Fall, wobei du auf jeden Fall die wp-config.php vorher lokal sichern solltest.

    Viele Grüße
    Hans-Gerd

    • Diese Antwort wurde geändert vor 1 Jahr, 3 Monaten von Hans-Gerd Gerhards. Grund: Änderung und Ergänzung
    Thread-Starter lukashauger

    (@lukashauger)

    Hallo threadi und Hans-Gerd,

    vielen Dank für eure Antworten! Ich habe die wp-config.php Datei wie von euch beschrieben korrigiert und siehe da: Die Website funktioniert mit PHP 8.0 und 8.2 fehlerlos!

    Ich habe übrigens ebenfalls den Support von Strato zuerst um Hilfe gebeten und bin dann aber abgewiesen worden, da Strato dafür nicht zuständig wäre. Laut dem von Hans-Gerd verlinkten Beitrag bin ich da wohl nicht der Einzige dem es so ergangen ist.

    Ich danke euch so sehr! Unten gebe ich noch die korrigierte wp-config.php Datei an (mit gelöschten Zugangsdaten/SALT-keys).

    Herzliche Grüße,
    Lukas

    <?php
    /**
     * The base configuration for WordPress
     *
     * The wp-config.php creation script uses this file during the
     * installation. You don't have to use the web site, you can
     * copy this file to "wp-config.php" and fill in the values.
     *
     * This file contains the following configurations:
     *
     * * MySQL settings
     * * Secret keys
     * * Database table prefix
     * * ABSPATH
     *
     * @link https://codex.wordpress.org/Editing_wp-config.php
     *
     * @package WordPress
     */
    
    // ** MySQL settings - You can get this info from your web host ** //
    /** The name of the database for WordPress */
    define('WP_CACHE', true);
    define( 'WPCACHEHOME', '/mnt/web112/b2/65/51339265/htdocs/wp-content/plugins/wp-super-cache/' );
    define('DB_NAME', 'xxxxx');
    
    /** MySQL database username */
    define('DB_USER', 'xxxxx');
    
    /** MySQL database password */
    define('DB_PASSWORD', 'xxxxx');
    
    /** MySQL hostname */
    define('DB_HOST', 'rdbms.strato.de');
    
    /** Database Charset to use in creating database tables. */
    define('DB_CHARSET', 'utf8');
    
    /** The Database Collate type. Don't change this if in doubt. */
    define('DB_COLLATE', '');
    
    /**#@+
     * Authentication Unique Keys and Salts.
     *
     * Change these to different unique phrases!
     * You can generate these using the {@link https://api.wordpress.org/secret-key/1.1/salt/ WordPress.org secret-key service}
     * You can change these at any point in time to invalidate all existing cookies. This will force all users to have to log in again.
     *
     * @since 2.6.0
     */
    define('AUTH_KEY',         'xxxxx');
    define('SECURE_AUTH_KEY',  'xxxxx');
    define('LOGGED_IN_KEY',    'xxxxx');
    define('NONCE_KEY',        'xxxxx');
    define('AUTH_SALT',        'xxxxx');
    define('SECURE_AUTH_SALT', 'xxxxx');
    define('LOGGED_IN_SALT',   'xxxxx');
    define('NONCE_SALT',       'xxxxx');
    /**#@-*/
    
    /**
     * WordPress Database Table prefix.
     *
     * You can have multiple installations in one database if you give each
     * a unique prefix. Only numbers, letters, and underscores please!
     */
    $table_prefix  = 'wp_';
    
    /**
     * For developers: WordPress debugging mode.
     *
     * Change this to true to enable the display of notices during development.
     * It is strongly recommended that plugin and theme developers use WP_DEBUG
     * in their development environments.
     *
     * For information on other constants that can be used for debugging,
     * visit the Codex.
     *
     * @link https://codex.wordpress.org/Debugging_in_WordPress
     */
    define('WP_DEBUG', false);
    
    define( 'WP_ALLOW_MULTISITE', true );
    
    define ('FS_METHOD', 'direct');
    
    define( "WP_AUTO_UPDATE_CORE", 'minor' );
    
    /* That's all, stop editing! Happy blogging. */
    
    /** Absolute path to the WordPress directory. */
    if ( !defined('ABSPATH') )
    	define('ABSPATH', dirname(__FILE__) . '/');
    
    /** Sets up WordPress vars and included files. */
    require_once(ABSPATH . 'wp-settings.php');
    
    • Diese Antwort wurde geändert vor 1 Jahr, 3 Monaten von Hans-Gerd Gerhards. Grund: Code korrigiert

    super – freut uns. Danke für die Rückmeldung und “Gelöst”-Markieren. 👍

Ansicht von 6 Antworten – 1 bis 6 (von insgesamt 6)
  • Das Thema „Kompatibilitätsprobleme bei Update von PHP Version 7.4 auf 8.0“ ist für neue Antworten geschlossen.