From owner-freebsd-fs@freebsd.org Mon Jul 6 21:29:58 2015 Return-Path: Delivered-To: freebsd-fs@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id C96E999509A for ; Mon, 6 Jul 2015 21:29:58 +0000 (UTC) (envelope-from allan@physics.umn.edu) Received: from mail.physics.umn.edu (smtp.spa.umn.edu [128.101.220.4]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id ABBD61F97 for ; Mon, 6 Jul 2015 21:29:57 +0000 (UTC) (envelope-from allan@physics.umn.edu) Received: from peevish.spa.umn.edu ([128.101.220.230]) by mail.physics.umn.edu with esmtp (Exim 4.77 (FreeBSD)) (envelope-from ) id 1ZCDxc-000DqW-JW; Mon, 06 Jul 2015 16:29:56 -0500 Received: by peevish.spa.umn.edu (Postfix, from userid 5000) id 86818A0F; Mon, 6 Jul 2015 16:29:56 -0500 (CDT) Date: Mon, 6 Jul 2015 16:29:56 -0500 From: Graham Allan To: Rick Macklem Cc: freebsd-fs@freebsd.org Subject: Re: increasing MAXNFSDCNT Message-ID: <20150706212956.GO12772@physics.umn.edu> References: <20150706191956.GL12772@physics.umn.edu> <1318238880.4985990.1436215575189.JavaMail.zimbra@uoguelph.ca> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1318238880.4985990.1436215575189.JavaMail.zimbra@uoguelph.ca> User-Agent: Mutt/1.5.20 (2009-12-10) X-BeenThere: freebsd-fs@freebsd.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: Filesystems List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 06 Jul 2015 21:29:58 -0000 On Mon, Jul 06, 2015 at 04:46:15PM -0400, Rick Macklem wrote: > Graham Allan wrote: > > Regarding the maximum number of nfs server threads, is increasing the > > "#define MAXNFSDCNT 256" in nfsd.c the only thing needed to try higher > > values? > > > Oops, my turn to admit that I should have read the man page before answering. > If you have a fairly recent nfsd that supports the "-maxthreads" option, you > can set this and I'm pretty sure you can make it larger than 256. > The system actually dynamically adjusts the # of nfsd kernel threads between > "-minthreads" and "-maxthreads". The "-n" option (which should probably be deprecated) > sets both of these to the same value and is limited to MAXNFSDCNT (256). > > If your nfsd doesn't support "-maxthreads", increasing MAXNFSDCNT should work. Would have helped if I stated the version too - I'm using 9.3 so it just supports "-n" (I can see "-minthreads" and "-maxthreads" in the 10.1 man pages). I guess I'm a bit cautious about increasing it though, since I expect it's possible I might rebuild a new patch release without remembering to re-edit nfsd.c. If that were the case and I'd specified "-n" > MAXNFSDCNT then this version of nfsd would revert back to DEFNFSDCNT = 4, which could be a painful shot in the foot. Thanks, Graham