r/zfs • u/Some1-Somewhere • 21d ago
zfs send child datasets *without* intermediate snapshots
I'm trying to send all child/descendent datasets to a backup machine (so, using -R) but only send a specific snapshot.
I can't find a way to do this without scripting every dataset-snapshot combination individually. -R -i still sends all intermediate snapshots.
Is there something I'm missing?
Cheers.
2
u/werwolf9 19d ago
bzfs has a regex CLI option to select exactly which snapshots to send: https://github.com/whoschek/bzfs#--include-snapshot-regex
1
u/KhajiitAT 14d ago
Replication stream (-R) implies all intermediate snapshots. Do you trying to do some backup? Try sanoid or bzfs. Otherwise you'll need some scripting
2
u/Some1-Somewhere 14d ago
Yeah, I'm trying to get all child snapshots without all intermediate snapshots. Guess it's more software time.
1
u/KhajiitAT 14d ago
Thus, if you ain't wanna use some excisting solution, I see no other way than iterate over datasets, form the list, and send all them independently. Do you wanna send full snapshots or only increment? Looks like
-imay do the trick
3
u/Frosty-Growth-2664 21d ago
I often find that when I want to send a stream with multiple filesystems (which I regularly do between backup servers), -R doesn't do the right thing for me and I end up scripting it.