Re: [Cluster-devel] gfs2 iomap dealock, IOMAP_F_UNBALANCED

2019-04-09 Thread Andreas Gruenbacher
On Tue, 9 Apr 2019 at 14:15, Christoph Hellwig wrote: > On Mon, Apr 08, 2019 at 03:44:05PM +0200, Jan Kara wrote: > > > We won't be able to do a log flush while another transaction is > > > active, but that's what's needed to clean dirty pages. iomap doesn't > > > allow us to put the block

Re: [Cluster-devel] gfs2 iomap dealock, IOMAP_F_UNBALANCED

2019-04-09 Thread Christoph Hellwig
On Mon, Apr 08, 2019 at 03:44:05PM +0200, Jan Kara wrote: > > We won't be able to do a log flush while another transaction is > > active, but that's what's needed to clean dirty pages. iomap doesn't > > allow us to put the block allocation into a separate transaction from > > the page writes; for

Re: [Cluster-devel] gfs2 iomap dealock, IOMAP_F_UNBALANCED

2019-04-08 Thread Jan Kara
On Mon 08-04-19 10:53:34, Andreas Gruenbacher wrote: > On Sun, 7 Apr 2019 at 09:32, Christoph Hellwig wrote: > > > > [adding Jan and linux-mm] > > > > On Fri, Mar 29, 2019 at 11:13:00PM +0100, Andreas Gruenbacher wrote: > > > > But what is the requirement to do this in writeback context? Can't >

Re: [Cluster-devel] gfs2 iomap dealock, IOMAP_F_UNBALANCED

2019-04-08 Thread Andreas Gruenbacher
On Sun, 7 Apr 2019 at 09:32, Christoph Hellwig wrote: > > [adding Jan and linux-mm] > > On Fri, Mar 29, 2019 at 11:13:00PM +0100, Andreas Gruenbacher wrote: > > > But what is the requirement to do this in writeback context? Can't > > > we move it out into another context instead? > > > > Indeed,

Re: [Cluster-devel] gfs2 iomap dealock, IOMAP_F_UNBALANCED

2019-04-07 Thread Christoph Hellwig
[adding Jan and linux-mm] On Fri, Mar 29, 2019 at 11:13:00PM +0100, Andreas Gruenbacher wrote: > > But what is the requirement to do this in writeback context? Can't > > we move it out into another context instead? > > Indeed, this isn't for data integrity in this case but because the > dirty

Re: [Cluster-devel] gfs2 iomap dealock, IOMAP_F_UNBALANCED

2019-03-29 Thread Andreas Gruenbacher
On Thu, 28 Mar 2019 at 17:51, Christoph Hellwig wrote: > On Thu, Mar 21, 2019 at 02:13:04PM +0100, Andreas Gruenbacher wrote: > > Hi Christoph, > > > > we need your help fixing a gfs2 deadlock involving iomap. What's going > > on is the following: > > > > * During iomap_file_buffered_write,

Re: [Cluster-devel] gfs2 iomap dealock, IOMAP_F_UNBALANCED

2019-03-28 Thread Christoph Hellwig
On Thu, Mar 21, 2019 at 02:13:04PM +0100, Andreas Gruenbacher wrote: > Hi Christoph, > > we need your help fixing a gfs2 deadlock involving iomap. What's going > on is the following: > > * During iomap_file_buffered_write, gfs2_iomap_begin grabs the log flush > lock and keeps it until

Re: [Cluster-devel] gfs2 iomap dealock, IOMAP_F_UNBALANCED

2019-03-27 Thread Ross Lagerwall
On 3/22/19 12:21 AM, Andreas Gruenbacher wrote: On Fri, 22 Mar 2019 at 00:01, Andreas Gruenbacher wrote: On Thu, 21 Mar 2019 at 22:43, Dave Chinner wrote: The problem is calling balance_dirty_pages() inside the ->iomap_begin/->iomap_end calls and not that it is called by the iomap

Re: [Cluster-devel] gfs2 iomap dealock, IOMAP_F_UNBALANCED

2019-03-21 Thread Andreas Gruenbacher
On Fri, 22 Mar 2019 at 00:01, Andreas Gruenbacher wrote: > On Thu, 21 Mar 2019 at 22:43, Dave Chinner wrote: > > The problem is calling balance_dirty_pages() inside the > > ->iomap_begin/->iomap_end calls and not that it is called by the > > iomap infrastructure itself, right? > > > > Is so, I'd

Re: [Cluster-devel] gfs2 iomap dealock, IOMAP_F_UNBALANCED

2019-03-21 Thread Andreas Gruenbacher
On Thu, 21 Mar 2019 at 22:43, Dave Chinner wrote: > The problem is calling balance_dirty_pages() inside the > ->iomap_begin/->iomap_end calls and not that it is called by the > iomap infrastructure itself, right? > > Is so, I'd prefer to see this in iomap_apply() after the call to >

Re: [Cluster-devel] gfs2 iomap dealock, IOMAP_F_UNBALANCED

2019-03-21 Thread Dave Chinner
On Thu, Mar 21, 2019 at 02:13:04PM +0100, Andreas Gruenbacher wrote: > Hi Christoph, > > we need your help fixing a gfs2 deadlock involving iomap. What's going > on is the following: > > * During iomap_file_buffered_write, gfs2_iomap_begin grabs the log flush > lock and keeps it until

[Cluster-devel] gfs2 iomap dealock, IOMAP_F_UNBALANCED

2019-03-21 Thread Andreas Gruenbacher
Hi Christoph, we need your help fixing a gfs2 deadlock involving iomap. What's going on is the following: * During iomap_file_buffered_write, gfs2_iomap_begin grabs the log flush lock and keeps it until gfs2_iomap_end. It currently always does that even though there is no point other than