linux-btrfs.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: David Sterba <dsterba@suse.cz>
To: Greed Rong <greedrong@gmail.com>
Cc: dsterba@suse.cz, Qu Wenruo <quwenruo.btrfs@gmx.com>,
	linux-btrfs@vger.kernel.org
Subject: Re: BTRFS: Transaction aborted (error -24)
Date: Fri, 12 Jun 2020 19:13:15 +0200	[thread overview]
Message-ID: <20200612171315.GW27795@twin.jikos.cz> (raw)
In-Reply-To: <CA+UqX+OcP_S6U37BHkGgzyDVNAud5vYOucL_WpNLhfU-T=+Vnw@mail.gmail.com>

On Fri, Jun 12, 2020 at 11:15:43AM +0800, Greed Rong wrote:
> This server is used for network storage. When a new client arrives, I
> create a snapshot of the workspace subvolume for this client. And
> delete it when the client disconnects.

NFS, cephfs and overlayfs use the same pool of ids, in combination with
btrfs snapshots the consumption might be higher than in other setups.

> Most workspaces are PC game programs. It contains thousands of files
> and Its size ranges from 1GB to 20GB.

We can rule out regular files, they don't affect that, and the numbers
you posted are all normal.

> About 200 windows clients access this server through samba. About 20
> snapshots create/delete in one minute.

This is contributing to the overall consumption of the ids from the
pool, but now it's shared among the network filesystem and btrfs.

Possible explanation would be leak of the ids, once this state is hit
it's permament so no new snapshots could be created or the network
clients will start getting some other error.

If there's no leak, then all objects that have the id attached would
need to be active, ie. snapshot part of a path, network client
connected to it's path. This also means some sort of caching, so the ids
are not returned back right away.

For the subvolumes the ids get returned once the subvolume is deleted
and cleaned, which might take time and contribute to the pool
exhaustion. I need to do some tests to see if we could release the ids
earlier.

  parent reply	other threads:[~2020-06-12 17:13 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-06-11 10:29 BTRFS: Transaction aborted (error -24) Greed Rong
2020-06-11 11:20 ` David Sterba
2020-06-11 12:37   ` Qu Wenruo
2020-06-11 13:52     ` David Sterba
2020-06-12  3:15       ` Greed Rong
2020-06-12  6:41         ` Qu Wenruo
2020-06-12 17:13         ` David Sterba [this message]
2020-06-15 12:50           ` Greed Rong
2020-06-16  0:38             ` Qu Wenruo
2020-06-18 12:34             ` David Sterba
2020-06-19  4:04               ` Greed Rong
2020-06-19  4:41                 ` Qu Wenruo
2020-06-12  5:38       ` Qu Wenruo

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=20200612171315.GW27795@twin.jikos.cz \
    --to=dsterba@suse.cz \
    --cc=greedrong@gmail.com \
    --cc=linux-btrfs@vger.kernel.org \
    --cc=quwenruo.btrfs@gmx.com \
    /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;
as well as URLs for NNTP newsgroup(s).