+ if [[ $destroy_local_filesystem_on_full_replicate == 1 ]]; then
+ $zfs destroy -r ${local_pool}/${remote_fs}
+ if [ $? != 0 ]; then
+ echo "-E- remote full $zfs destroy command failed"
+ exit 1
+ fi
+ else
+ echo "-W- We need to destroy a local filesystem before receiving a full stream."
+ echo " However, since the option is set to prevent this, skipping replicate operation."
+ echo "$zfs destroy -r ${local_pool}/${remote_fs} not able to run" | /usr/bin/mailx -s "zfs-replicate-all unable to destroy local filesystem" $mailto