public inbox for linux-ext4@vger.kernel.org
 help / color / mirror / Atom feed
From: "Lukáš Czerner" <lczerner@redhat.com>
To: tytso@mit.edu
Cc: Lubos Uhliarik <uhliarik@seznam.cz>,
	linux-ext4@vger.kernel.org, vojnar@fit.vutbr.cz
Subject: Re: [RFC][PATCH 0/1] ext4: Undelete Feature for Ext4
Date: Tue, 18 Mar 2014 18:28:34 +0100 (CET)	[thread overview]
Message-ID: <alpine.LFD.2.00.1403181820220.2121@localhost.localdomain> (raw)
In-Reply-To: <20140318171425.GC8506@thunk.org>

On Tue, 18 Mar 2014, tytso@mit.edu wrote:

> Date: Tue, 18 Mar 2014 13:14:26 -0400
> From: tytso@mit.edu
> To: Lubos Uhliarik <uhliarik@seznam.cz>
> Cc: linux-ext4@vger.kernel.org, lczerner@redhat.com, vojnar@fit.vutbr.cz
> Subject: Re: [RFC][PATCH 0/1] ext4: Undelete Feature for Ext4
> 
> On Tue, Mar 18, 2014 at 04:09:30PM +0100, Lubos Uhliarik wrote:
> > The main changes in patch are following:
> > 
> > a) commented out zeroing ex->ee_len, ee->start_hi and ee->start_lo,
> > because these entries are essential for undelete process
> 
> The reason why we have to zero out ex->ee_len, etc. is because the
> truncate operation can sometimes span multiple journal transactions.
> So as a result, we need to keep the file system consistent if we are
> interrupted (i.e., via a power fail event) while in the middle of a
> truncate operation.
> 
> It's a rare case, but it can happen if the journal is almost full at
> the time when the truncate eoperation has started, such that there is
> no room for to exntend the transaction handle, and so we are forced to
> start a new transaction (and possibly wait for a journal checkpoint
> operation).
> 
> In theory, it would be possible to figure out in advance whether or
> not we could fit the truncate in a single transaction, but it would
> require making the truncate operation be a two-pass operation --- once
> to determine how many blocks needs to be modified, and once to
> actually do the truncate operation.

Hi Lubos,

that's what we've been discussing including the power failure
testing. Have you managed to make a power failure test for this ? I
kind of forgot to ask you about that today.

Also, if I recall correctly you mentioned that we should be ok with
the respect of power failure in the middle of truncate, but I do not
recall the details, can you try to look into that again ?

Thanks!
-Lukas

> 
> > This patch shouldn't break ext4, I tested it with xfs_tests and tests 
> > were successfull.
> 
> I'm guessing you didn't do power fail testing --- and this is very
> important when messing with the design truncate/unlink code path.
> 
> Regards,
> 
> 						- Ted
> 

  reply	other threads:[~2014-03-18 17:28 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-03-18 15:09 [RFC][PATCH 0/1] ext4: Undelete Feature for Ext4 Lubos Uhliarik
2014-03-18 17:14 ` tytso
2014-03-18 17:28   ` Lukáš Czerner [this message]
2014-04-18 16:01   ` Lubos Uhliarik
2014-05-08 21:11   ` Lubos Uhliarik

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=alpine.LFD.2.00.1403181820220.2121@localhost.localdomain \
    --to=lczerner@redhat.com \
    --cc=linux-ext4@vger.kernel.org \
    --cc=tytso@mit.edu \
    --cc=uhliarik@seznam.cz \
    --cc=vojnar@fit.vutbr.cz \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox