• Resolved simontpf

    (@simontpf)


    A few of the sites I manage had automatic updates switched on and attempted to install 6.3 overnight. I received emails this morning saying an attempt was made but the site could not be updated.

    The sites were not responding and it wasn’t even possible to log in to the dashboard, or access the actual site content. Everything was completely broken.

    Here’s the error messages I saw:

    PHP Fatal error: Cannot declare class WP_Metadata_Lazyloader, because the name is already in use in /var/www/html/wp-includes/class-wp-metadata-lazyloader.php on line 32
    PHP Fatal error: Uncaught Error: Call to a member function set() on null in /var/www/html/wp-includes/l10n.php:806\nStack trace:\n#0 /var/www/html/wp-includes/l10n.php(900): load_textdomain()\n#1 /var/www/html/wp-includes/class-wp-fatal-error-handler.php(47): load_default_textdomain()\n#2 [internal function]: WP_Fatal_Error_Handler->handle()\n#3 {main}\n thrown in /var/www/html/wp-includes/l10n.php on line 806

    Luckily I managed to work out how to roll back to 6.2.2 from the command line which means I can now log in to my site (I’ve switched automatic updates off).

    Has anybody else experienced this? Is this a known problem? I’m very hesitant to attempt an upgrade again until I know it’s not going to break everything.

