[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CA+55aFzyUb07Lt251bzi4T79oB=M8uypFQ2m__FgnRJUauqd0Q@mail.gmail.com>
Date: Mon, 2 Jul 2018 15:54:04 -0700
From: Linus Torvalds <torvalds@...ux-foundation.org>
To: James Bottomley <James.Bottomley@...senpartnership.com>
Cc: Andrew Morton <akpm@...ux-foundation.org>,
Waiman Long <longman@...hat.com>,
Al Viro <viro@...iv.linux.org.uk>,
Linux Kernel Mailing List <linux-kernel@...r.kernel.org>,
linux-fsdevel <linux-fsdevel@...r.kernel.org>,
Jan Kara <jack@...e.cz>,
Paul McKenney <paulmck@...ux.vnet.ibm.com>,
Ingo Molnar <mingo@...nel.org>,
Miklos Szeredi <mszeredi@...hat.com>,
Matthew Wilcox <willy@...radead.org>,
Larry Woodman <lwoodman@...hat.com>,
"Wangkai (Kevin,C)" <wangkai86@...wei.com>,
linux-mm <linux-mm@...ck.org>, Michal Hocko <mhocko@...nel.org>
Subject: Re: [PATCH v5 0/6] fs/dcache: Track & limit # of negative dentries
On Mon, Jul 2, 2018 at 3:34 PM James Bottomley
<James.Bottomley@...senpartnership.com> wrote:
>
> There are still a lot of applications that keep looking up non-existent
> files, so I think it's still beneficial to keep them. Apparently
> apache still looks for a .htaccess file in every directory it
> traverses, for instance.
.. or git looking for ".gitignore" files in every directory, or any
number of similar things.
Lookie here, for example:
[torvalds@i7 linux]$ strace -e trace=%file -c git status
On branch master
Your branch is up to date with 'origin/master'.
nothing to commit, working tree clean
% time seconds usecs/call calls errors syscall
------ ----------- ----------- --------- --------- ----------------
73.23 0.009066 2 4056 6 open
23.33 0.002888 2 1294 1189 openat
1.60 0.000198 13 15 8 access
0.80 0.000099 2 36 31 lstat
0.53 0.000066 1 40 6 stat
0.27 0.000033 8 4 getcwd
0.11 0.000014 14 1 execve
0.11 0.000014 14 1 chdir
0.02 0.000003 3 1 1 readlink
0.00 0.000000 0 1 unlink
------ ----------- ----------- --------- --------- ----------------
100.00 0.012381 5449 1241 total
so almost a quarter (1241 of 5449) of the file accesses resulted in
errors (and I think they are all ENOENT).
Negative lookups are *not* some unusual thing.
Linus
Powered by blists - more mailing lists