public inbox for linux-xfs@vger.kernel.org
 help / color / mirror / Atom feed
From: "Darrick J. Wong" <djwong@kernel.org>
To: Christoph Hellwig <hch@lst.de>
Cc: linux-xfs@vger.kernel.org
Subject: Re: RFC: don't allow disabling quota accounting on a mounted file system
Date: Tue, 20 Apr 2021 10:36:34 -0700	[thread overview]
Message-ID: <20210420173634.GO3122264@magnolia> (raw)
In-Reply-To: <20210420072256.2326268-1-hch@lst.de>

On Tue, Apr 20, 2021 at 09:22:54AM +0200, Christoph Hellwig wrote:
> Hi all,
> 
> disabling quota accounting (vs just enforcement) on a running file system
> is a fundamentally race and hard to get right operation.  It also has
> very little practical use.
> 
> This causes xfs/007 xfs/106 xfs/220 xfs/304 xfs/305 to fail, as they
> specifically test this functionality.

What kind of failures do you get now?  Are they all a result of the
_ACCT flags never going away?  Which I guess means that tests expecting
to get ENOSYS after you turn off _ACCT will now no longer error out?

I've been wondering recently why we can't just apply "xfs: skip dquot
reservations if quota is inactive" and change dqpurge_all to relog the
quotaoff item if !xfs_log_item_in_current_chkpt to prevent tail pinning.
AFAICT we can log a qoffend and a new qoff (just like we do with regular
intents) and it won't have any bad effect on recovery.

--D

> 
> Note that the quotaitem log recovery code is left for to make sure we
> don't increase inconsistent recovery states.
> 
> Diffstat:
>  libxfs/xfs_quota_defs.h |   30 ----
>  libxfs/xfs_trans_resv.c |   30 ----
>  libxfs/xfs_trans_resv.h |    2 
>  scrub/quota.c           |    2 
>  xfs_dquot.c             |    3 
>  xfs_dquot_item.c        |  134 ---------------------
>  xfs_dquot_item.h        |   17 --
>  xfs_ioctl.c             |    2 
>  xfs_iops.c              |    4 
>  xfs_mount.c             |    4 
>  xfs_qm.c                |   28 ++--
>  xfs_qm.h                |    4 
>  xfs_qm_syscalls.c       |  300 ------------------------------------------------
>  xfs_quotaops.c          |   57 +++++----
>  xfs_super.c             |   51 +++-----
>  xfs_trans_dquot.c       |   49 -------
>  16 files changed, 84 insertions(+), 633 deletions(-)

  parent reply	other threads:[~2021-04-20 17:36 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-04-20  7:22 RFC: don't allow disabling quota accounting on a mounted file system Christoph Hellwig
2021-04-20  7:22 ` [PATCH 1/2] xfs: remove support for " Christoph Hellwig
2021-04-22 14:18   ` [xfs] 44349bf9f5: xfstests.xfs.305.fail kernel test robot
2021-04-26 15:06   ` [PATCH 1/2] xfs: remove support for disabling quota accounting on a mounted file system Brian Foster
2021-04-20  7:22 ` [PATCH 2/2] xfs: remove the active vs running quota differentiation Christoph Hellwig
2021-04-20 17:36 ` Darrick J. Wong [this message]
2021-04-21  6:26   ` RFC: don't allow disabling quota accounting on a mounted file system Christoph Hellwig

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20210420173634.GO3122264@magnolia \
    --to=djwong@kernel.org \
    --cc=hch@lst.de \
    --cc=linux-xfs@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox