Skip to content

Instantly share code, notes, and snippets.

@qxzg
Created April 24, 2020 09:52
Show Gist options
  • Save qxzg/357d091a789437c3f9980c175bacde0c to your computer and use it in GitHub Desktop.
Save qxzg/357d091a789437c3f9980c175bacde0c to your computer and use it in GitHub Desktop.
zfs incremental sync
#!/bin/bash
zfs snap -r nvme@end
zfs rollback -r main-pool/backup/nvme@begen
zfs send -R -I nvme@begen nvme@end | zfs receive -v main-pool/backup/nvme
zfs destroy -R nvme@begen
zfs destroy -R main-pool/backup/nvme@begen
zfs rename -r nvme@end nvme@begen
zfs rename -r main-pool/backup/nvme@end main-pool/backup/nvme@begen
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment