[Top] [All Lists]

Re: [PATCH] xfs: dummy transactions should not dirty VFS state

To: Christoph Hellwig <hch@xxxxxxxxxxxxx>
Subject: Re: [PATCH] xfs: dummy transactions should not dirty VFS state
From: Dave Chinner <david@xxxxxxxxxxxxx>
Date: Tue, 3 Aug 2010 22:07:28 +1000
Cc: xfs@xxxxxxxxxxx
In-reply-to: <20100803095518.GA27470@xxxxxxxxxxxxx>
References: <1280826605-3506-1-git-send-email-david@xxxxxxxxxxxxx> <20100803095518.GA27470@xxxxxxxxxxxxx>
User-agent: Mutt/1.5.20 (2009-06-14)
On Tue, Aug 03, 2010 at 05:55:18AM -0400, Christoph Hellwig wrote:
> I looks good to me, but there are two subtile differences between
> xfs_commit_dummy_trans and xfs_fs_log_dummy that get lost. 

Yes, I noticed those things. Especially as I modified the wrong
one in the first place and realised both need fixing and the
duplication of code seems completely unnecessary. We should have
only one copy of this code, not two copies that do slightly
different things.

> For one
> xfs_commit_dummy_trans doesn't actually commit a synchronous transaction
> (or rather forces out the log) unless SYNC_WAIT is set,

I don't think that we really _need_ a non-blocking version - waiting
for a single sync transaction in xfssyncd once every 36s is hardly
going to kill performance.

> in addition
> to that xfs_fs_log_dummy uses _xfs_trans_alloc, which doesn't get
> blocked by the filesystem freezing.

Everything will be clean on a frozen filesystem, so all the current
code does is block the xfssyncd until the filesytem is
unfrozen. Given that we can still read everything on the frozen
filesystem, inode caches can still grow and hence we still need to
run regular reclaiming. If the xfssyncd is blocked then only memory
pressure can free up inodes.

If we want to keep all these little differences, then we still
need to kill one of the two versions. Let me know which you


Dave Chinner

<Prev in Thread] Current Thread [Next in Thread>