From owner-freebsd-hackers Fri Apr 20 7:36:59 2001 Delivered-To: freebsd-hackers@freebsd.org Received: from chmod.ath.cx (CC2-861.charter-stl.com [24.217.115.99]) by hub.freebsd.org (Postfix) with ESMTP id 9B69037B42C for ; Fri, 20 Apr 2001 07:36:56 -0700 (PDT) (envelope-from ajh3@chmod.ath.cx) Received: by chmod.ath.cx (Postfix, from userid 1001) id 6A86DA924; Fri, 20 Apr 2001 09:35:30 -0500 (CDT) Date: Fri, 20 Apr 2001 09:35:30 -0500 From: Andrew Hesford To: niek@bergboer.net Cc: Alfred Perlstein , freebsd-hackers@freebsd.org Subject: Re: UFS block size vs. write speed Message-ID: <20010420093530.A98970@cec.wustl.edu> References: <20010420144543.F30241@wit379119.student.utwente.nl> <20010420055426.Q1790@fw.wintelcom.net> <20010420152029.A35974@wit379119.student.utwente.nl> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.2.5i In-Reply-To: <20010420152029.A35974@wit379119.student.utwente.nl>; from niek@wit379119.student.utwente.nl on Fri, Apr 20, 2001 at 03:20:29PM +0200 X-Loop: Andrew Hesford Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG On Fri, Apr 20, 2001 at 03:20:29PM +0200, Niek Bergboer wrote: > Isn't it true that softupdates only work when filesystems are mounted > sync? Or does it also improve performance when filesystems are > mounted async? The other guy was right; you really do need to wrap text at around 70 lines (I have vim wrap at 72). When I try to reply to messages, it messes up the reply text. I don't send out messages with screwed-up line breaks, so I'm not going to help in the future if the formatting is bad. Soft updates isn't an "async" or "sync" thing. It combines synchronous and asynchronous transfers. If I'm not mistaken, all metadata is synchronously written, and all data is asynchronously written. It also orders writes so that blocks are allocated before inodes, and inodes before directory entries. This is why fsck is so fast: if a directory entry exists for an inode, the file is known to be consistent, so fsck only needs to check for claimed inodes that don't have directory entries, and check the free-block bitmap for used blocks that don't have inodes claiming them. Something like ext2, on the other hand, must check every directory entry, every inode, and every free block to make sure it is allocated properly. This is much slower. But I digress... Since metadata is typically small compared to data, particularly in your case, the synchronous transfers are trivial. According to one paper on FFS with soft updates, I think my Marshall Kirk McKusick, the file system speed approaches that of a memory filesystem. Mounting the partition async would definitely speed up I/O. If you didn't see a noticible gain in network throughput, that tells you the bottleneck is somewhere else. Remember, too, that a network operating at a raw 9Mbits/sec is going to be slower in real-world transfer rates, because transfer protocols have overhead, breaking data into packets and reassembling it takes time, and other things. -- Andrew Hesford ajh3@chmod.ath.cx To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message