Received: by 2002:ab2:7855:0:b0:1f9:5764:f03e with SMTP id m21csp572159lqp; Wed, 22 May 2024 12:40:45 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCXnSZEY1bkATFEZhrhxm5u+vqfrbVv0UiMs0/WoYefrjIqGdmC5wKlyybwp07gK259E0v2QMkxpkAV7eIa8bU8N6VTsEZOBlyZe7PbzgQ== X-Google-Smtp-Source: AGHT+IHxlxWWIe6kRR9xe51Jn/+OJmdU8M/BCo+aDGjn2guL5xWOcCmUA5y7jTY3zQig6ol4wAlq X-Received: by 2002:a2e:92ce:0:b0:2e7:151:4bd0 with SMTP id 38308e7fff4ca-2e9495505c0mr18275281fa.20.1716406845521; Wed, 22 May 2024 12:40:45 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1716406845; cv=pass; d=google.com; s=arc-20160816; b=01BnTBlKmF02Dsr6QKsa+cKrYdxV1bEFe5eWoeuCmvAFK5mf0cRepQAQY6VTDh0Z26 zDx/1H4siIpVR6Wey5+JpdqJsDLy6GLYevAy/rzvha2+jh4O0lNjCzkhr4DmKF+igmjj pcK2tQOpwjctFcQkMjBm9V2M3FV3mOwl9oCpXL1pac3gaq0ka00Y1Yip0dJ+lem35lXa uY/c4KD8Fi3RqRyyuxCVOqkoY1EeCISwZm9QR2pdu1I18Llgnqi/gft3R8vN6iPhnhmD CUC+HJIWm44fO+fdu3IjVJ2gcx2BGzlNP9+j8OpLmVMrgKbPVC0WEjdGyQyUcPI4e8T+ GbDg== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:in-reply-to:content-language:references :cc:to:from:subject:user-agent:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:date:message-id; bh=xYSzCVqGVCN6hRR0v4IyYrc8OYj7KgCuAfX9b8bLwok=; fh=T75iuVtw8UDCAUKT7edpT451MRMrO06PMMmVhTXTwAQ=; b=DvhYClGPbwrPzKGfc89s877Bq3zAvur43qr3Z/0A0MkVXHFWYYIBi3IsCh5jze1d+n VnyJEGOC1n7KbYYlUU1W4+AfYJj2X+UJZX+ozbPiZSIdYnKiGUdkFbPPYc4FZjpUhkMD XhaVEzk+VR8PmB/vHnXyYLV4S5LraLRysqYOf3q54DuWTaG4SJYf1ZloZopS61hG0pSc cILZY/zlDqNW6j/9ZMDpkKuRBt5la1gHTS9c1EQZNf6g+HopOWO07Z1rRGe3cYOVc164 MSUhJPEtFg7y9OHEd+fySKFfgzoRXwykZHG57VjJ5KhOdf9XVNiLRYjl+u2BYC2AXCeY Lqiw==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; arc=pass (i=1 spf=pass spfdomain=gmail.com); spf=pass (google.com: domain of linux-nfs+bounces-3340-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.80.249 as permitted sender) smtp.mailfrom="linux-nfs+bounces-3340-linux.lists.archive=gmail.com@vger.kernel.org" Return-Path: Received: from am.mirrors.kernel.org (am.mirrors.kernel.org. [147.75.80.249]) by mx.google.com with ESMTPS id 4fb4d7f45d1cf-57509572b40si7802993a12.357.2024.05.22.12.40.45 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 22 May 2024 12:40:45 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-nfs+bounces-3340-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.80.249 as permitted sender) client-ip=147.75.80.249; Authentication-Results: mx.google.com; arc=pass (i=1 spf=pass spfdomain=gmail.com); spf=pass (google.com: domain of linux-nfs+bounces-3340-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.80.249 as permitted sender) smtp.mailfrom="linux-nfs+bounces-3340-linux.lists.archive=gmail.com@vger.kernel.org" Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by am.mirrors.kernel.org (Postfix) with ESMTPS id 38B641F21555 for ; Wed, 22 May 2024 19:40:45 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id EA45A134BC; Wed, 22 May 2024 19:40:43 +0000 (UTC) X-Original-To: linux-nfs@vger.kernel.org Received: from mail-wr1-f50.google.com (mail-wr1-f50.google.com [209.85.221.50]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 219587BB01 for ; Wed, 22 May 2024 19:40:41 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.221.50 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1716406843; cv=none; b=Fqtwy3qGtpxRa3PU14WK/B4oOsJuN+vDoR3hYLaXmMtuS//RWx9OorkMI4HzvWnlz8xHXT3IA0P1i1wC3spdiYVMF3SwRUOWZ0awS54HM+lgF668enuL/JwOmCMskdZqeJ2ZHZdsvhALvItTk6kXKcTSBbyZZhsVGZ/zGuZhdjI= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1716406843; c=relaxed/simple; bh=gDjeJZgaSxzV2bdDDJcyrwo5uymOIFhqW6OF4c5ZMYg=; h=Message-ID:Date:MIME-Version:Subject:From:To:Cc:References: In-Reply-To:Content-Type; b=lDT4IRG5/Ts903AjmnigG5xYSyMBtyZK83ZFp8NPwv2Mmaxr6mTIg16oGerYUfGEivOUev5kzcW2Fq1hPhzcMPaKdcY7v3GzB1PAxnB6c1OOIcwG+wPc85Uc5IhBPhe+oIwqJ7YPFvoDmBj0e49/cvFvWCCYlR22nTEwH3QQoNM= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=grimberg.me; spf=pass smtp.mailfrom=gmail.com; arc=none smtp.client-ip=209.85.221.50 Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=grimberg.me Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gmail.com Received: by mail-wr1-f50.google.com with SMTP id ffacd0b85a97d-34ef40fae25so283822f8f.1 for ; Wed, 22 May 2024 12:40:41 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1716406840; x=1717011640; h=content-transfer-encoding:in-reply-to:content-language:references :cc:to:from:subject:user-agent:mime-version:date:message-id :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=xYSzCVqGVCN6hRR0v4IyYrc8OYj7KgCuAfX9b8bLwok=; b=nKLn+VAKo+7Pco/rAW09/I3dUN3c5R0zwJciJgJbrEFZTWRKmj/B0gvGCk1n+nN/8J uS/s+mssVNrZ1+AjyK8yr/sYlQWfTLCBNToR3wfsmUhI+iXCwtZti31K1lqQrnQrMoBs /NSJiIyKGTT6x4E3pD0lPAzhPoaDuiRAefPipLT8HgsG1wPGOaH6PNv3FuRewNF+Acuk wyjdm4vTrYYCtUXl1uEwdS+LTjhvRlF+dY4sKbJCScbS4da6iGQA+nH4cthtKWP0HcV+ 9E8wVKxKwdCV1HM4HhrG5CqhZishMbKpgoUjM4tFYBCgXtXewzd7BTvbnP85sC5e7jU/ nCAA== X-Forwarded-Encrypted: i=1; AJvYcCVWlVOdkDyB3TAFekAhSX4/EfAtWltLGiPY4zq/6cjO3QlCHv/XeSW4+w3lhDltbd/xa+PlC55viFFfnK7/6VLMyVnZxhSO3tGV X-Gm-Message-State: AOJu0YzoorvoYywV3JSa1qmoxaV46LDxwx5jIrgliZA2GsSCQgPgzicb wqvNtHb7dG9IU0GfO3ZLjPmEt2lG/A+b5+Pz3ThB3390jd5zJdm7zuRKLw== X-Received: by 2002:a05:600c:4fcd:b0:41c:a98:b217 with SMTP id 5b1f17b1804b1-420fd3975b8mr23156555e9.4.1716406819584; Wed, 22 May 2024 12:40:19 -0700 (PDT) Received: from [10.100.102.74] (85.65.193.189.dynamic.barak-online.net. [85.65.193.189]) by smtp.gmail.com with ESMTPSA id 5b1f17b1804b1-42100f14436sm3441885e9.17.2024.05.22.12.40.18 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Wed, 22 May 2024 12:40:19 -0700 (PDT) Message-ID: Date: Wed, 22 May 2024 22:40:17 +0300 Precedence: bulk X-Mailing-List: linux-nfs@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: [PATCH rfc] nfs: propagate readlink errors in nfs_symlink_filler From: Sagi Grimberg To: Trond Myklebust , "linux-nfs@vger.kernel.org" , "jlayton@kernel.org" Cc: "hch@lst.de" , "dan.aloni@vastdata.com" , "chuck.lever@oracle.com" References: <20240521125840.186618-1-sagi@grimberg.me> <4d2bc7f1-b5c2-469c-9351-772626c707d7@grimberg.me> Content-Language: he-IL, en-US In-Reply-To: <4d2bc7f1-b5c2-469c-9351-772626c707d7@grimberg.me> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit Hey Trond, >> filehandle is stale? There will have been an unlink() on the symlink at >> some point in the recent past. >> > > No reason that I can see. However given that this was observed in the > wild, and essentially > a common pattern with symlinks (overwrite a config file for example), > I think its reasonable > to have the vfs at least do a single retry, by simply returning ESTALE. > However NFS cannot distinguish between first and second retries > afaict... Perhaps the > vfs can help with a ESTALE->ENOENT conversion? So what do you suggest we do here? IMO at a minimum NFS should retry once similar to nfs4_file_open (it would probably address 99.9% of the use-cases where symlinks are not overwritten in a high enough frequency for the client to see 2 consecutive stale readlink rpc rplies). I can send a patch paired with a vfs ESTALE conversion patch? alternatively retry locally in NFS... I would like to understand your position here.