Skip to content

Instantly share code, notes, and snippets.

@raoulbhatia
Created August 23, 2020 20:15
Show Gist options
  • Save raoulbhatia/cd0e6eca037403c291eb1c2876759abb to your computer and use it in GitHub Desktop.
Save raoulbhatia/cd0e6eca037403c291eb1c2876759abb to your computer and use it in GitHub Desktop.

Dump of commands

BTRFS Restore

yes a | btrfs restore -i -m -S -x -o /dev/mapper/backup--vg-backup /mnt; echo $?

Find Corruption

find /mnt/backuppc/ -type f -exec sh -c 'for x; do cat "$x" > /dev/null || echo "$x"; done' -- {} + | tee broken_files.txt

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment