From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id A9402C4332F for ; Wed, 4 Jan 2023 12:24:04 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230250AbjADMYD (ORCPT ); Wed, 4 Jan 2023 07:24:03 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:49840 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230200AbjADMYC (ORCPT ); Wed, 4 Jan 2023 07:24:02 -0500 Received: from dfw.source.kernel.org (dfw.source.kernel.org [IPv6:2604:1380:4641:c500::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 978F8DC for ; Wed, 4 Jan 2023 04:24:01 -0800 (PST) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id 323896142C for ; Wed, 4 Jan 2023 12:24:01 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 21E8CC433EF; Wed, 4 Jan 2023 12:24:00 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1672835040; bh=cl8QEa+4LKO/Jvp4GMZ0+G8c9V8uH7Yl2lEg3tdTWa8=; h=Subject:From:To:Cc:Date:In-Reply-To:References:From; b=KoBaZp5qwNqtOZPQJ8q5FEEb0dORSKMLlXdhOranJu3k2EVwekLEVNO0wU3qLzYBF SxsOJNHDIVLAYE2g/w28qwrodwsNuOjIRvoNqGEfpcYaPSTojCCMcuaUwQVV2k3Vib RJDVQl7MVDnrktkpKFTKOKccNeOhTUNbQB9pyHNWSJOSOSOGf+RZ1n3uI51fbUkP0C puNjTfEK3G4ZJwSTAVptVdeKYNfBB2orHBLkkTe2VCBy6oIX9R/S9SXtZjm17If6R2 9jTrViS5UTQvKtkM0kdCmeIIOdet0kWOk3AbXQY994sBM57nlbIaDzjKVeGhdzSJ62 PZ540DIjwnxlQ== Message-ID: Subject: Re: [nfs-utils PATCH] Don't allow junction tests to trigger automounts From: Jeff Layton To: steved@redhat.com Cc: linux-nfs@vger.kernel.org, Chuck Lever , JianHong Yin Date: Wed, 04 Jan 2023 07:23:58 -0500 In-Reply-To: <20221213160104.198237-1-jlayton@kernel.org> References: <20221213160104.198237-1-jlayton@kernel.org> Content-Type: text/plain; charset="ISO-8859-15" Content-Transfer-Encoding: quoted-printable User-Agent: Evolution 3.46.2 (3.46.2-1.fc37) MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: linux-nfs@vger.kernel.org On Tue, 2022-12-13 at 11:01 -0500, Jeff Layton wrote: > JianHong reported some strange behavior with automounts on an nfs server > without an explicit pseudoroot. When clients issued a readdir in the > pseudoroot, automounted directories that were not yet mounted would show > up even if they weren't exported, though the clients wouldn't be able to > do anything with them. >=20 > The issue was that triggering the automount on a directory would cause > the mountd upcall to time out, which would cause nfsd to include the > automounted dentry in the readdir response. Eventually, the automount > would work and report that it wasn't exported and subsequent attempts to > access the dentry would (properly) fail. >=20 > We never want mountd to trigger an automount. The kernel should do that > if it wants to use it. Change the junction checks to do an O_PATH open > and use fstatat with AT_NO_AUTOMOUNT. >=20 > Cc: Chuck Lever > Link: https://bugzilla.redhat.com/show_bug.cgi?id=3D2148353 > Reported-by: JianHong Yin > Signed-off-by: Jeff Layton > --- > support/junction/junction.c | 10 +++++----- > 1 file changed, 5 insertions(+), 5 deletions(-) >=20 Ping? Steve, can you comment on (or merge) this patch? Thanks, --=20 Jeff Layton