mysql db problems

They have: 28 posts

Joined: May 2003

Hi, one of my tables has gotten corrupt or something in the past few weeks. Is this a problem with the server? I have a feeling my hosts server is crapping out with too many open connections. I got it fixed by using the repair option via phpmyadmin...

They have: 447 posts

Joined: Oct 1999

it happens. can't tell you exactly what caused it, but in my experience mysql shutting down improperly (such as a hard kill), the server crashing, or running out of disk space can corrupt tables.

99/100 times REPAIR TABLE tablename; will fix it.

Mark Hensler's picture

He has: 4,048 posts

Joined: Aug 2000

I'm just curious. Are you using a lot of permanent connections? Or do you avoid them?

They have: 28 posts

Joined: May 2003

NO, I don't use any permanent.

They have: 30 posts

Joined: Aug 2003

that happened to me a couple of times on one server and the reason was frequent server crashes.

They have: 28 posts

Joined: May 2003

Yes...i'm almost sure its the server crapping out.

They have: 4 posts

Joined: Aug 2003

Hi,

On a related note, you may want to backup your database or at least important tables on a daily basis or any other better frequency that makes sense.

Table corruption, data loss is a very frequent issue we as webmasters have to deal with. So, precaution is better than cure.

Regards,
- Nitin

Webmaster tools, tutorials and tips.

Get a FREE ebook on Building Dynamic Web Sites
technobuff.net

Want to join the discussion? Create an account or log in if you already have one. Joining is fast, free and painless! We’ll even whisk you back here when you’ve finished.