Re: [PATCH 4/5] ext4: flush journal when switching from journal data mode

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Fri, Dec 30, 2011 at 5:01 AM, Darrick J. Wong <djwong@xxxxxxxxxx> wrote:
> On Wed, Dec 28, 2011 at 01:56:43PM -0500, Ted Ts'o wrote:
>> On Tue, Nov 15, 2011 at 04:07:53PM +0800, Yongqiang Yang wrote:
>> > When switching from journal data mode, the data blocks
>> > in journal will have no revoke record.  Thus, data could be
>> > corrupted during replay.  However, there is no such problem in
>> > switching to journal data mode.  So we flush journal only in
>> > the case that swithes from journal data mode.
>> >
>> > Signed-off-by: Yongqiang Yang <xiaoqiangnk@xxxxxxxxx>
>>
>> Applied, with a slightly different (and more explanatory commit
>> message):
>>
>> ext4: flush journal when switching from data=journal mode
>>
>> From: Yongqiang Yang <xiaoqiangnk@xxxxxxxxx>
>>
>> It's necessary to flush the journal when switching away from
>> data=journal mode.  This is because there are no revoke records when
>> we are data blocks are journalled,
>
> Minor nit, but did you mean "when data blocks are journalled" ?
Yes!  chattr +j can change journal mode of a file to data mode.

Yongqiang.
>
> --D
>> which are required in the other journal modes.
>>
>> However, it is not necessary to flush the journal when switching into
>> data=journal mode, and flushing the journal is expensive.  So let's
>> avoid it in that case.
>>
>> Signed-off-by: Yongqiang Yang <xiaoqiangnk@xxxxxxxxx>
>> Signed-off-by: "Theodore Ts'o" <tytso@xxxxxxx>
>>
>>                                               - Ted
>> --
>> To unsubscribe from this list: send the line "unsubscribe linux-ext4" in
>> the body of a message to majordomo@xxxxxxxxxxxxxxx
>> More majordomo info at  http://vger.kernel.org/majordomo-info.html
>>
>



-- 
Best Wishes
Yongqiang Yang
--
To unsubscribe from this list: send the line "unsubscribe linux-ext4" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Reiser Filesystem Development]     [Ceph FS]     [Kernel Newbies]     [Security]     [Netfilter]     [Bugtraq]     [Linux FS]     [Yosemite National Park]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Samba]     [Device Mapper]     [Linux Media]

  Powered by Linux