From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-yb0-f196.google.com ([209.85.213.196]:35524 "EHLO mail-yb0-f196.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751096AbdFSR7h (ORCPT ); Mon, 19 Jun 2017 13:59:37 -0400 Received: by mail-yb0-f196.google.com with SMTP id g206so2984672yba.2 for ; Mon, 19 Jun 2017 10:59:36 -0700 (PDT) Date: Mon, 19 Jun 2017 13:59:34 -0400 From: Tejun Heo To: Christoph Hellwig Cc: Greg Kroah-Hartman , Linus Torvalds , linux-fsdevel@vger.kernel.org Subject: Re: odd sysfs find behavior, was: Re: [PATCH v6 00/10] Implement NVMe Namespace Descriptor Identification Message-ID: <20170619175934.GB12062@htj.duckdns.org> References: <20170616094056.GA12465@lst.de> <905ed2e6-1c1c-f3a3-5391-66e42fb61861@suse.de> <20170616095837.GA14217@lst.de> <20170617120814.GA13236@lst.de> <20170618011250.GA1987@kroah.com> <20170618073249.GA25797@lst.de> <20170618073305.GB25797@lst.de> <20170618102020.GA28042@htj.duckdns.org> <20170618134336.GA32701@lst.de> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20170618134336.GA32701@lst.de> Sender: linux-fsdevel-owner@vger.kernel.org List-ID: Hello, On Sun, Jun 18, 2017 at 03:43:36PM +0200, Christoph Hellwig wrote: > On Sun, Jun 18, 2017 at 06:20:20AM -0400, Tejun Heo wrote: > > If you "cd /sys/kernel/debug/tracing; cd -" before doing the find, > > does it succeed the first time? It could be that the on-demand > > mounting of tracefs is giving incoherent results across the mounting > > and confusing find. > > Yes, that works fine: > > root@testvm:~# cd /sys/kernel/debug/tracing; cd - > /root > root@testvm:~# find /sys -name uuid > /sys/devices/virtual/nvme-fabrics/ctl/nvme3/nvme3n1/uuid > /sys/devices/virtual/nvme-fabrics/ctl/nvme2/nvme2n1/uuid So, looks like this is the debugfs automount mechanism changing nlinks across automounts and confusing find in the process. Greg? Thanks. -- tejun