From owner-freebsd-fs@FreeBSD.ORG Fri Sep 27 13:54:09 2013 Return-Path: Delivered-To: freebsd-fs@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTP id BAA3E62C for ; Fri, 27 Sep 2013 13:54:09 +0000 (UTC) (envelope-from ronald-freebsd8@klop.yi.org) Received: from cpsmtpb-ews09.kpnxchange.com (cpsmtpb-ews09.kpnxchange.com [213.75.39.14]) by mx1.freebsd.org (Postfix) with ESMTP id 2B9D422BE for ; Fri, 27 Sep 2013 13:54:08 +0000 (UTC) Received: from cpsps-ews01.kpnxchange.com ([10.94.84.168]) by cpsmtpb-ews09.kpnxchange.com with Microsoft SMTPSVC(7.5.7601.17514); Fri, 27 Sep 2013 15:52:57 +0200 Received: from CPSMTPM-TLF101.kpnxchange.com ([195.121.3.4]) by cpsps-ews01.kpnxchange.com with Microsoft SMTPSVC(7.5.7601.17514); Fri, 27 Sep 2013 15:52:57 +0200 Received: from sjakie.klop.ws ([212.182.167.131]) by CPSMTPM-TLF101.kpnxchange.com with Microsoft SMTPSVC(7.5.7601.17514); Fri, 27 Sep 2013 15:52:57 +0200 Received: from 212-182-167-131.ip.telfort.nl (localhost [127.0.0.1]) by sjakie.klop.ws (Postfix) with ESMTP id D8D8B984 for ; Fri, 27 Sep 2013 15:52:56 +0200 (CEST) Content-Type: text/plain; charset=us-ascii; format=flowed; delsp=yes To: freebsd-fs@freebsd.org Subject: Re: zfs: the exponential file system from hell References: <52457A32.2090105@fsn.hu> Date: Fri, 27 Sep 2013 15:52:56 +0200 MIME-Version: 1.0 Content-Transfer-Encoding: 7bit From: "Ronald Klop" Message-ID: In-Reply-To: <52457A32.2090105@fsn.hu> User-Agent: Opera Mail/12.16 (FreeBSD) X-OriginalArrivalTime: 27 Sep 2013 13:52:57.0474 (UTC) FILETIME=[DF301620:01CEBB88] X-RcptDomain: freebsd.org X-BeenThere: freebsd-fs@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Filesystems List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 27 Sep 2013 13:54:09 -0000 On Fri, 27 Sep 2013 14:29:38 +0200, Attila Nagy wrote: > Hi, > > Did anyone try to fill a zpool with multiple zfs in it and graph the > space accounted by df and zpool list? > If not, here it is: > https://picasaweb.google.com/104147045962330059540/FreeBSDZfsVsDf#5928271443977601554 > > The zpool in question: > NAME STATE READ WRITE CKSUM > mnt ONLINE 0 0 0 > raidz2-0 ONLINE 0 0 0 > da1 ONLINE 0 0 0 > da2 ONLINE 0 0 0 > da3 ONLINE 0 0 0 > da4 ONLINE 0 0 0 > raidz2-1 ONLINE 0 0 0 > da5 ONLINE 0 0 0 > da6 ONLINE 0 0 0 > da7 ONLINE 0 0 0 > da8 ONLINE 0 0 0 > raidz2-2 ONLINE 0 0 0 > da9 ONLINE 0 0 0 > da10 ONLINE 0 0 0 > da11 ONLINE 0 0 0 > da13 ONLINE 0 0 0 > > And the zfs-es on it: > NAME USED AVAIL REFER MOUNTPOINT > mnt 23.3G 0 53.8K /mnt > mnt/p1 3.89G 0 3.89G /mnt/p1 > mnt/p2 3.89G 0 3.89G /mnt/p2 > mnt/p3 3.89G 0 3.89G /mnt/p3 > mnt/p4 3.89G 0 3.89G /mnt/p4 > mnt/p5 3.89G 0 3.89G /mnt/p5 > mnt/p6 3.89G 0 3.89G /mnt/p6 > > I have evenly filled the six zfs in 1/100th percents of the full space > available, and graphed the results of zpool list's capacity and df's > capacity. > The x scale is the real space usage in percents. > > It's quite annoying when df says the file systems are 20% full, while in > reality, they are at 60%. > > Any chance that it will be solved? So, if I understand you correctly, you compare the output of free space of zpool list (of the whole pool) to the output of df of one of size zfs's. So the conclusion is that zpool list shows you how much space there is in the pool and df shows the amount-of-space-of-one-zfs-if-you-don't-do-change-other-zfs's-in-the-pool-in-the-meantime. This is not going to be fixed. It is by design. Choose the best tool to measure what you want to know. But I understand it is a bit confusing if you come from traditional fixed-size filesystems. You can emulate a fixed-size filesystem by using quota's. Give all zfs's 1/6 of the space in quota and your df will work perfectly. NB: I'm not a ZFS developer so I don't have an authoritative opinion about all this. Regards, Ronald.