Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-2.2 required=3.0 tests=HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,USER_AGENT_SANE_1 autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id F0349CA9EAF for ; Thu, 24 Oct 2019 15:12:19 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id CC3862166E for ; Thu, 24 Oct 2019 15:12:19 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2409620AbfJXPMT (ORCPT ); Thu, 24 Oct 2019 11:12:19 -0400 Received: from mx2.suse.de ([195.135.220.15]:50154 "EHLO mx1.suse.de" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S2409599AbfJXPMT (ORCPT ); Thu, 24 Oct 2019 11:12:19 -0400 X-Virus-Scanned: by amavisd-new at test-mx.suse.de Received: from relay2.suse.de (unknown [195.135.220.254]) by mx1.suse.de (Postfix) with ESMTP id 95A72C213; Thu, 24 Oct 2019 15:12:17 +0000 (UTC) Received: by quack2.suse.cz (Postfix, from userid 1000) id EA9011E155F; Thu, 24 Oct 2019 17:12:16 +0200 (CEST) Date: Thu, 24 Oct 2019 17:12:16 +0200 From: Jan Kara To: "Theodore Y. Ts'o" Cc: Jan Kara , linux-ext4@vger.kernel.org Subject: Re: [PATCH 0/19 v3] ext4: Fix transaction overflow due to revoke descriptors Message-ID: <20191024151216.GQ31271@quack2.suse.cz> References: <20191003215523.7313-1-jack@suse.cz> <20191019191933.GA25841@mit.edu> <20191024130908.GO31271@quack2.suse.cz> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20191024130908.GO31271@quack2.suse.cz> User-Agent: Mutt/1.10.1 (2018-07-13) Sender: linux-ext4-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-ext4@vger.kernel.org On Thu 24-10-19 15:09:08, Jan Kara wrote: > On Sat 19-10-19 15:19:33, Theodore Y. Ts'o wrote: > > Hi Jan, > > > > I've tried applying this patch set against 5.4-rc3, and I'm finding a > > easily reproducible failure using: > > > > kvm-xfstests -c ext3conv ext4/039 > > > > It is the BUG_ON in fs/jbd2/commit.c, around line 570: > > > > J_ASSERT(commit_transaction->t_nr_buffers <= > > atomic_read(&commit_transaction->t_outstanding_credits)); > > > > The failure (with the obvious debugging printk added) is: > > > > ext4/039 [15:13:16][ 6.747101] run fstests ext4/039 at 2019-10 > > -19 15:13:16 > > [ 7.018766] Mounted ext4 file system at /vdc supports timestamps until 2038 ( > > 0x7fffffff) > > [ 8.227631] JBD2: t_nr_buffers 226, t_outstanding_credits=223 > > [ 8.229215] ------------[ cut here ]------------ > > [ 8.230249] kernel BUG at fs/jbd2/commit.c:573! > > ... > > > > The full log is attached (although the stack trace isn't terribly > > interesting, since this is being run out of kjournald2). > > Thanks! Somehow this escaped my testing although I thought I have run ext3 > configuration... Anyway we are reserving too few space in this case - with > some debugging added: > > [ 80.296029] t_buffers: 222, t_outstanding_credits: 219, > t_revoke_written: 23, t_revoke_reserved: 12, t_revoke_records_written > 11432, t_revoke_records_reserved 11432, revokes_per_block: 1020 > > Which is really puzzling because it would suggest that revokes_per_block is > actually wrong. Digging more into this. Yeah, ext4 was updating journal features in this case but j_revoke_records_per_block didn't get properly updated. Fixed now. Honza -- Jan Kara SUSE Labs, CR