Bug 507296 - Databases created by MySQL v4 are corrupted when using F11
Databases created by MySQL v4 are corrupted when using F11
Status: CLOSED ERRATA
Product: Fedora
Classification: Fedora
Component: mysql (Show other bugs)
11
All Linux
low Severity medium
: ---
: ---
Assigned To: Tom Lane
Fedora Extras Quality Assurance
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2009-06-22 04:33 EDT by Simon Andrews
Modified: 2013-07-02 23:23 EDT (History)
3 users (show)

See Also:
Fixed In Version: 5.1.35-1.fc11
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2009-06-24 15:31:27 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Simon Andrews 2009-06-22 04:33:28 EDT
Description of problem:
There is a problem with the mysql_upgrade program where it is failing to update tables created with mysql v4 such that they appear corrupted can can't be accessed within v5.1


Version-Release number of selected component (if applicable):
mysql-5.1.32-1.fc11

How reproducible:
Not sure - but many people have seen this.  There are reproducible test cases available

Steps to Reproduce:
1. Create a database in mysql v4
2. Update mysql to 5.1
3. Run mysqlcheck on the database
  
Actual results:
Errors such as:

warning  : Table is marked as crashed
warning  : Size of indexfile is: 1975296      Should be: 1572864
error    : Found key at page 180224 that points to record outside datafile
error    : Corrupt
Error    : Incorrect key file for table 'Clone_hit'; try to repair it
error    : Corrupt

Repair table (even with use_frm) can't fix this, neither can isamchk.  Apparently it requires a dump from the old verion, completely deleting the files under /var/lib/mysql (apart from the mysql tables), and then a restore to get things working again.

This could potentially cause big problems.


Expected results:
Tables are upgraded properly from older versions.

Additional info:
There is an upstream report of this, which suggests that this is fixed in v5.1.35 but I've not been able to verify that this solves the problem and the bug page isn't exactly chock full of reports that it works.  The upstream bug is at:

http://bugs.mysql.com/bug.php?id=37631
Comment 1 Tom Lane 2009-06-22 09:33:49 EDT
Please add your comments to the existing upstream bug --- I am not in a position to fix this for you.
Comment 2 Simon Andrews 2009-06-22 09:43:31 EDT
I'll keep track of the upstream bug, but consider this a placeholder for a request to the patched version of mysql as soon as it's released.  

I'm sure others will be hitting this bug at some point so this should also hopefully be useful to point them to the upstream problem.
Comment 3 Tom Lane 2009-06-22 10:07:02 EDT
FWIW, 5.1.35 is in updates-testing now.
Comment 4 Simon Andrews 2009-06-22 10:47:23 EDT
5.1.35 fixes this problem for me.  Let me know if you want me to report this in the buildsystem to help get this pushed out.

Thanks!
Comment 5 Tom Lane 2009-06-22 11:09:54 EDT
Given that, I'll go ahead and mark it for stable --- it's been in testing a few days already.
Comment 6 Fedora Update System 2009-06-24 15:31:18 EDT
mysql-5.1.35-1.fc11 has been pushed to the Fedora 11 stable repository.  If problems still persist, please make note of it in this bug report.

Note You need to log in before you can comment on or make changes to this bug.