linux-btrfs.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 0/2] btrfs-progs: provide command to dump checksums
@ 2019-04-08 13:31 Johannes Thumshirn
  2019-04-08 13:31 ` [PATCH 1/2] btrfs-progs: add 'btrfs inspect-internal csum-dump' command Johannes Thumshirn
  2019-04-08 13:31 ` [PATCH 2/2] btrfs-progs: completion: wire-up dump-csum Johannes Thumshirn
  0 siblings, 2 replies; 7+ messages in thread
From: Johannes Thumshirn @ 2019-04-08 13:31 UTC (permalink / raw)
  To: David Sterba; +Cc: Linux BTRFS Mailinglist, Johannes Thumshirn

Provide a command to dump checksums from 'btrfs inspect-internal'. This
command does a lookup for the given file's extents via FIEMAP (which is
handy as it already skips holes) and walks the checksum tree printing all
checksums of an extent.

It is tested against different layouts of files with and without holes,
but further testing done by others is highly appreciated.

It is also available on github @ https://github.com/morbidrsa/btrfs-progs/tree/inspect-csums

Changes since RFC:
* Complete re-write using ioctl()s (FIEMAP and BTRFS_TREE_SEARCH_V2) to
  gather the extent and checksum informtion, as per David's (private)
  comment.

* Re-named btrfs_lookup_csum() as per Qu's comment.

Johannes Thumshirn (2):
  btrfs-progs: add 'btrfs inspect-internal csum-dump' command
  btrfs-progs: completion: wire-up dump-csum

 Makefile                 |   3 +-
 btrfs-completion         |   4 +-
 cmds-inspect-dump-csum.c | 231 +++++++++++++++++++++++++++++++++++++++++++++++
 cmds-inspect.c           |   2 +
 commands.h               |   2 +
 5 files changed, 239 insertions(+), 3 deletions(-)
 create mode 100644 cmds-inspect-dump-csum.c

-- 
2.16.4


^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2019-04-09 10:30 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-04-08 13:31 [PATCH 0/2] btrfs-progs: provide command to dump checksums Johannes Thumshirn
2019-04-08 13:31 ` [PATCH 1/2] btrfs-progs: add 'btrfs inspect-internal csum-dump' command Johannes Thumshirn
2019-04-09  8:47   ` Nikolay Borisov
2019-04-09  9:43     ` Johannes Thumshirn
2019-04-09  9:34   ` Su Yue
2019-04-09 10:30     ` Johannes Thumshirn
2019-04-08 13:31 ` [PATCH 2/2] btrfs-progs: completion: wire-up dump-csum Johannes Thumshirn

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).