Skip to content

Instantly share code, notes, and snippets.

@joshuataylor
Created January 31, 2023 03:02
Show Gist options
  • Save joshuataylor/e3ca30aa53d49073ca232780726c497d to your computer and use it in GitHub Desktop.
Save joshuataylor/e3ca30aa53d49073ca232780726c497d to your computer and use it in GitHub Desktop.
# Dumps using zstd, with up to 32 threads.
# To silence zstd, add -q
# xfsdump -L mybackup -J - / | zstd -3 --threads=0 -o /backups/mybackup.zstd
xfsdump options (https://man.archlinux.org/man/xfsdump.8.en):
# -L session_label: Specifies a label for the dump session. It can be any arbitrary string up to 255 characters long.
# -J Inhibits the normal update of the inventory. This is useful when the media being dumped to will be discarded or overwritten.
# - sends output to stdout, for zstd to read
# / the partition directory
zstd options (https://man.archlinux.org/man/zstd.1.en):
# -3 the level of compression, from 1-22. 3 is the default.
# --threads=0 use all threads. 0 means "all threads". This is the magic, as ti uses all your CPU to compress.
# -o the backup location
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment