[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <CAOiN93kaujMhfiF6m4+SrUW7jZjJE-GY_6SAba72-XAaea0rjw@mail.gmail.com>
Date: Mon, 10 Dec 2012 11:52:39 +0530
From: Ashish Sangwan <ashishsangwan2@...il.com>
To: Forrest Liu <forrestl@...ology.com>
Cc: "Theodore Ts'o" <tytso@....edu>,
ext4 development <linux-ext4@...r.kernel.org>,
Eric Sandeen <sandeen@...hat.com>
Subject: Re: [PATCH] ext4: fix extent tree corruption that incurred by hole punch
> Hi Ashish,
>
> First, create a file lager than 4GB, and then punch out every even blocks;
> Use ex command in debugfs to dump extents, belowing is the result.
>
> Level Entries Logical Physical Length Flags
> 0/ 3 1/ 1 1 - 1048575 40013 1048575
> 1/ 3 1/ 5 1 - 231160 40012 231160
> 2/ 3 1/340 1 - 680 40011 680
> 3/ 3 1/340 1 - 1 2228225 - 2228225 1
> 3/ 3 2/340 3 - 3 2228227 - 2228227 1
> 3/ 3 3/340 5 - 5 2228229 - 2228229 1
>
>
> punch out 231159, 231157, ..., 1..
>
>
> Level Entries Logical Physical Length Flags
> 0/ 3 1/ 1 1 - 1048575 40013 1048575
> 1/ 3 1/ 4 231161 - 462320 2457604 231160
> 2/ 3 1/340 231161 - 231840 2457606 680
> 3/ 3 1/340 231161 - 231161 2459385 - 2459385 1
>
>
> Then, we get incorrect logical index, if only do correction in ext4_ext_rm_leaf.
Ok, In your patch we can do without varibale border and instead use:
path->p_idx->ei_block = (path+1)->p_idx->ei_block;
Rest of the patch seems Ok.
Thanks,
Ashish
>
>
> Thanks,
> Forrest
--
To unsubscribe from this list: send the line "unsubscribe linux-ext4" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Powered by blists - more mailing lists