linux-btrfs.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* bad file extent, some csum missing - how to check that restored volumes are error-free?
@ 2021-07-14 17:53 Dave T
  2021-07-14 22:51 ` Qu Wenruo
  0 siblings, 1 reply; 17+ messages in thread
From: Dave T @ 2021-07-14 17:53 UTC (permalink / raw)
  To: Btrfs BTRFS

I was running btrfs send | receive to a target host via ssh and the
operation suddenly failed in the middle.

I ran this check:

btrfs check /dev/mapper/${xyz}

This shows lots of these errors:
  root 329 inode 262 errors 1040, bad file extent, some csum missing
  root 329 inode 7070 errors 1040, bad file extent, some csum missing
  root 329 inode 7242 errors 1040, bad file extent, some csum missing
  root 329 inode 7246 errors 1040, bad file extent, some csum missing
  root 329 inode 7252 errors 1040, bad file extent, some csum missing
  root 329 inode 7401 errors 1040, bad file extent, some csum missing
  root 329 inode 7753 errors 1040, bad file extent, some csum missing
  root 330 inode 588 errors 1040, bad file extent, some csum missing
  root 334 inode 258 errors 1040, bad file extent, some csum missing
  root 334 inode 636 errors 1040, bad file extent, some csum missing
  root 334 inode 3151 errors 1040, bad file extent, some csum missing
  ...
  root 334 inode 184871 errors 1040, bad file extent, some csum missing
  root 334 inode 184872 errors 1040, bad file extent, some csum missing
  root 334 inode 184874 errors 1040, bad file extent, some csum missing

I rebooted without any problems, then connected an external USB HDD.
Then I created new snapshots and used btrfs send | receive to send
them to the USB HDD.

Next I installed a new SSD and restored the snapshots. Then I ran
"btrfs check --check-data-csum /dev/mapper/abc" on the new device. It
shows:

Opening filesystem to check...
Checking filesystem on /dev/mapper/abc
UUID: fac54a70-8c27-4cbe-a8d0-325e761ba01d
[1/7] checking root items
[2/7] checking extents
[3/7] checking free space cache
[4/7] checking fs roots
[5/7] checking csums against data
[6/7] checking root refs
[7/7] checking quota groups skipped (not enabled on this FS)
found 128390598656 bytes used, no error found
total csum bytes: 124046564
total tree bytes: 1335197696
total fs tree bytes: 1140211712
total extent tree bytes: 50757632
btree space waste bytes: 168388261
file data blocks allocated: 127058169856
 referenced 142833545216

What else can or should I do to be sure my restored snapshots are error-free?
What additional checks would you recommend on the new device?
The new device is a Samsung EVO 970 Plus.
The old device was a Samsung 950 Pro.

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

end of thread, other threads:[~2021-07-25 23:51 UTC | newest]

Thread overview: 17+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-07-14 17:53 bad file extent, some csum missing - how to check that restored volumes are error-free? Dave T
2021-07-14 22:51 ` Qu Wenruo
     [not found]   ` <CAGdWbB44nH7dgdP3qO_bFYZwbkrW37OwFEVTE2Bn+rn4d7zWiQ@mail.gmail.com>
     [not found]     ` <43e7dc04-c862-fff1-45af-fd779206d71c@gmx.com>
     [not found]       ` <CAGdWbB7Q98tSbPgHUBF+yjqYRBPZ-a42hd=xLwMZUMO46gfd0A@mail.gmail.com>
2021-07-15 22:19         ` Dave T
2021-07-15 22:30           ` Qu Wenruo
2021-07-15 22:49             ` Dave T
2021-07-16  1:05               ` Qu Wenruo
2021-07-16  2:32                 ` Qu Wenruo
2021-07-16 13:15                 ` Dave T
2021-07-16 13:28                   ` Qu Wenruo
2021-07-16 15:40                     ` Dave T
2021-07-16 23:06                       ` Qu Wenruo
2021-07-17  0:18                         ` Dave T
2021-07-17  0:25                           ` Qu Wenruo
2021-07-17  0:57                             ` Dave T
2021-07-17  0:59                               ` Qu Wenruo
2021-07-25 17:34                                 ` Dave T
2021-07-25 23:51                                   ` Qu Wenruo

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).