From owner-freebsd-hackers Sat Jul 19 16:24:21 1997 Return-Path: Received: (from root@localhost) by hub.freebsd.org (8.8.5/8.8.5) id QAA16780 for hackers-outgoing; Sat, 19 Jul 1997 16:24:21 -0700 (PDT) Received: from minor.stranger.com (stranger.vip.best.com [204.156.129.250]) by hub.freebsd.org (8.8.5/8.8.5) with SMTP id QAA16775 for ; Sat, 19 Jul 1997 16:24:14 -0700 (PDT) Received: from dog.farm.org (dog.farm.org [207.111.140.47]) by minor.stranger.com (8.6.12/8.6.12) with ESMTP id QAA07474 for ; Sat, 19 Jul 1997 16:47:57 -0700 Received: (from dk@localhost) by dog.farm.org (8.7.5/dk#3) id QAA22569 for freebsd-hackers@freebsd.org; Sat, 19 Jul 1997 16:28:38 -0700 (PDT) Received: from dog.farm.org (dog.farm.org [207.111.140.47]) by minor.stranger.com (8.6.12/8.6.12) with ESMTP id OAA07221; Sat, 19 Jul 1997 14:30:29 -0700 Received: (from dk@localhost) by dog.farm.org (8.7.5/dk#3) id OAA21295; Sat, 19 Jul 1997 14:06:26 -0700 (PDT) Date: Sat, 19 Jul 1997 14:06:26 -0700 (PDT) From: Dmitry Kohmanyuk Message-Id: <199707192106.OAA21295@dog.farm.org> To: gilham@csl.sri.com (Fred Gilham) Cc: freebsd-hackers@freebsd.org Subject: Re: NFS wierdness? Newsgroups: cs-monolit.gated.lists.freebsd.hackers Organization: FARM Computing Association Reply-To: dk+@ua.net X-Newsreader: TIN [version 1.2 PL2] Sender: owner-hackers@freebsd.org X-Loop: FreeBSD.org Precedence: bulk In article <199707191439.HAA12910@japonica.csl.sri.com> you wrote: > I have this user who runs programs that generate lots of output to > stdout. The output sometimes contains very long `lines'---long > stretches of output without a newline. The programs are also supposed > to be very CPU intensive. [...] > Unfortunately when he does this on a FreeBSD box where the directory > he's writing to is NFS mounted, he gets almost no CPU time; the > process spends most of its time in the `nfsfsy' state (according to > top). [...] First, some questions: - what is your NFS server? - is NFS mount v3 or v2? On last FreeBSD-SFUG meeting, I talked to Dyson and he confirmed that NFS appends are broken in FreeBSD; I do not know does this relate to 3.0 or 2.2 as well. I have got full-zero blocks written to mail folders opened in append mode, sometimes (folders were written by mail user agent, mutt, not by MTA), so there were no concurrency / locking problems - only one process involved. Also, NFSv3 mount on FreeBSD 2.2.2 is simply broken - it is a sure way to crash thew system by simple `rm -rf /some/dir' when /some/dir has many files (i.e., /usr/src/sys directory mounted from NFS server). This is infamous readdirplus() bug. Same on 2.2-GAMMA, or 2.2-STABLE past 2.2.2-RELEASE (which I run now). NFS v2 mounts do not show these problems (crashes / zero writes). So, please try `mount -t nfs -o nonfsv3 ...' and see whether your problem goes away. My NFS server is NetApp F330, running ONTAP 4.0-something. (this is not a Unix box). It works absolutely flawlessly with Solaris clients, which also use v3 mounts as the default. I think that changing default mount from v2 to v3 was a bad idea. > Both of these boxes are on the same network segment as the directory > they're writing to. They were invoked as follows: > tester >> dummy > and > tester.sol >> dummy > Another symptom of the problem is that it's not possible to get any > output from > tail -f dummy > on the same box that's running on tester program under FreeBSD. > However, solaris has no problems. again, this looks like file append problem. Have you tried writing numbers separated by newlines? Does this make any difference?? -- "The only problem with troubleshooting is that sometimes trouble shoots back." --joez@earthlink.net