xfs
[Top] [All Lists]

Re: [PATCH 2/2] xfs: avoid shutdown hang in xlog_wait()

To: Dave Chinner <david@xxxxxxxxxxxxx>
Subject: Re: [PATCH 2/2] xfs: avoid shutdown hang in xlog_wait()
From: Christoph Hellwig <hch@xxxxxxxxxxxxx>
Date: Sat, 24 Mar 2012 13:03:02 -0400
Cc: xfs@xxxxxxxxxxx
In-reply-to: <1332467263-12985-3-git-send-email-david@xxxxxxxxxxxxx>
References: <1332467263-12985-1-git-send-email-david@xxxxxxxxxxxxx> <1332467263-12985-3-git-send-email-david@xxxxxxxxxxxxx>
User-agent: Mutt/1.5.21 (2010-09-15)
On Fri, Mar 23, 2012 at 12:47:43PM +1100, Dave Chinner wrote:
> From: Dave Chinner <dchinner@xxxxxxxxxx>
> 
> When a shutdown is triggered from failing to find an item in the AIL
> during delete, we can be called from either metadata IO completion
> context or from log IO completion context. In the case of log IO
> completion context, we must indicate that this is a log error so
> that the forced shutdown does not attempt to flush the log.
> 
> To flush the log whilst in log IO completion will cause a deadlock
> as the shutdown won't proceed until log IO completes, and log Io
> cannot complete because it has blocked waiting for itself to
> complete....
> 
> We delete items in the AIL from log IO completion when we are
> unpinning in-memory only items, or items that do not require
> writeback to remove from the AIL (e.g. EFI/EFD items). Hence there
> are several locations that need this treatment.

Looks good.  I wonder if it might be simple to simply pass a flags
argument to xfs_ail_delete(_bulk) which tells which kind of shutdown
to do.

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