[SOLVED] Database Errors all of a sudden

rhylast

Joined: 2012-06-24
Posts: 3
Posted: Sun, 2012-06-24 15:03

I'm having several problems that seem to have come out of the blue.

First, if I type anything in my 'search' interface I get the DANG error page:

Quote:
Platform information

Host name: nerba.lunariffic.com
Operating system: Linux 2.6.18-194.3.1.el5PAE
Apache: Unknown
PHP: 5.2.14
MySQL: 5.1.62-rel13.3
Server load: 1.15 1.17 0.97
Graphics toolkit: imagemagick

Gallery stats

Version: 3.0.2 (Coollanta)
Albums: 44
Photos: 864

Database_Exception [ Database Error ]: #145: Table './smsan0_gall846/gal_search_records' is marked as crashed and should be repaired [ SELECT SQL_CALC_FOUND_ROWS gal_items.*, MATCH(gal_search_records.`data`) AGAINST ('sai sai*') AS `score` FROM gal_items JOIN gal_search_records ON (gal_items.`id` = gal_search_records.`item_id`) WHERE MATCH(gal_search_records.`data`) AGAINST ('sai sai*' IN BOOLEAN MODE) ORDER BY `score` DESC LIMIT 30 OFFSET 0 ]

SYSPATH/libraries/Database_Mysql_Result.php[ 27 ]
22 } 23 elseif (is_bool($result)) 24 { 25 if ($result == FALSE) 26 { 27 throw new Database_Exception('#:errno: :error [ :query ]', 28 array(':error' => mysql_error($link), 29 ':query' => $sql, 30 ':errno' => mysql_errno($link))); 31 32 }

Then, when I try to delete an image from the organizer, it says "error, please contact your system administrator."

If I try to add pictures, it says, "photo cannot be processed" and will not let me upload any new pictures.

Lastly, when I try to go to maintenance mode:

Quote:
Database_Exception [ Database Error ]: #145: Table './smsan0_gall846/gal_search_records' is marked as crashed and should be repaired [ DELETE FROM `gal_search_records` WHERE `item_id` NOT IN (SELECT `id` FROM `gal_items`) ]

SYSPATH/libraries/Database_Mysql_Result.php[ 27 ]
22 } 23 elseif (is_bool($result)) 24 { 25 if ($result == FALSE) 26 { 27 throw new Database_Exception('#:errno: :error [ :query ]', 28 array(':error' => mysql_error($link), 29 ':query' => $sql, 30 ':errno' => mysql_errno($link))); 31 32 }

I also tried just unpacking gallery 3.0.3 and moving the var folder, but the same problem happens with the newer version.

My original gallery is located at: http://www.rhylast.com/gallery
New 3.0.3. gallery: http://www.rhylast.com/gallery3 (with var folder from old gallery replaced over it)

Still the same errors anyway on both except with a thumbnail overlapping problem in 3.0.3 (i'm guessing it's the theme).

I would like to add that all these problems exist in another install I have at, also running on 3.0.2:

http://cbguild.rhylast.com/gallery/

I haven't touched this gallery in forever.

Login or register to post comments
floridave
floridave's picture

Joined: 2003-12-22
Posts: 25966
Posted: Sun, 2012-06-24 17:09
Quote:
is marked as crashed and should be repaired

You will need to use your DB admin tool the repair your DB.

There is tutorials on the net to use some admin tool like phpMyAdmin to repair tables from your control panel of your host.
Here is one for WP http://www.youtube.com/watch?v=7aFUfzCZuU0 but you could replace workdpress with gallery.

Dave
_____________________________________________
Blog & G2 || floridave - Gallery Team

Login or register to post comments
rhylast

Joined: 2012-06-24
Posts: 3
Posted: Sun, 2012-06-24 17:37

Thank you, I will check that out and try!

Login or register to post comments
rhylast

Joined: 2012-06-24
Posts: 3
Posted: Sun, 2012-06-24 17:54

Oh wow. That was really easy. LOL. Thank you!

Login or register to post comments