[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <2583800.1585756303@warthog.procyon.org.uk>
Date: Wed, 01 Apr 2020 16:51:43 +0100
From: David Howells <dhowells@...hat.com>
To: Miklos Szeredi <miklos@...redi.hu>
Cc: dhowells@...hat.com, Ian Kent <raven@...maw.net>,
Linus Torvalds <torvalds@...ux-foundation.org>,
Al Viro <viro@...iv.linux.org.uk>,
Linux NFS list <linux-nfs@...r.kernel.org>,
Andreas Dilger <adilger.kernel@...ger.ca>,
Anna Schumaker <anna.schumaker@...app.com>,
"Theodore Ts'o" <tytso@....edu>,
Linux API <linux-api@...r.kernel.org>,
linux-ext4@...r.kernel.org,
Trond Myklebust <trond.myklebust@...merspace.com>,
Miklos Szeredi <mszeredi@...hat.com>,
Christian Brauner <christian@...uner.io>,
Jann Horn <jannh@...gle.com>,
"Darrick J. Wong" <darrick.wong@...cle.com>,
Karel Zak <kzak@...hat.com>, Jeff Layton <jlayton@...hat.com>,
linux-fsdevel@...r.kernel.org,
LSM <linux-security-module@...r.kernel.org>,
linux-kernel@...r.kernel.org
Subject: Re: [PATCH 00/13] VFS: Filesystem information [ver #19]
Miklos Szeredi <miklos@...redi.hu> wrote:
> For 30000 mounts, f= 146400us f2= 136766us p= 1406569us p2=
> 221669us; p=9.6*f p=10.3*f2 p=6.3*p2
f = 146400us
f2= 136766us
p = 1406569us <--- Order of magnitude slower
p2= 221669us
And more memory used because it's added a whole bunch of inodes and dentries
to the cache. For each mount that's a pair for each dir and a pair for each
file within the dir. So for the two files my test is reading, for 30000
mounts, that's 90000 dentries and 90000 inodes in mountfs alone.
(gdb) p sizeof(struct dentry)
$1 = 216
(gdb) p sizeof(struct inode)
$2 = 696
(gdb) p (216*696)*30000*3/1024/1024
$3 = 615
so 615 MiB of RAM added to the caches in an extreme case.
We're seeing customers with 10000+ mounts - that would be 205 MiB, just to
read two values from each mount.
I presume you're not going through /proc/fdinfo each time as that would add
another d+i - for >1GiB added to the caches for 30000 mounts.
David
Powered by blists - more mailing lists