From owner-freebsd-fs@FreeBSD.ORG Mon Jan 23 15:56:56 2012 Return-Path: Delivered-To: freebsd-fs@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 0F447106564A; Mon, 23 Jan 2012 15:56:56 +0000 (UTC) (envelope-from rmacklem@uoguelph.ca) Received: from esa-jnhn.mail.uoguelph.ca (esa-jnhn.mail.uoguelph.ca [131.104.91.44]) by mx1.freebsd.org (Postfix) with ESMTP id A6BED8FC08; Mon, 23 Jan 2012 15:56:55 +0000 (UTC) X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: Ap4EABOCHU+DaFvO/2dsb2JhbABDhQmqI4FyAQEEASNWGw4KAgINGQJZBi6HYacVkRuBL4lhgRYEiDuMXpJs X-IronPort-AV: E=Sophos;i="4.71,556,1320642000"; d="scan'208";a="156355770" Received: from erie.cs.uoguelph.ca (HELO zcs3.mail.uoguelph.ca) ([131.104.91.206]) by esa-jnhn-pri.mail.uoguelph.ca with ESMTP; 23 Jan 2012 10:56:54 -0500 Received: from zcs3.mail.uoguelph.ca (localhost.localdomain [127.0.0.1]) by zcs3.mail.uoguelph.ca (Postfix) with ESMTP id C435FB3F1E; Mon, 23 Jan 2012 10:56:54 -0500 (EST) Date: Mon, 23 Jan 2012 10:56:54 -0500 (EST) From: Rick Macklem To: Jaakko Heinonen Message-ID: <219911446.737753.1327334214785.JavaMail.root@erie.cs.uoguelph.ca> In-Reply-To: <20120123153833.GB2246@a91-153-116-96.elisa-laajakaista.fi> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-Originating-IP: [172.17.91.203] X-Mailer: Zimbra 6.0.10_GA_2692 (ZimbraWebClient - FF3.0 (Win)/6.0.10_GA_2692) Cc: freebsd-fs@freebsd.org Subject: Re: should mount -u fail or silently ignore options? X-BeenThere: freebsd-fs@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Filesystems List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 23 Jan 2012 15:56:56 -0000 Jaakko Heinonen wrote: > On 2012-01-22, Rick Macklem wrote: > > There is a bug in the NFS clients, where a > > "mount -u -o udp /mnt" will cause any threads > > that have an RPC in progress to hang, if the > > mount previously was using too large an rsize/wsize. > > Does the hang occur if the UDP transport was already used? > I don't think so. I did test the case where it switched from TCP to UDP, but the TCP mount had rsize=16384,wsize=16384 and that was fine. The problem occurs when the rsize/wsize for the mount is > 16K before the change to UDP (which "can't" be the case if the mount is already UDP). The patch only generates an error if the old rsize/wsize is greater than 16K. Or, it could be easily re-written to silently ignore the request to switch to UDP. > > This case can easily be detected in nfs_mount(). > > > > However, my question is... > > - Should the "mount -u" fail and return an error > > OR > > Silently ignore the "udp" option and return ok. > > Depending on the answer to the question above, IMHO the best solution > would be to return an error if user tries to change TCP to UDP but > accept the "udp" option if UDP transport is already active. I don't > know > about potential problems with root nfs. > Yea, I feel returning an error makes more sense than silently ignoring the request. The concerns I had were related to diskless roots. Thanks for the comments, rick > -- > Jaakko