From owner-freebsd-fs@FreeBSD.ORG Tue Aug 20 14:03:14 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 65D2BB09 for ; Tue, 20 Aug 2013 14:03:14 +0000 (UTC) (envelope-from gtodd@bellanet.org) Received: from mail-qa0-f48.google.com (mail-qa0-f48.google.com [209.85.216.48]) (using TLSv1 with cipher ECDHE-RSA-RC4-SHA (128/128 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id 2818A21A8 for ; Tue, 20 Aug 2013 14:03:13 +0000 (UTC) Received: by mail-qa0-f48.google.com with SMTP id o19so347891qap.14 for ; Tue, 20 Aug 2013 07:03:12 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=x-gm-message-state:date:from:to:subject:message-id:user-agent :mime-version:content-type; bh=HIZBDn/FUhu+NxB4nZ9KlhiygxRRLhnCFO9Vgu4hDCM=; b=m/LUfvXSemESFxPZOoPMrh+2Xxaf92fF0T4JTiIP95g6L0+h39AAl+z32Q/mT8ZeBi rkkDS/xATzsTuo5VTSmtz9THybSlG4fjpz70z7HAVWWLG8FS2pXqupbypvN61gE5B2sx IlKTVjLSPglzXjuYRqHB4w/izdu3SlGJPKzqsdOUcsOqFZAH6CTS2X4YezvwK9dnTthD ZijYcOSGgp4kFkVkOJjeW8QHC0daZPQpJzSMRs4U9CRAMEBWks5fsYnz2TU+mn7GaImo uHprrl4HpLn2y2g8cqp/KvtMBYeSm1DbL1E4hSvS0dYobWFY3uXIzR6PEJSxWScs+8dm cIvw== X-Gm-Message-State: ALoCoQk35R/vCZpX+VLmPFiWSdERtvJnyF0qyRrLxZ21qwJ1cK3ETG42LXG06ZiOcVywTSCf+zwP X-Received: by 10.224.223.137 with SMTP id ik9mr4038061qab.78.1377007392805; Tue, 20 Aug 2013 07:03:12 -0700 (PDT) Received: from [192.168.2.72] (CPE0080c8f208a5-CM001371173cf8.cpe.net.cable.rogers.com. [99.246.61.82]) by mx.google.com with ESMTPSA id a7sm1938592qeg.2.1969.12.31.16.00.00 (version=TLSv1 cipher=RC4-SHA bits=128/128); Tue, 20 Aug 2013 07:03:11 -0700 (PDT) Date: Tue, 20 Aug 2013 10:01:48 -0400 (EDT) From: gtodd@bellanet.org X-X-Sender: gtodd@ninga.iciti.internal To: freebsd-fs@freebsd.org Subject: Re: du which understands ZFS Message-ID: User-Agent: Alpine 2.00 (BSF 1167 2008-08-23) MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed 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: Tue, 20 Aug 2013 14:03:14 -0000 On Tue, 20 Aug 2013, Mark Felder wrote: > On Mon, Aug 19, 2013, at 22:51, aurfalien wrote: >> Hi, >> >> Is there a version of du which understands ZFS? >> >> Currently when running du I get this; >> >> Filesystem Size Used Avail Capacity Mounted on >> abyss 51T 50k 51T 0% /abyss >> abyss/PROJECT 72T 20T 51T 29% /abyss/PROJECTS >> abyss/PROJECTX 54T 2.6T 51T 5% /abyss/PROJECTSX >> >> The zpool of abyss is 75TB in size. >> > And do you want df to be aware of compression and deduplication, too? I > don't think this will show up in FreeBSD's df. Use the tools that ZFS > provides and you'll never get any unexpected surprises. I think if there were to be a "zfs aware" df it would show filesystem statistics for ufs and other "traditional" filesystems, but if/when it detected zfs it would output something like: "ZFS - free disk space does not apply" :-) or maybe some more helpful message about using zpool(1) zfs(1) etc. The Oracle docs say something like this: When you compare the space consumption that is reported by the df command with the zfs list command, consider that df is reporting the pool size and not just file system sizes. In addition, df doesn't understand descendent file systems or whether snapshots exist. If any ZFS properties, such as compression and quotas, are set on file systems, reconciling the space consumption that is reported by df might be difficult. http://docs.oracle.com/cd/E23824_01/html/821-1448/gbchp.html Perhaps a short addition to the df/du manual pages or a reference to the relevant zfs part of the FreeBSD handbook would make df "zfs aware".