btrfs-progs: filesystem: add 'du' command
authorMark Fasheh <mfasheh@suse.de>
Wed, 20 Jan 2016 21:49:26 +0000 (13:49 -0800)
committerDavid Sterba <dsterba@suse.com>
Mon, 14 Mar 2016 12:42:47 +0000 (13:42 +0100)
commita2e7ff1eae45ad77d80d31d8b793021364573a74
tree3449d277507736b67768ef96c7b4f69f91162c03
parentb5e7979ad27146d8f225b3bc7866c1b17942b6a0
btrfs-progs: filesystem: add 'du' command

'btrfs du' differs from regular du in that it will work to resolve which
blocks are shared between files in its list. This gives the user a more
accurate bytecount from which they can make decisions regarding management
of their file space.

We still print a total number of bytes counted (like regular du), but also
print the number of bytes which were found to have been shared amongst the
file set provided. From there it becomes trivial to calculate how much space
is exclusively owned.

Signed-off-by: Mark Fasheh <mfasheh@suse.de>
[ rename files to reflect the filesystem command group, add GPL v2
  file headers ]
Signed-off-by: David Sterba <dsterba@suse.com>
Makefile.in
cmds-fi-du.c [new file with mode: 0644]
cmds-fi-du.h [new file with mode: 0644]
cmds-filesystem.c