[lkml]   [2005]   [Oct]   [19]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
Patch in this message
SubjectWarning: Serious NTFS data corruption bug! + Fix! - Was: Re: ntfs CFT - was: Re: 2.6.14-rc4-mm1

To all: There is serious data corruption issue with ntfs in
2.6.14-rc4-mm1 (and ntfs 2.1.25 release in general, not just -mm). Fix
is below. Hopefully this is the only bug!

On Tue, 2005-10-18 at 12:48 -0500, Alberto Patino wrote:
> On 10/18/05, Alberto Patino <> wrote:
> > Hi Anton, not too lucky doing modifications with soffice to word documents.
> > Saving files is ok but when I reopen the files, the format is lost...
> > I'll try to recover them from Word.exe
> Anton:
> I'm afraid I have bad news, I couldn't boot W2K, I got this message
> translated fom spanish:
> STOP: C0000221 { checksum image test incorrect }
> Something weird, I edited txt file A with vim, then I edited Word File
> B with soffice, I close it, then I reopened. I lost format so the file
> is not legible but I can see paragraphs from file A in file B!!!!!

I am really sorry about this. )-: You should be able to hopefully fix
windows by booting with the installation CD and going into recovery
console and running chkdsk on the partition. You can also try running
ntfsfix from ntfsprogs and then booting into windows. This may be
sufficient to allow it to do a chkdsk on the partition before it

I found a bug that caused corruption of the openoffice document as you
described. The fix is below.

diff -urNp /usr/src/ntfs-2.6-devel/fs/ntfs/file.c ntfs26dev/file.c
--- /usr/src/ntfs-2.6-devel/fs/ntfs/file.c 2005-10-11 15:00:00.000000000 +0100
+++ ntfs26dev/file.c 2005-10-19 11:50:54.859558000 +0100
@@ -787,6 +787,7 @@ retry_remap:
vcn_len = rl[1].vcn - vcn;
lcn_block = lcn << (vol->cluster_size_bits -
+ cdelta = 0;
* If the number of remaining clusters in the
* @pages is smaller or equal to the number of
Thank you very much for testing and I am really sorry it caused the
corruption to your partition. In the future I will make sure to say
"Please only test on test partitions."...

Best regards,

Anton Altaparmakov <aia21 at> (replace at with @)
Unix Support, Computing Service, University of Cambridge, CB2 3QH, UK
Linux NTFS maintainer / IRC: #ntfs on
WWW: &

To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to
More majordomo info at
Please read the FAQ at

 \ /
  Last update: 2005-10-19 13:12    [W:0.191 / U:1.440 seconds]
©2003-2018 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site