forum.coppermine-gallery.net

Support => cpg1.4.x Support => Older/other versions => cpg1.4 miscellaneous => Topic started by: AntihopE on November 21, 2007, 05:10:42 am

Title: pictures table crashed, won't repair
Post by: AntihopE on November 21, 2007, 05:10:42 am
I tried to delete a few pictures, then tried to add the pictures (or maybe in some other order), since I wanted to change their rotation.  I guess I tried a few times.  Then the DB crashed. 

Here's the error:


While executing query "SELECT count(*) FROM cpg1410_pictures as p, cpg1410_albums as a WHERE p.aid = a.aid AND approved='YES' AND category >= 10000 and a.aid NOT IN (41,58,89) " on 0

mySQL error: Table './words/cpg1410_pictures' is marked as crashed and should be repaired

So, I went into PhPMyAdmin and typed in :
repair table cpg1410_pictures;

It responded:
 words.cpg1410_pictures       repair       status       Table is already up to date

I have tried to repair all of the tables.. The other ones repair, and this one gives the same error.

http://www.antihope.com/cpg

I have set it to debug mode.  The page doesn't even load in Firefox, just bad page script.
Title: Re: pictures table crashed, won't repair
Post by: Joachim Müller on November 21, 2007, 07:24:49 am
If a table is crashed beyond repair the only option is to restore it from a previous backup. See
A crashed table is just that: it is broken. The repair command (no matter if it is issued using phpMyAdmin or directly on the shell) tries to repair the table. It may or may not be capable to repair it.
[...]
If an incident like this happens (i.e. if a mysql table crashes), you perform the repair command and hope that it will be capable to fix it. It not, restore the backup that you must have taken earlier.
There is no guarantee that the repair command will be able to repair a table. The message your get when running the repair command just says that phpMyAdmin was able to run the repair query, that's it. It doesn't mean that everything will then be fine.