archive mirror
 help / color / mirror / Atom feed
From: Miklos Szeredi <>
To: Miklos Szeredi <>,
	fuse-devel <>,
	linux-fsdevel <>
Subject: Re: [fuse-devel] [fuse] What happens with dirty pages on NOTIFY_INVAL_INODE?
Date: Mon, 24 Sep 2018 15:38:24 +0200	[thread overview]
Message-ID: <> (raw)
In-Reply-To: <>

On Mon, Sep 24, 2018 at 10:43 AM, Nikolaus Rath <> wrote:
> On Sep 24 2018, Miklos Szeredi <> wrote:
>> On Mon, Sep 24, 2018 at 10:06 AM, Nikolaus Rath <> wrote:
>>> Hi,
>>> What happens with dirty pages when a (writeback-cache enabled) FUSE
>>> filesystem sends a NOTIFY_INVAL_INODE request? Are they dropped?
>>> flushed?
>> Haven't tried, but AFAICS it flushes dirty pages and waits on
>> writeback for these.
> "waits on writeback" means "wait until the write requests have
> completed"?

Appears to be so.  An so there we have the blocking notification
you've asked about.

>> However, it doesn't wait on already queued
>> writes.  So it's a bit of a mess at the moment.
>>> To me neither behaviour seems correct...
>> What would be the correct operation be if neither flushing not
>> dropping them is correct?
> What about returning an error?
> My thinking is that if the filesystem issues an inval request, then the
> data has already been changed/disappeared. So a writeback at this point
> would most likely not do the right thing - since it would partially
> write back old data that has actually been mutated.
> Similarly, just dropping the cache seems bad because most likely this
> causes data loss for the new data that hasn't been flushed.

This is a pretty complicated issue.  For reference we should look at
what NFS is doing, because NFS has a long history and likely that
behavior is the most acceptable when cached writes are mixed with
concurrent remote updates.

And I don't think NFS will report an error in such a situation.   More
likely it will accept the reordered writes.


      reply	other threads:[~2018-09-24 19:40 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-09-24  8:06 [fuse] What happens with dirty pages on NOTIFY_INVAL_INODE? Nikolaus Rath
2018-09-24  8:22 ` Miklos Szeredi
2018-09-24  8:43   ` [fuse-devel] " Nikolaus Rath
2018-09-24 13:38     ` Miklos Szeredi [this message]

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:

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

  git send-email \ \ \ \ \

* 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;
as well as URLs for NNTP newsgroup(s).