From owner-freebsd-stable@FreeBSD.ORG Wed May 5 16:08:11 2010 Return-Path: Delivered-To: freebsd-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 1EDAE1065670 for ; Wed, 5 May 2010 16:08:11 +0000 (UTC) (envelope-from jdc@koitsu.dyndns.org) Received: from qmta12.westchester.pa.mail.comcast.net (qmta12.westchester.pa.mail.comcast.net [76.96.59.227]) by mx1.freebsd.org (Postfix) with ESMTP id C1E508FC1D for ; Wed, 5 May 2010 16:08:10 +0000 (UTC) Received: from omta13.westchester.pa.mail.comcast.net ([76.96.62.52]) by qmta12.westchester.pa.mail.comcast.net with comcast id Dm9l1e00517dt5G5Cs8BKA; Wed, 05 May 2010 16:08:11 +0000 Received: from koitsu.dyndns.org ([98.248.46.159]) by omta13.westchester.pa.mail.comcast.net with comcast id Ds891e00m3S48mS3Zs8AZD; Wed, 05 May 2010 16:08:11 +0000 Received: by icarus.home.lan (Postfix, from userid 1000) id A6BFD9B425; Wed, 5 May 2010 09:08:08 -0700 (PDT) Date: Wed, 5 May 2010 09:08:08 -0700 From: Jeremy Chadwick To: Tom Evans Message-ID: <20100505160808.GA69687@icarus.home.lan> References: <20100505155833.GA69377@icarus.home.lan> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20100505155833.GA69377@icarus.home.lan> User-Agent: Mutt/1.5.20 (2009-06-14) Cc: FreeBSD Stable Subject: Re: Different sizes between zfs list and zpool list X-BeenThere: freebsd-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Production branch of FreeBSD source code List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 05 May 2010 16:08:11 -0000 On Wed, May 05, 2010 at 08:58:33AM -0700, Jeremy Chadwick wrote: > On Wed, May 05, 2010 at 04:44:32PM +0100, Tom Evans wrote: > > When looking at the size of a pool, this information can be got from > > both zpool list and zfs list: > > > > > $ zfs list > > NAME USED AVAIL REFER MOUNTPOINT > > tank 5.69T 982G 36.5K /tank > > > > > $ zpool list > > NAME SIZE USED AVAIL CAP HEALTH ALTROOT > > tank 8.14T 6.86T 1.28T 84% ONLINE - > > > > Why the different sizes? > > > > The pool is a raidz of 6 x 1.5 TB drives. > > Is the tank filesystem using compression? "zfs get all" would help shed > some light here. > > There is some variance in AVAIL on all of our systems, and I see > identical on Solaris 10. My guess is (the equivalent of) parity of > raidz has something to do with it. > > However, in the case of our systems, USED always matches between zfs > list and zpool list. I should have provided some actual sample data to back this up. I only checked one of our systems, which uses mirror. Here's a better sample set. Some of these use the 'quota' property, but none use compression. host1$ zfs list NAME USED AVAIL REFER MOUNTPOINT data 4.49G 681G 18K none data/home 793M 681G 793M /home data/storage 3.72G 681G 3.72G /storage host1$ zpool list NAME SIZE USED AVAIL CAP HEALTH ALTROOT data 696G 4.49G 692G 0% ONLINE - host1$ zpool status ... NAME STATE READ WRITE CKSUM data ONLINE 0 0 0 ad6 ONLINE 0 0 0 host2$ zfs list NAME USED AVAIL REFER MOUNTPOINT data 312G 1.48T 24.0K none data/backups 312G 1.48T 312G /backups data/home 48.0K 256G 48.0K /home host2$ zpool list NAME SIZE USED AVAIL CAP HEALTH ALTROOT data 2.72T 469G 2.26T 16% ONLINE - host2$ zpool status ... NAME STATE READ WRITE CKSUM data ONLINE 0 0 0 raidz1 ONLINE 0 0 0 ada1 ONLINE 0 0 0 ada2 ONLINE 0 0 0 ada3 ONLINE 0 0 0 host3$ zfs list NAME USED AVAIL REFER MOUNTPOINT pool 45.5G 175G 45.4G /home host3$ zpool list NAME SIZE USED AVAIL CAP HEALTH ALTROOT pool 224G 45.5G 179G 20% ONLINE - host3$ zpool status ... NAME STATE READ WRITE CKSUM pool ONLINE 0 0 0 mirror ONLINE 0 0 0 ad4s1g ONLINE 0 0 0 ad6 ONLINE 0 0 0 host4$ zfs list NAME USED AVAIL REFER MOUNTPOINT data 250G 664G 18K none data/cvs 299K 8.00G 299K /cvs data/home 643M 15.4G 643M /home data/storage 249G 664G 249G /storage host4$ zpool list NAME SIZE USED AVAIL CAP HEALTH ALTROOT data 928G 250G 678G 26% ONLINE - host4$ zpool status ... NAME STATE READ WRITE CKSUM data ONLINE 0 0 0 mirror ONLINE 0 0 0 ada1 ONLINE 0 0 0 ada2 ONLINE 0 0 0 So in summary, Freddie's explanation sounds spot on. -- | Jeremy Chadwick jdc@parodius.com | | Parodius Networking http://www.parodius.com/ | | UNIX Systems Administrator Mountain View, CA, USA | | Making life hard for others since 1977. PGP: 4BD6C0CB |