ZFS ZFS received snapshot with -Fu will mount on reboot

Hello,
I'm confused about what it means for a dataset to be mounted and how zfs send & receive backup my system.

In my case, I backup my root filesystem on a pool located on another physical disk

Code:
zfs send -R zroot@snapshot | zfs receive -Fu external-disk-pool/backups/zroot

I use the the -u to make sure the dataset will not be mounted.

However, after a reboot, I checked the property of the dataset and found that it was mounted

Code:
# zfs get all external-disk-pool/backups/zroot
external-disk-pool/backups/zroot  mounted               yes                       -
external-disk-pool/backups/zroot  mountpoint            /zroot                    received
external-disk-pool/backups/zroot  canmount              on                        default

The difference with the actual zroot is that the value in the SOURCE column is received instead of local

It clearly says that it can mount and that it is mounted.

Also, when ls /external-disk-pool/backups/ I don't have any directory named zroot where I expect the backup files to show.

But when listing dataset with zfs list it shows the dataset and all snapshots.

Code:
# zfs list -t all -r external-disk-pool/backups/zroot
NAME                                                          USED  AVAIL  REFER  MOUNTPOINT
external-disk-pool/backups/zroot                                    4.72G  4.81T    96K  /zroot
external-disk-pool/backups/zroot@2025-03-11-2                          0B      -    96K  -
external-disk-pool/backups/zroot@2025-03-13                            0B      -    96K  -
external-disk-pool/backups/zroot/ROOT                               4.25G  4.81T    96K  none
external-disk-pool/backups/zroot/ROOT@2025-03-11-2                     0B      -    96K  -
external-disk-pool/backups/zroot/ROOT@2025-03-13                       0B      -    96K  -
...

Finally, more importantly, I can boot onto my system.

What did I misunderstood about how zfs send & receive tools to make backup?
 
-u option of zfs receive is effective only for zfs receive.
Received properties are not affected.
So, if the received properties say that the dataset can be mounted then it will be mounted when the pool is imported afresh, e.g., after a reboot, or after issuing zfs mount -a.
If you do not want it mounted then you need to override the corresponding properties (canmount, mountpoint).

P.S.
Regarding /external-disk-pool/backups, I think that you missed what mountpoint said.
 
Back
Top