Support » Fixing WordPress » 503 error with WordPress only (possibly WP5)

  • Resolved Thorned Rose

    (@thorned-rose)


    Yesterday I was able to access and use this website fine. Today this one (and another) are resulting in a 503 error. Other websites on the same hosting can be accessed fine. If I go directly to a file like robots.txt, it’s accessible. I can ping and traceroute the website fine. But as soon as I try to load the website with WordPress, it results in a 503. I have tried restoring the backup from yesterday – 503. Tried restoring from the day before that. Still 503.
    I believe the website was on 4.9.9. and I suspect that the error has started because it autoupdated or at least tried to update to 5.something. However, I can’t explain why restoring previous backups does not restore the site.
    I have tried all the tricks I can think of such as disabling the plugins/themes directories, deleting cache, turning off Cloudflare (which is running DNS only anyway), etc., etc., etc. ๐Ÿ™

    Help much appreciated!

    The page I need help with: [log in to see the link]

Viewing 9 replies - 1 through 9 (of 9 total)
  • Moderator t-p

    (@t-p)

    The 503 service unavailable error occurs when your web server is unable to get a proper response from a PHP script. This PHP script could be a WordPress plugin, a theme, or a misbehaving custom code snippet.

    If the error is caused by heavy usage, a server glitch, server temporarily offline for maintenance, the server too busy or concurrent request limit exceeded, or a DDoS attack, then it could automatically disappear in a few minutes.

    However, if it is caused by bad code on your website, then it will keep occurring unless you find and disable the code thatโ€™s causing it.

    To troubleshoot, try:
    – Deactivate plugins, switch theme, reinstall WP
    – If these methods fail to resolve the error, then try contacting your hosting providert.
    http://www.wpbeginner.com/wp-tutorials/how-to-fix-503-service-unavailable-error-in-wordpress/

    Probably not a CloudFlare issue though CloudFlare running as proxy tends to amplify the 500 type errors. Let the DNS run… it’s a better DNS than most servers or ISPs can ever hope to have.

    And Yeah, I see the robots.txt file just as soon as I request it so the server is working just fine…

    So what doesn’t work? Looks like anything running from index.php which is WordPress’ index.php (I hope).

    If you did a root install you might rename all the files there by adding a few numbers or ‘bak’ to them. Do the same to the sub-directories. And then install the older (oldest known good) backup files.

    If instead, this was an install in a sub-directory off webroot then you could try a rename of the sub-directory and then installing that older backup into an empty sub of the same original name. You shouldn’t need to reload the database but then again you might need to do that, too. You’ll need to deal with the index.php and htaccess file by copying those over from the backup.

    I can’t imagine much of anything else that could have went wrong during the update.

    Maybe, just maybe, you’ll need to start from scratch with a fresh install on a new database then selectively install the files and then the database from that older backup.

    That’s the worst case though.

    @t-p Not sure if that’s an automated response or not but as I said in my OP, I tried all those things. The website is accessible via anything BUT WordPress. Other WordPress websites that are on the same hosting are loading fine. This is very unlikely to be an issue with the hosting.

    @jnashhawkins Thanks for your help. I’m about to try restoring an even older backup because at this stage I’ll try just about anything. This is a large complicated website with important booking system and a LOT of customisation so starting again is my worst freaking nightmare! ๐Ÿ™

    *sigh* Restoring a backup from 1st November (WordPress v4.9.8) still results in a 503. Blitzing the files and then restoring results in a 503.

    Fresh install of WordPress 4.9 is still coming up with a 503

    I have fixed it. There was something funky going on with the PHP versioning. I tried switching to another version of PHP and then back again (PHP 7.1) and it started working. I then restored the current backup and all is now fine. I tried to switch to PHP 7.2 and it looks like that caused a massive memory leak as the processor and RAM maxed out. Switch back to PHP 7.1 and all is happy again.
    I have no idea what has caused these issues with PHP and no idea why switching between versions solved the problem.
    All I can say is that if anyone else has mysterious 503 issues where nothing seems to resolve it, try checking your PHP version.

    Moderator t-p

    (@t-p)

    Thanks for reporting. ๐Ÿ™‚

    Error 503 was created by DoS Denial of Service

    Moderator t-p

    (@t-p)

    Glad its sorted ๐Ÿ™‚

Viewing 9 replies - 1 through 9 (of 9 total)
  • The topic ‘503 error with WordPress only (possibly WP5)’ is closed to new replies.