From: Boaz Harrosh <bharrosh@panasas.com>
To: Nick Piggin <npiggin@kernel.dk>
Cc: linux-fsdevel@vger.kernel.org, linux-kernel@vger.kernel.org,
linux-ext4@vger.kernel.org, Roman Zippel <zippel@linux-m68k.org>,
"Tigran A. Aivazian" <tigran@aivazian.fsnet.co.uk>,
OGAWA Hirofumi <hirofumi@mail.parknet.co.jp>,
Dave Kleikamp <shaggy@linux.vnet.ibm.com>,
Bob Copeland <me@bobcopeland.com>,
reiserfs-devel@vger.kernel.org,
Christoph Hellwig <hch@infradead.org>,
Evgeniy Dushistov <dushistov@mail.ru>, Jan Kara <jack@suse.cz>
Subject: Re: [RFC][PATCH] Possible data integrity problems in lots of filesystems?
Date: Thu, 25 Nov 2010 14:18:30 +0200 [thread overview]
Message-ID: <4CEE5416.4020904@panasas.com> (raw)
In-Reply-To: <20101125114711.GA3622@amd>
On 11/25/2010 01:47 PM, Nick Piggin wrote:
> On Thu, Nov 25, 2010 at 12:51:11PM +0200, Boaz Harrosh wrote:
>
> It does not get it right, because of the situation I described
> above. Background writeout can come in first, and clear the inode
> dirty bits, and call your ->write_inode for async writeout.
>
> That means you skip doing the exofs_put_io_state(), and (I presume)
> this means you aren't waiting for write completion there.
>
> What then happens is that sync_inode_metadata() from your fsync
> does not call ->write_inode because the inode dirty bits are clear.
> It's basically a noop. So you need to either make your .write_inode
> always synchronous, or wait for it in your .fsync and .sync_fs.
>
Rrr I now see what you mean, that the previous call to
writeback_single_inode(wait==0) came and go without actually
finishing because exofs_write_inode(wait==0).
So I wish there was an
write_inode_async_done() that will actually do the final inode_sync_complete
or something like that, right? (That I could call from exofs::updatei_done)
Sigh. I think I'll go with the always wait==1 at exofs_write_inode() for
now. Just as your patch.
If there is nothing better by the next Kernel I might consider my own
wait_event() in exofs_file_fsync()
ACK-by: Boaz Harrosh <bharrosh@panasas.com>
Thanks
Boaz
next prev parent reply other threads:[~2010-11-25 12:18 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-11-25 7:49 [RFC][PATCH] Possible data integrity problems in lots of filesystems? Nick Piggin
2010-11-25 9:28 ` Boaz Harrosh
2010-11-25 10:06 ` Nick Piggin
2010-11-25 10:51 ` Boaz Harrosh
2010-11-25 10:52 ` [PATCH] exofs: simple fsync race fix Boaz Harrosh
2010-11-25 11:50 ` Nick Piggin
2011-02-03 11:44 ` Boaz Harrosh
2010-11-25 11:47 ` [RFC][PATCH] Possible data integrity problems in lots of filesystems? Nick Piggin
2010-11-25 12:18 ` Boaz Harrosh [this message]
2010-11-25 11:54 ` Nick Piggin
2010-11-25 12:01 ` Christoph Hellwig
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=4CEE5416.4020904@panasas.com \
--to=bharrosh@panasas.com \
--cc=dushistov@mail.ru \
--cc=hch@infradead.org \
--cc=hirofumi@mail.parknet.co.jp \
--cc=jack@suse.cz \
--cc=linux-ext4@vger.kernel.org \
--cc=linux-fsdevel@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=me@bobcopeland.com \
--cc=npiggin@kernel.dk \
--cc=reiserfs-devel@vger.kernel.org \
--cc=shaggy@linux.vnet.ibm.com \
--cc=tigran@aivazian.fsnet.co.uk \
--cc=zippel@linux-m68k.org \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.