From owner-freebsd-questions@FreeBSD.ORG Wed Sep 29 10:14:27 2010 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id C0CF0106564A for ; Wed, 29 Sep 2010 10:14:27 +0000 (UTC) (envelope-from kraduk@gmail.com) Received: from mail-qw0-f54.google.com (mail-qw0-f54.google.com [209.85.216.54]) by mx1.freebsd.org (Postfix) with ESMTP id 6F46F8FC15 for ; Wed, 29 Sep 2010 10:14:27 +0000 (UTC) Received: by qwd6 with SMTP id 6so491314qwd.13 for ; Wed, 29 Sep 2010 03:14:26 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:received:in-reply-to :references:date:message-id:subject:from:to:cc:content-type; bh=3eL+j6p/EYjeUN1y1WRxlqcBQWNYivr+v2J1mffgG9w=; b=V1RKfljskhCMYaQeh4wov+7AqWCCBfp7PNt23y7h2qPaApMGWBavai1Gc+5Z9CTLjS 2qyN4Fv0q09ZgUpHDEI9uHO/vJVTjRlxTC144nPEiTIm25BNuLLdpZr/hfxRy0TUVglP g/6hGxh7IkX81QL6kohvy3iSKTfQ7L1f+NxF8= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type; b=iz0S0oCma4UuCPt/guBK/dYlpRVmaA3hnCwsKXf+3V4jflxLXToq2/F97KaPNVkd2/ SNbxXiRGJH1pQRooLWdNgAITQpGlSvZQpG5VwuUcTVUm+NyPSHZJMZg797yxTV6E5DbD D+he8VN3+Vmi87MwjU2UTvln2sKSrQ5FkgYTc= MIME-Version: 1.0 Received: by 10.224.102.146 with SMTP id g18mr996857qao.200.1285755266532; Wed, 29 Sep 2010 03:14:26 -0700 (PDT) Received: by 10.229.215.209 with HTTP; Wed, 29 Sep 2010 03:14:26 -0700 (PDT) In-Reply-To: <4CA302E5.9050004@pp.dyndns.biz> References: <4CA302E5.9050004@pp.dyndns.biz> Date: Wed, 29 Sep 2010 11:14:26 +0100 Message-ID: From: krad To: =?ISO-8859-1?Q?Morgan_Wesstr=F6m?= Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable X-Content-Filtered-By: Mailman/MimeDel 2.1.5 Cc: freebsd-questions@freebsd.org, Aaron Subject: Re: Disappearing available space with ZFS...what am I missing? X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 29 Sep 2010 10:14:27 -0000 On 29 September 2010 10:12, Morgan Wesstr=F6m wrote: > On 2010-09-29 07:56, Aaron wrote: > >> I've created a ZFS pool with zpool create tank raidz ada0 ada1 ada2 >> ada3, and then I add some additional mountpoints (I think they're >> called) using zfs create tank/storage, etc. In zpool list, I see the >> pool with 3.62T available. With df -h, I see 2.4T available for tank, >> and tank/storage. When I first created tank, it had the 3.62T >> available as I expected. What am I missing? I do have compression set >> to gzip-9 on tank which gets inherited like I want, don't know if that >> would affect anything. >> >> --Aaron >> > > There's nothing wrong here that I can see, you just have to make a > distinction between the zfs pool and the filesystems within the pool and = I > agree it can be confusing at first. > > The numbers suggest you are using 4 x 1TB (base 10 TB) drives? That equal= s > 3.7TiB (base 2 TB) which is the unit zpool/zfs uses. This is the total > amount of space available to the pool and includes all space on all drive= s > in the pool. Nothing strange so far. > > Now, since you've told zpool to create filesystems within the pool using > raidz, the filesystems will have 25% less space available since this spac= e > is used for parity data. So a filesystem using the whole pool will report > having 3.7 * 0.75 =3D 2.7TiB available which is in agreement with your > numbers. A raidz filesystem will always lose 1 disk worth of space and wi= ll > never report that space as available to you since it will always be occup= ied > with parity data. > > The pool on the other hand doesn't make a distinction, in this case anywa= y, > between user data and parity data so zpool will always report what's > actually unallocated on all your physical drives in the pool. For every G= iB > you allocate in the filesystem you will allocate 1.33GiB in the pool sinc= e > that includes parity data. "zfs list" and "df -h" are your best friends t= o > find out how much space is available for your files. Don't bother about > "zpool list". > > Regards > Morgan > > _______________________________________________ > freebsd-questions@freebsd.org mailing list > http://lists.freebsd.org/mailman/listinfo/freebsd-questions > To unsubscribe, send any mail to " > freebsd-questions-unsubscribe@freebsd.org" > It gets even more hairy when you start adding in reservsions, quotas, and compression. Slap dedup on top of that and you get magically growing fs according to df 8)