From owner-freebsd-stable Thu Jan 25 16:33:41 2001 Delivered-To: freebsd-stable@freebsd.org Received: from emma1.emma.line.org (p3EE3C868.dip.t-dialin.net [62.227.200.104]) by hub.freebsd.org (Postfix) with ESMTP id 8689137B401; Thu, 25 Jan 2001 16:33:21 -0800 (PST) Received: by emma1.emma.line.org (Postfix, from userid 500) id 26A20A2068; Fri, 26 Jan 2001 01:16:44 +0100 (CET) To: Eric Werme USG Cc: Mike Smith , Linux NFS mailing list , FreeBSD Stable , Guy Harris Subject: Resolved: Incompatible: FreeBSD 4.2 client, Linux 2.2.18 nfsv3 server, read-only export References: <200101252040.PAA0000803167@anw.zk3.dec.com> In-Reply-To: <200101252040.PAA0000803167@anw.zk3.dec.com> From: Matthias Andree Date: 26 Jan 2001 01:16:44 +0100 Message-ID: Lines: 76 User-Agent: Gnus/5.0808 (Gnus v5.8.8) Emacs/20.7 MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Sender: owner-freebsd-stable@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG Eric Werme USG writes: > Umm, either I'm reading your post wrong, or you've glitched on your > recall of the protocol. > > If status == NFS3ERR_ROFS, then you get ACCESS3resfail which does not > have the bit mask that is only returned as part of ACCESS3resok. Evident when using a good packet dissector like ethereal. :*) > Folks, I think we've beaten this dead molehill into a mountain. > What's going to happen when someone finds a big problem? Message flood without hope to escape the Big Chaos[tm]. Seriously, Neil Brown has posted a really short (3 line) patch to the linux-kernel mailing list which does the expected job: fix the server problem. I'm using it and my FreeBSD 4.2 client and Linux 2.2.18 server happily chat to each other "in NFSv3". As a reference and for the records and archives, I'm attaching the patch (against vanilla 2.2.18 Linux) that Neil Brown sent to the linux-kernel mailing list. Thanks for all helpful mails and tracking and tracing. Thanks to Neil for fixing things. Again, Neil's patch is against a stock kernel.org Linux 2.2.18 tree. To apply in /usr/src/linux with patch -p0. Matthias Andree Neil's patch to follow, headers mutilated and quotes and attribution of the body stripped (already there): From: Neil Brown To: Matthias Andree Date: Wed, 24 Jan 2001 17:06:55 +1100 (EST) Message-ID: <14958.28927.756597.940445@notabene.cse.unsw.edu.au> Cc: Linux NFS mailing list , Linux-Kernel mailing list , Alan Cox Subject: Re: [NFS] Linux 2.2.18 nfs v3 server bug (was: Incompatible: FreeBSD 4.2 client, Linux 2.2.18 nfsv3 server, read-only export) References: <20010123015612.H345@quadrajet.flashcom.com> <20010123162930.B5443@emma1.emma.line.org> <20010123105350.B344@quadrajet.flashcom.com> <20010124041437.A28212@emma1.emma.line.org> [...] I stuffed up when I tried to interpret the error, but after much sensible correction, here is a patch. Please try it, and suggest any other errs that should be tested for (or maybe we should invert the sense of the test, and test for error codes that ACCESS is allowed to return. 2.4.0 seems to get it right. NeilBrown --- ./fs/nfsd/vfs.c 2001/01/10 05:03:28 1.11 +++ ./fs/nfsd/vfs.c 2001/01/24 06:02:01 @@ -448,7 +448,9 @@ error = nfsd_permission(export, dentry, (map->how | NO_OWNER_OVERRIDE)); if (error == 0) result |= map->access; - else if ((error == nfserr_perm) || (error == nfserr_acces)) { + else if ((error == nfserr_perm) || + (error == nfserr_acces) || + (error == nfserr_rofs)) { /* * This access type is denyed; but the * access query itself succeeds. To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-stable" in the body of the message