From owner-cvs-all Tue Jan 4 16:32:28 2000 Delivered-To: cvs-all@freebsd.org Received: from freefall.freebsd.org (freefall.FreeBSD.ORG [204.216.27.21]) by hub.freebsd.org (Postfix) with ESMTP id C41E514FDC; Tue, 4 Jan 2000 16:32:24 -0800 (PST) (envelope-from dillon@FreeBSD.org) Received: (from dillon@localhost) by freefall.freebsd.org (8.9.3/8.9.2) id QAA54189; Tue, 4 Jan 2000 16:32:24 -0800 (PST) (envelope-from dillon@FreeBSD.org) Message-Id: <200001050032.QAA54189@freefall.freebsd.org> From: Matt Dillon Date: Tue, 4 Jan 2000 16:32:23 -0800 (PST) To: cvs-committers@FreeBSD.org, cvs-all@FreeBSD.org Subject: cvs commit: src/sys/nfs nfs_vnops.c Sender: owner-cvs-all@FreeBSD.ORG Precedence: bulk dillon 2000/01/04 16:32:23 PST Modified files: sys/nfs nfs_vnops.c Log: Fix at least one source of the continued 'NFS append race'. close() was calling nfs_flush() and then clearing the NMODIFIED bit. This is not legal since there might still be dirty buffers after the nfs_flush (for example, pending commits). The clearing of this bit in turn prevented a necessary vinvalbuf() from occuring leaving left over dirty buffers even after truncating the file in a new operation. The fix is to simply not clear NMODIFIED. Also added a sysctl vfs.nfs.nfsv3_commit_on_close which, if set to 1, will cause close() to do a stage 1 write AND a stage 2 commit synchronously. By default only the stage 1 write is done synchronously. Reviewed by: Alfred Perlstein Revision Changes Path 1.150 +22 -4 src/sys/nfs/nfs_vnops.c To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe cvs-all" in the body of the message