From nobody@FreeBSD.org Mon Feb 23 05:17:40 2009 Return-Path: Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 9AF77106566B for ; Mon, 23 Feb 2009 05:17:40 +0000 (UTC) (envelope-from nobody@FreeBSD.org) Received: from www.freebsd.org (www.freebsd.org [IPv6:2001:4f8:fff6::21]) by mx1.freebsd.org (Postfix) with ESMTP id 6F4CE8FC1A for ; Mon, 23 Feb 2009 05:17:40 +0000 (UTC) (envelope-from nobody@FreeBSD.org) Received: from www.freebsd.org (localhost [127.0.0.1]) by www.freebsd.org (8.14.3/8.14.3) with ESMTP id n1N5HeJ0019440 for ; Mon, 23 Feb 2009 05:17:40 GMT (envelope-from nobody@www.freebsd.org) Received: (from nobody@localhost) by www.freebsd.org (8.14.3/8.14.3/Submit) id n1N5HeO9019439; Mon, 23 Feb 2009 05:17:40 GMT (envelope-from nobody) Message-Id: <200902230517.n1N5HeO9019439@www.freebsd.org> Date: Mon, 23 Feb 2009 05:17:40 GMT From: Jeff Garzik To: freebsd-gnats-submit@FreeBSD.org Subject: Failure to mount NFSv4 server X-Send-Pr-Version: www-3.1 X-GNATS-Notify: >Number: 131995 >Category: kern >Synopsis: [nfs] Failure to mount NFSv4 server >Confidential: no >Severity: serious >Priority: medium >Responsible: jh >State: closed >Quarter: >Keywords: >Date-Required: >Class: sw-bug >Submitter-Id: current-users >Arrival-Date: Mon Feb 23 05:20:01 UTC 2009 >Closed-Date: Thu Jun 17 19:15:10 UTC 2010 >Last-Modified: Thu Jun 17 19:15:10 UTC 2010 >Originator: Jeff Garzik >Release: 7.1 >Organization: Red Hat, Inc. >Environment: FreeBSD freebsd71.yyz.us 7.1-RELEASE FreeBSD 7.1-RELEASE #0: Thu Jan 1 08:58:24 UTC 2009 root@driscoll.cse.buffalo.edu:/usr/obj/usr/src/sys/GENERIC amd64 >Description: I am the author of an NFSv4 userland server. Linux and OpenSolaris NFSv4 clients successfully talk to my server, but FreeBSD 7.1 does not. Problems observed: 1) The "-4" argument to mount_nfs does not automatically set the TCP (-T) and port 2049 (-o port=2049) options. These are the defaults for NFSv4. Quoting RFC3530: The registered port 2049 [RFC3232] for the NFS protocol should be the default configuration. Using the registered port for NFS services means the NFS client will not need to use the RPC binding protocols as described in [RFC1833] 2) As quoted above in RFC3530, rpc bind/mount protocols are not needed for NFSv4, and should not be required to mount an NFSv4 filesystem. 3) When supplying the '-4', '-T' and -'o port=2049' options, FreeBSD's NFSv4 client successfully contacts my server... and tries to speak NFSv3! RPC header from mount_nfs -4 -T -o port=2049 bd:/ /bd yields RPC version: 2 RPC program: 100003 RPC program version: 3 FreeBSD 7.1 also has problems mounting a known-working-with-multiple-clients Linux NFSv4 server, but I'll leave that for a separate bug report. >How-To-Repeat: 1. Install Linux 2. Install my NFSv4 server from git repository: http://linux.yyz.us/projects/nfsv4.html 3. Run my NFSv4 server under Linux (sorry, no fBSD support... yet). 4. Run tcpdump on client or server, watching the NFS and RPC traffic 5. Attempt to mount Linux NFSv4 userland server from FreeBSD NFSv4 client >Fix: 1. Directly connect to port 2049 over TCP by default, for NFSv4. No need to consult portmapper, rpcbind, mountd, etc. 2. Actually speak NFSv4 RPC protocol, once connected to an NFSv4 server (see problem #3, above). >Release-Note: >Audit-Trail: Responsible-Changed-From-To: freebsd-bugs->freebsd-fs Responsible-Changed-By: linimon Responsible-Changed-When: Mon Feb 23 08:49:12 UTC 2009 Responsible-Changed-Why: Over to maintainer(s). http://www.freebsd.org/cgi/query-pr.cgi?pr=131995 Responsible-Changed-From-To: freebsd-fs->rmacklem Responsible-Changed-By: ed Responsible-Changed-When: Fri Sep 18 13:41:51 UTC 2009 Responsible-Changed-Why: http://www.freebsd.org/cgi/query-pr.cgi?pr=131995 Responsible-Changed-From-To: rmacklem->freebsd-fs Responsible-Changed-By: ed Responsible-Changed-When: Fri Sep 18 13:42:28 UTC 2009 Responsible-Changed-Why: Woops! Better put it back on fs@. It looks like this has something to do with the old NFS implementation. http://www.freebsd.org/cgi/query-pr.cgi?pr=131995 State-Changed-From-To: open->feedback State-Changed-By: jh State-Changed-When: Wed Mar 10 16:03:11 UTC 2010 State-Changed-Why: University of Michigan NFSv4 client has been removed from head and stable/8. A new, experimental implementation with support for NFSv4 is available in head and stable/8. Can you still reproduce the problems with the new implementation? The file system type for mount(8) command is newnfs. Responsible-Changed-From-To: freebsd-fs->jh Responsible-Changed-By: jh Responsible-Changed-When: Wed Mar 10 16:03:11 UTC 2010 Responsible-Changed-Why: Track. http://www.freebsd.org/cgi/query-pr.cgi?pr=131995 State-Changed-From-To: feedback->closed State-Changed-By: jh State-Changed-When: Thu Jun 17 19:15:09 UTC 2010 State-Changed-Why: Feedback timeout. http://www.freebsd.org/cgi/query-pr.cgi?pr=131995 >Unformatted: