FS/XFS testing framework
 help / color / mirror / Atom feed
From: Mikulas Patocka <mpatocka@redhat.com>
To: Kent Overstreet <kent.overstreet@linux.dev>
Cc: "Darrick J. Wong" <djwong@kernel.org>,
	Zorro Lang <zlang@kernel.org>,
	fstests@vger.kernel.org
Subject: Re: [PATCH] generic/558: limit the number of spawned subprocesses
Date: Wed, 12 Jul 2023 19:59:07 +0200 (CEST)	[thread overview]
Message-ID: <173ce5a9-5494-3ac2-e121-63a838734e1c@redhat.com> (raw)
In-Reply-To: <20230712145252.35xgebxg4i4a6g7e@moria.home.lan>



On Wed, 12 Jul 2023, Kent Overstreet wrote:

> On Wed, Jul 12, 2023 at 12:10:05PM +0200, Mikulas Patocka wrote:
> > If we hit the limit of total open files, we already killed the system. At 
> > this point the user can't execute any program because executing a programs 
> > requires opening files.
> > 
> > I think that it is possible to setup cgroups so that a process inside a 
> > cgroup can't kill the machine by exhausting resources. But distributions 
> > don't do it. And they don't do it for a root user (the test runs under 
> > root).
> 
> When I looked at this test before I missed the fork bomb aspect - was
> just looking at the crazy numbers of pinned inodes (which is still a
> significant fraction of system memory, looking again...)
> 
> If we change bcachefs to not report a maximum number of inodes, might
> that be more in line with other filesystems? Or is it really just
> because bcachefs inodes are tiny?

I think that it's OK to report as many free inodes as it fits on the 
filesystem. I think it is not a bug - we should fix the test, not lie to 
make the test pass.

There is one misbehavior though. As the test allocates the inodes on 
bcachefs, the total number of inodes is decreasing. The other filesystems 
don't behave in this way and I think that bcachefs shouldn't change the 
total number of inodes too.

Mikulas


  reply	other threads:[~2023-07-12 18:00 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-07-11 15:51 [PATCH] generic/558: limit the number of spawned subprocesses Mikulas Patocka
2023-07-11 23:44 ` Darrick J. Wong
2023-07-12  1:09   ` Kent Overstreet
2023-07-12  5:15     ` Amir Goldstein
2023-07-12 10:10     ` Mikulas Patocka
2023-07-12 14:52       ` Kent Overstreet
2023-07-12 17:59         ` Mikulas Patocka [this message]
2023-07-12 18:35           ` Kent Overstreet
2023-07-12  9:57   ` Mikulas Patocka
2023-07-12 22:05     ` Darrick J. Wong
2023-07-12 18:40 ` Zorro Lang
2023-07-13  1:44   ` Theodore Ts'o
2023-07-13  1:48 ` Darrick J. Wong
2023-07-13 15:08   ` Mikulas Patocka

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=173ce5a9-5494-3ac2-e121-63a838734e1c@redhat.com \
    --to=mpatocka@redhat.com \
    --cc=djwong@kernel.org \
    --cc=fstests@vger.kernel.org \
    --cc=kent.overstreet@linux.dev \
    --cc=zlang@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