From owner-freebsd-hackers Mon May 8 6:55: 8 2000 Delivered-To: freebsd-hackers@freebsd.org Received: from bingnet2.cc.binghamton.edu (bingnet2.cc.binghamton.edu [128.226.1.18]) by hub.freebsd.org (Postfix) with ESMTP id 46D9537B53E for ; Mon, 8 May 2000 06:55:05 -0700 (PDT) (envelope-from zzhang@cs.binghamton.edu) Received: from sol.cs.binghamton.edu (sol.cs.binghamton.edu [128.226.123.100]) by bingnet2.cc.binghamton.edu (8.9.3/8.9.3) with ESMTP id JAA26017; Mon, 8 May 2000 09:55:01 -0400 (EDT) Date: Mon, 8 May 2000 09:54:34 -0400 (EDT) From: Zhihui Zhang To: Matthew Dillon Cc: freebsd-hackers@FreeBSD.ORG Subject: Re: One NFS cookie question In-Reply-To: <200005080644.XAA14811@apollo.backplane.com> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG On Sun, 7 May 2000, Matthew Dillon wrote: > :I have one question regarding the usage of NFS cookies. I read the > :following passage in the mailing list archive: > : > :-------- > : > :The BSD code simpy re-reads all of the directory blocks until it > :hits the right offset again whenever it gets NFSERR_BAD_COOKIE. However, > :suppose you have a directory of 3 blocks. You read the first block. > :Your offset is now at the end of the first block. You delete all the > :files in the first block. You want to read the 2nd block. You get > :BAD_COOKIE. So then you start again from the beginning, until you > :are at the wanted offset. However, the first block has disappeared now, > :so your offset lands you at what was originally the 3rd block. You've > :missed the 2nd block entirely. > : > :------- > : > :Is this problem solved or not in FreeBSD 4.0-Release? > : > :-Zhihui > > I think this problem has been solved, at least insofar as Solaris > clients (which are sensitive to BAD_COOKIE returns from a FreeBSD > NFS server) are concerned . > This is not obvious from the source code. The BAD_COOKIE is now only returned locally on the client side. Anyway, since the client has read lock on the nfsnode, this rarely happens and if so, the client is messing with himself. It can do nothing with other NFS clients due to the stateless of the server. -Zhihui To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message