xfs
[Top] [All Lists]

Re: Review: freezing sometimes leaves the log dirty

To: David Chinner <dgc@xxxxxxx>
Subject: Re: Review: freezing sometimes leaves the log dirty
From: Donald Douwsma <donaldd@xxxxxxx>
Date: Thu, 01 Feb 2007 17:52:18 +1100
Cc: xfs-dev@xxxxxxx, xfs@xxxxxxxxxxx
In-reply-to: <20070130220326.GM33919298@xxxxxxxxxxxxxxxxx>
References: <20070130220326.GM33919298@xxxxxxxxxxxxxxxxx>
Sender: xfs-bounce@xxxxxxxxxxx
User-agent: Thunderbird 1.5.0.9 (X11/20070103)
Hi Dave,

It looks good to me.

Donald

David Chinner wrote:
> When we freeze the filesystem on a system that is under
> heavy load, the fleeze can complete it's flushes while there
> are still transactions active. Hence the freeze completes
> with a dirty log and dirty metadata buffers still in memory.
> 
> The Linux freeze path is a tangled mess - I had to go back
> to the irix code to work out exactly what we should be doing
> to work out why the linux code was failing because of
> the convoluted paths the linux code takes through the
> generic layers.
> 
> In short, when we freeze the writes, we should not be
> quiescing the filesystem at this point. All we should
> be doing is a blocking data sync because we haven't shut down
> the transaction subsystem yet. We also need to wait
> for all direct I/O writes to complete as well.
> 
> Once the data sync is complete, we can return to the generic
> code for it to freeze new transactions. Then we can wait for
> all active transactions to complete before we quiesce the
> filesystem which flushes out all the dirty metadata buffers.
> 
> At this point we have a clean filesystem and an empty log
> so we can safely write the unmount record followed by a
> dummy record to dirty the log to ensure unlinked list
> processing on remount if we crash or shut down the machine
> while the filesystem is frozen.
> 
> Comments?
> 
> Cheers,
> 
> Dave.


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