Re: database repair corruption

This is a discussion on Re: database repair corruption within the MySQL Database forums, part of the Database Forums category; Troy Piggins wrote : > We had a MySQL v4.x database running, and a quick "backup" was > ...


Go Back   Usenet Forums > Database Forums > MySQL Database

FAQ Members List Calendar Search Today's Posts Mark Forums Read
  #1 (permalink)  
Old 04-27-2007
Hugo
 
Posts: n/a
Default Re: database repair corruption

Troy Piggins wrote :

> We had a MySQL v4.x database running, and a quick "backup" was
> made by simply copying the /var/lib/mysql dir to a backup
> drive.


This is a poor backup according to me. You rather should use "mysqldump"
tools which is designed for such tasks.

> Copied the /var/lib/mysql dir to another running server with
> MySQL v5 on it in a rush. :-(


AFAIK, you could not assume raw data representation compatibility
between version of MySQL, especially between two major versions (v4-v5).
This means that is unlikely that a data folder wrote by MySQL v4 could
be understood by MySQL v5.

Maybe MyISAM is more flexible regarding that point than let's say
InnoDB, or maybe conversion scripts exist somewhere, but it's anyway not
safe to rely on such assumption.

> Any recommendations on a better restore that won't get corrupted
> tables? Or is hte problem from how it was copied originally?


Try to install a MySQL with the same version that the one you make
backup with. Copy the folder into this fresh installation. If done
correctly, you should be able to get your MySQL running up with the
backup data into it. You could then use mysqldump to export this data,
and finally import them into your MySQL v5 successfully.

[follow up to]

--
Hugo
Reply With Quote
Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are Off
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On



All times are GMT +1. The time now is 08:21 AM.


Powered by vBulletin® Version 3.7.3
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO 3.0.0