From owner-freebsd-fs@FreeBSD.ORG Mon Sep 19 19:17:45 2011 Return-Path: Delivered-To: freebsd-fs@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 5E1BB106566B for ; Mon, 19 Sep 2011 19:17:45 +0000 (UTC) (envelope-from bfriesen@simple.dallas.tx.us) Received: from blade.simplesystems.org (blade.simplesystems.org [65.66.246.74]) by mx1.freebsd.org (Postfix) with ESMTP id 23FD38FC12 for ; Mon, 19 Sep 2011 19:17:44 +0000 (UTC) Received: from freddy.simplesystems.org (freddy.simplesystems.org [65.66.246.65]) by blade.simplesystems.org (8.14.4+Sun/8.14.4) with ESMTP id p8JJHis1016787; Mon, 19 Sep 2011 14:17:44 -0500 (CDT) Date: Mon, 19 Sep 2011 14:17:44 -0500 (CDT) From: Bob Friesenhahn X-X-Sender: bfriesen@freddy.simplesystems.org To: Jason Usher In-Reply-To: <1316459220.35419.YahooMailClassic@web121209.mail.ne1.yahoo.com> Message-ID: References: <1316459220.35419.YahooMailClassic@web121209.mail.ne1.yahoo.com> User-Agent: Alpine 2.01 (GSO 1266 2009-07-14) MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.2.2 (blade.simplesystems.org [65.66.246.90]); Mon, 19 Sep 2011 14:17:44 -0500 (CDT) Cc: freebsd-fs@freebsd.org Subject: Re: ZFS obn FreeBSD hardware model for 48 or 96 sata3 paths... X-BeenThere: freebsd-fs@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Filesystems List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 19 Sep 2011 19:17:45 -0000 On Mon, 19 Sep 2011, Jason Usher wrote: > > How does one make sure that all metadata and directories are cached > in RAM? Just run a 'find' on the filesystem, or a 'du' during the > least busy time of day ? Or is there a more elegant, or more direct > way to read all of that in ? Caching occurs due to normal use and it is best to rely on that until proven otherwise. > Further, if this (small files, lots of them) dataset benefits a lot > from having the metadata and dirs read in, how can I KEEP that data > in the cache, but not cache the file data (as you suggest, above) ? Modern zfs includes tunables to decide how metadata and file data caching should be handled. The main reason to disable file data caching would be for cases where the data is only accessed once such as when data is normally written out once to whole files or read just once with a well-behaved algorithm. Video streaming servers may disable file caching if the number of streams served would cause the cache size to grow to huge (yet insufficient) proportions. > Can I explicitly cache metadata/dirs in RAM, and cache file data in L2ARC ? Again, it is best to rely on the caching algorithm until an actual problem has been found. The ZFS ARC will optimize its caching based on use. Less often used data will end up being migrated from the RAM-based ARC to L2ARC. Bob -- Bob Friesenhahn bfriesen@simple.dallas.tx.us, http://www.simplesystems.org/users/bfriesen/ GraphicsMagick Maintainer, http://www.GraphicsMagick.org/