From owner-freebsd-stable Mon May 10 10:59:34 1999 Delivered-To: freebsd-stable@freebsd.org Received: from crydee.sai.msu.ru (crydee.sai.msu.ru [195.208.220.203]) by hub.freebsd.org (Postfix) with ESMTP id 31EEF150BE for ; Mon, 10 May 1999 10:59:22 -0700 (PDT) (envelope-from asv1@crydee.sai.msu.ru) Received: from localhost (asv1@localhost) by crydee.sai.msu.ru (8.9.2/8.9.2) with ESMTP id VAA05561; Mon, 10 May 1999 21:01:11 +0400 (MSD) (envelope-from asv1@crydee.sai.msu.ru) Date: Mon, 10 May 1999 21:01:11 +0400 (MSD) From: "Sergey Ayukov (mailing lists)" To: Doug Rabson Cc: Mats Lofkvist , stable@FreeBSD.ORG Subject: Re: NFS question.. In-Reply-To: Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-freebsd-stable@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG On Mon, 10 May 1999, Doug Rabson wrote: > > Well, I understand the issues (or at least I think so). But I am > > interested in fast, working NFS implementation (which I know could exist > > because Linux does it) and not in explanations (system administration is > > not my primary job). I can trade some bit of stability for performance in > > case of safe/unsafe NFS write modes. > > Linux is fast because it violates the spec (this really pisses me off). Specification violation only affects server, right? Therefore I don't see anything terribly wrong with loose play with specs on server to get reasonable performance. Especially with such a poor design as NFSv2. > The specification for NFSv2 states that the reply to a write rpc shouldn't > be sent until the write has been completed. From rfc1094: [skipped] > The linux server appears to ack the write as soon as it has been handed > off to the kernel's buffer cache (which is certainly not stable storage). > If you want FreeBSD to do this, you can set the sysctl variable > vfs.nfs.async to nonzero. The default for this is off since turning it on > risks data loss. I have tried it now. Performance numbers are below. Client is OS/2 NFS, with rsize and wsize of 8192. NFSD Host OS Network Throughput, KB/s Comments speed Read Write FreeBSD 3.1 100 4500 610 ! vfs.nfs.async=1 FreeBSD 3.1 100 550 vfs.nfs.async=0 FTP->FreeBSD 100 6000 3000 FreeBSD 3.1 10 1040 560 vfs.nfs.async=1 FreeBSD 3.1 10 330 vfs.nfs.async=0 Linux 10 1020 800 ! Solaris 7 (i386) 10 900 480 100Mbit segment is clean (it's just a crossover cable, actually) while 10Mbit segment is more or less loaded. As you see, there's no significant performance improvement with vfs.nfs.async=1 (BTW, where can I find the information about all sysctl variables?) The figure 4500KB/s on read apparently involves disk cache because hard drive itself can't sustain it. FTP read is only 6MB/s due to OS/2 TCP/IP stack limitations and measuring problems (the file I was testing on is just 12MB). FTP write is limited by both local read and remote write. > Alternatively you can use NFSv3 which uses a more complex protocol which > allows the server to delay the writes safely. If the linux clients can't > do NFSv3, perhaps you would consider replacing them with FreeBSD > clients... I have DOS and OS/2 clients, and I can't change that, unfortunately. While performance for DOS clients is more or less acceptable (they are not very fast machines anyway), I am concerned about OS/2 client performance. Windoze clients connect to Samba which unfortunately is also very slow on writes for unknown reasons, but that's another thread... --------------------------------------------------------------------------- Dr. Sergey Ayukov Sternberg Astronomical Institute http://www.ayukov.com Moscow, Russia http://crydee.sai.msu.ru/index-asv.html To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-stable" in the body of the message