From owner-freebsd-arch@FreeBSD.ORG Fri Oct 23 14:29:29 2009 Return-Path: Delivered-To: arch@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 82B8B1065694; Fri, 23 Oct 2009 14:29:29 +0000 (UTC) (envelope-from brde@optusnet.com.au) Received: from mail03.syd.optusnet.com.au (mail03.syd.optusnet.com.au [211.29.132.184]) by mx1.freebsd.org (Postfix) with ESMTP id ED5A18FC20; Fri, 23 Oct 2009 14:29:28 +0000 (UTC) Received: from c122-106-159-135.carlnfd1.nsw.optusnet.com.au (c122-106-159-135.carlnfd1.nsw.optusnet.com.au [122.106.159.135]) by mail03.syd.optusnet.com.au (8.13.1/8.13.1) with ESMTP id n9NETOGc003170 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Sat, 24 Oct 2009 01:29:26 +1100 Date: Sat, 24 Oct 2009 01:29:24 +1100 (EST) From: Bruce Evans X-X-Sender: bde@delplex.bde.org To: Rick Macklem In-Reply-To: Message-ID: <20091024010347.D14674@delplex.bde.org> References: <200910191634.30040.jhb@freebsd.org> <20091022182943.P13634@delplex.bde.org> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed Cc: arch@FreeBSD.org, John Baldwin Subject: Re: Put a timeout on -ve name cache entries in NFS X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 23 Oct 2009 14:29:29 -0000 On Thu, 22 Oct 2009, Rick Macklem wrote: > On Thu, 22 Oct 2009, Bruce Evans wrote: >> One reason that I never committed my port of NetBSD's implementation of >> negative cache entries for nfs is that I thought the timeout should be >> a mount option but I didn't want to deal with the portability problems >> from that. >> > Just to clarify. Are you saying that, given no other system has such > a mount option, you think the sysctl variable is an ok solution or > that you think it should be a mount option and not a sysctl variable? No; I think it should be a mount option. > I'll admit that I'm biased because the sysctl variable is easier to > do (and I don't think many people will need to twiddle it). I suggested > it to John, mostly so that there was a way of disabling the -ve name > caching, for the rare case where it might be causing someone grief. > (That's what I think he meant by "safety belt".) Mount options are harder to add (especially using nmount) but that is not intrinsic (in 4.4BSD, sysctls were harder to add, but now they have more infrastructure so they are easier to add). It would almost be easier to abuse sysctls for mount options (they would have to select the mount instance). My version actually just uses a hackish sysctl vfs.nfs.negcache (default: enabled) to enable the negative name cache. I don't have any timeout control for it. Bruce