Have you ever encountered this error message: WordPress options is marked as crashed and should be repaired?

This may sound pretty frustrating but it is relatively easy to fix. It will, however, require going to your hosting account and using phpMyAdmin.

It seems the WordPress has detected some inconsistencies in the database and warned us that something is not OK.

In my case my WordPress installation was behaving very strangely. For example it wasn't deactivating plugins or saving plugin settings etc.

 

On WordPress forums people suggested to enable WP_DEBUG mode. Actually, that's how I managed to see the error message by the way.

 

My suggestion is to add the following code at the end of the wp-config.php file

if ($_SERVER['REMOTE_ADDR'] == '10.20.30.40') {
    define('WP_DEBUG', true);
}

By using this approach only you will be seeing the error/warning messages. Your users will not see them which is the better way to do it.

10.20.30.40 is your IP address. How to find your IP Address? See IPChicken.com and make sure there are no spaces when you paste your IP Address.


Solution

Go to phpMyAdmin and click on your database.

Before we do anything export the current database.

Then go back to the structure and select all tables (or only those that belong to the current WordPress site that needs fixing) and then select repair.

You'll be given some information about the operation.

 

I just created a video how to do that.

 

Referral Note: When you purchase through an referral link (if any) on this page, we may earn a commission.
If you're feeling thankful, you can buy me a coffee or a beer