Re: [developer] What vdev is picked as leading in mirror resilver proces?

2021-12-20 Thread openzfs via openzfs-developer
Thanks Richard for explaining this. I have done a couple of tests some time ago (you can find these in this pastebin: https://8n1.org/20024/2eb4). Results from these tests were that even for vdevs that have newer data (and other data for that matter) than other vdevs, it does not guarantee that

Re: [developer] What vdev is picked as leading in mirror resilver proces?

2021-12-20 Thread Richard Elling
First, resilvering is done at the dataset and snapshot layer (DSL) and not the vdev layer. Each txg commit has a monotonically increasing counter. So the dataset knows what data is written when. The resilver begins temporally at the oldest common time (as determined by the txg commit in the vdev's

[developer] What vdev is picked as leading in mirror resilver proces?

2021-12-20 Thread openzfs via openzfs-developer
I have a question regarding ZFS mirror resilvering. Consider a mirror with two vdevs: disk A and B. Disk B is hot-removed. Data is written to mirror (only written to disk A). The host is powered off. Disk B is cold-attached to the host and booted again. Zpool is imported. What vdev of the