Viewing 15 replies - 1 through 15 (of 16 total)
  • Hello, glad to know you were able to roll back to a working state. If you have a staging site, then you could try an upgrade to 6.3 and see if the issue stemmed from the update not being able to complete or if it’s due to some other factor.

    There was a similar issue (admin not accessible after WP 6.3 update) that involved the W3TC plugin, so just in case I put here the link to that thread – https://www.ads-software.com/support/topic/plugin-broken-my-wordpress-site-after-update-to-6-3/

    Thread Starter simontpf

    (@simontpf)

    Some further errors at the time of the automatic update:

    PHP Warning: copy(/var/www/html/wp-config-sample.php): Failed to open stream: Permission denied in /var/www/html/wp-admin/includes/class-wp-filesystem-direct.php on line 309
    PHP Warning: chmod(): No such file or directory in /var/www/html/wp-admin/includes/class-wp-filesystem-direct.php on line 173
    PHP Warning: chmod(): No such file or directory in /var/www/html/wp-admin/includes/class-wp-filesystem-direct.php on line 173
    PHP Warning: copy(/var/www/html/wp-config-sample.php): Failed to open stream: Permission denied in /var/www/html/wp-admin/includes/class-wp-filesystem-direct.php on line 309
    PHP Warning: chmod(): No such file or directory in /var/www/html/wp-admin/includes/class-wp-filesystem-direct.php on line 173
    PHP Warning: copy(/var/www/html/wp-config-sample.php): Failed to open stream: Permission denied in /var/www/html/wp-admin/includes/class-wp-filesystem-direct.php on line 309
    PHP Warning: chmod(): No such file or directory in /var/www/html/wp-admin/includes/class-wp-filesystem-direct.php on line 173
    PHP Warning: chmod(): No such file or directory in /var/www/html/wp-admin/includes/class-wp-filesystem-direct.php on line 173
    PHP Warning: copy(/var/www/html/wp-config-sample.php): Failed to open stream: Permission denied in /var/www/html/wp-admin/includes/class-wp-filesystem-direct.php on line 309
    PHP Warning: chmod(): No such file or directory in /var/www/html/wp-admin/includes/class-wp-filesystem-direct.php on line 173

    So it looks like something failed during the automatic update (because I don’t have the sample config file??)

    When the automatic update failed, it appears to have left the “require class-wp-metadata-lazyloader.php” in wp-includes/wp-settings.php (where it exists in 6.2.2) rather than move it into wp-includes/meta.php (where it exists in 6.3). This appears to be the cause of the errors I originally reported.

    After rolling back one of the sites to 6.2.2 I’ve tried a manual update on it (it’s not currently in use so I can test). That worked fine, even when the wp-config-sample.php file was not present) so I don’t know what could cause this to break during the automatic update.

    Thread Starter simontpf

    (@simontpf)

    Thanks, we’re not using W3TC, and the manual update appears to have worked correctly with exactly the same plugins as were on the site before.

    Hi, thanks for letting us know. If the manual update worked, then there could be something else that affected the autoupdate, which led to the fatal errors you have mentioned in your original post. The rest are warnings so they might likewise be effects of the autoupdate failure. You could check in Tools > Site Health to see if there is anything that could help pinpoint the cause of the autoupdate failure.

    Thread Starter simontpf

    (@simontpf)

    Here’s the site health report for background updates. I can’t see anything else related:

    Background updates ensure that WordPress can auto-update if a security update is released for the version you are currently using.

    • Warning A previous automatic background update could not occur. You would have received an email because of this. Another attempt will be made with the next release. The error code was copy_failed_copy_dir_retry.
    • Passed No version control systems were detected.
    • Passed Your installation of WordPress does not require FTP credentials to perform updates.
    • Passed All of your WordPress files are writable.

    Hello, thanks for the Site Health info; it looked like another attempt was going to be made, so when you noticed the issues you mentioned, one possibility was the website was stuck in maintenance mode — if that had been the case, you would only need to remove a .maintenance file in the website root folder via FTP or your host’s control panel file manager.

    I can’t say what caused the autoupdate failure though, it could be a temporary server resource overload. If you haven’t already, I would recommend having a regular scheduled backup in place to mitigate any risk of an autoupdate failure happening again in the future. Good luck!

    Thread Starter simontpf

    (@simontpf)

    Ok thanks, I don’t think it was stuck in maintenance mode as I couldn’t even get to the dashboard.

    Hi

    I am also facing this issue

    There is no maintenance file in the website root folder

    So kindly give me a solution

    Fatal error: Cannot declare class WP_Metadata_Lazyloader, because the name is already in use in /home3/wirelfhp/example.com/wp-includes/class-wp-metadata-lazyloader.php on line 32

    • This reply was modified 1 year, 3 months ago by rogrmartn.
    Thread Starter simontpf

    (@simontpf)

    Only solution I had is to log in to the server via ssh and manually revert back to 6.2.2 so I could at least log back in to the dashboard. Here’s the link to get the source code for 6.2.2:

    https://en-gb.www.ads-software.com/download/releases/

    And here’s the link I found showing how to revert the files (basically, copy everything from 6.2.2 but don’t overwrite your wp-config.php or your wp-content folder:

    https://www.hostinger.co.uk/tutorials/downgrade-wordpress

    We’ve seen a few reports of this and are investigating. If anyone is running into this problem and can provide more details about their setup, please reply on this ticket: https://core.trac.www.ads-software.com/ticket/59057

    You are a life saver, thank you so much for this. Reverting back to WordPress 6.2 solved for me

    Hi all, please help me to resolve the issue. Not able to log in to account and following error displayed.

    Warning: require(/home4/organonu/public_html/wp-includes/class-wp-duotone.php): Failed to open stream: No such file or directory in /home4/organonu/public_html/wp-settings.php on line 178

    Fatal error: Uncaught Error: Failed opening required ‘/home4/organonu/public_html/wp-includes/class-wp-duotone.php’ (include_path=’.:/opt/cpanel/ea-php82/root/usr/share/pear’) in /home4/organonu/public_html/wp-settings.php:178 Stack trace: #0 /home4/organonu/public_html/wp-config.php(100): require_once() #1 /home4/organonu/public_html/wp-load.php(50): require_once(‘/home4/organonu…’) #2 /home4/organonu/public_html/wp-blog-header.php(13): require_once(‘/home4/organonu…’) #3 /home4/organonu/public_html/sapp-wp-signon.php(40): require(‘/home4/organonu…’) #4 {main} thrown in /home4/organonu/public_html/wp-settings.php on line 178

    Hello everyone,

    I hope you’re all doing well. I’m facing a similar issue as discussed in the thread about WP_Metadata_Lazyloader. I’ve been following the conversation closely, but I haven’t come across a definitive solution yet.

    I have a couple of questions:

    1. Is there a command I can use to revert to the previous version? I’m unable to log in to my dashboard at the moment.
    2. Could someone please provide guidance on resolving this error? Any pointers or a comprehensive guide would be greatly appreciated.

    Thank you in advance.

    • This reply was modified 1 year, 3 months ago by silexlab.

    This happened to one of my sites also.

    Thank you @simontpf for the suggestion to roll back to 6.2.2! This worked.

    Interestingly, I didn’t even have time after manually rolling back to go and turn off the auto-update. It instantly updated to 6.3 again, but this time with no issue.

    @silexlab Not sure if you figured this out, but your problem was my exact issue. It looks like 6.3 failed to install in the middle of an upgrade, follow the instructions from this ticket https://core.trac.www.ads-software.com/ticket/59144#comment:1

    Worked for me!

Viewing 15 replies - 1 through 15 (of 16 total)
  • The topic ‘Automatic update to 6.3 completely broke everything’ is closed to new replies.