TrueNAS Replication Task - Option to prevent auto-mount after replication is finished

Breit

Dabbler
Joined
Oct 4, 2016
Messages
25
Is there an option for replication tasks to prevent replicated datasets to get automatically mounted?

This is my scenario:
I've got a server with FreeBSD 12.2 on it that has a ZFS boot pool. Now I wan't my TrueNAS box at home to pull snapshots of this servers boot pool as backups.

I've configured the replication task as a PULL task using SSH and have the zroot dataset from the server as 'source' and some backup dataset on the TrueNAS box as 'destination'.
The replication runs fine so far, but as soon as the replication of one of the child dataset is complete, this dataset gets mounted on the TrueNAS box with the mountpoint configured on the original zroot dataset. This is dangerous, as the mountpoints for those datasets interfere with the filesystem from the TrueNAS box. For instance zroot/var/log gets mounted to /var/log and so on...

I've tried to set the canmount property of the backup dataset into wich the replication stream is written to 'off' or 'noauto' and excluded the canmount property from the replication, but that does not help. The datasets get mounted nonetheless.

The only thing that worked so far is setting the jailed property to 'on' on the backup dataset (destination).

I'm new to these replication tasks and might have missed something?!

Previously I used a backup script that I had written that was running on the server with a cronjob, which takes a recursive backup snapshot of the boot pool and used to sends this over to my NAS using zfs send|recv into a dedicated backup jail I had created where only the backup dataset is visible and only this specific host could connect via SSH. However sending ZFS filesystems over SSH does not seem to work anymore since I upgraded my FreeNAS-11.3-U5 to TrueNAS-12.0-U1. I always get a 'cannot receive new filesystem stream: invalid backup stream' for some reason. The exact same send|recv option without SSH involved work locally on either the TrueNAS box or FreeBSD server. So this must have something to do with SSH.
 
Last edited:

seldo

Dabbler
Joined
Jan 4, 2021
Messages
47
Same question here!
I'd like my backup to not mount so I don't have to think if the directories I see are from my working data set or my backup set.
 
Top