I would like to create a script to sync the full tree of all zfs filesystems of a newly installed FreeBSD.
The list of the filesystems is as follows:
zroot
zroot/ROOT
zroot/ROOT/default
zroot/home
zroot/home/peter
zroot/tmp
zroot/usr
zroot/usr/ports
zroot/usr/src
zroot/var
zroot/var/audit
zroot/var/crash
zroot/var/log
zroot/var/mail
zroot/var/tmp
Another filesystems could be created during install or after it (for example, zroot/home/<user> or zroot/ROOT/default/<update>). The existing zrep configuration should continue to work in such case, only new filesystems need to be added to the sync list.
As I understand, the recursive replication is not reliable, the filesystems should be synced one-by-one. As I mentioned in #166, zrep data is propagated to the child filesystems, so the only approach would be ZREPTAG defined separately for EVERY filesystem to sync. It looks a bit hard to manage and snapshot deletion needs to be debugged/validated, so I would like to ask if any other approach looks possible before starting developing this solution.
I would like to create a script to sync the full tree of all zfs filesystems of a newly installed FreeBSD.
The list of the filesystems is as follows:
Another filesystems could be created during install or after it (for example,
zroot/home/<user>orzroot/ROOT/default/<update>). The existing zrep configuration should continue to work in such case, only new filesystems need to be added to the sync list.As I understand, the recursive replication is not reliable, the filesystems should be synced one-by-one. As I mentioned in #166, zrep data is propagated to the child filesystems, so the only approach would be ZREPTAG defined separately for EVERY filesystem to sync. It looks a bit hard to manage and snapshot deletion needs to be debugged/validated, so I would like to ask if any other approach looks possible before starting developing this solution.