Skip to content
WJunction - Webmaster Forum

How to repair crashed wp_options table, when phpmyadmin doesn't do the job

Status
Not open for further replies.
So you are hosting wordpress blog on VPS, and there were some server/wordpress updates, or similar disasters that caused your wordpress options tables to crash?

You are getting message: Error establishing a database connection ?

You don't have a backup, and hosting staff is incompetent, and asking from you database backup to restore it?

You tried PHPMyAdmin to repair tables, but it doesn't work? You get some dumb 'blob' messages from phpmyadmin?

You are pulling your hair out? Being bold is not trendy but here's the solution:

=========================


Well, solution is quite simple, but took me plenty of time to find working solution.

Solution is applied through SSH, since repairing tables from phpmyadmin in this case didn't work.

first you need to stop mysqld service by typing:

Code:
service mysqld stop

then run this command (ofc if you are running centos)

Code:
myisamchk /var/lib/mysql/YOURDBNAME/*.MYI

Search through output, and find something like this:

FdHjbhm.png


Then run this command:

Code:
myisamchk -r /var/lib/mysql/YOURDBHERE/wp_options.MYI

QSjYSwy.png


and last, but not least start mysqld:

Code:
service mysqld start

Then check your site, it should load now.



You can copy this article, but you must link back to original source.
 

3 comments

Status
Not open for further replies.

About the author

C
Active Member · Joined
5,788
Messages
4,363
Reactions
113
Points

Advertise on WJunction

Reach 1000's of webmasters, hosts & affiliates. Banner & sponsored-thread slots available.

Contact us
Back
Top Bottom