On Tue, Nov 04, 2014 at 11:28:39AM -0700, Chris Murphy wrote: > On Nov 3, 2014, at 9:31 PM, Zygo Blaxell wrote: > > It needs to be more than a sequential number. If one of the disks > > disappears we need to record this fact on the surviving disks, and also > > cope with _both_ disks claiming to be the "surviving" one. > > I agree this is also a problem. But the most common case is where we > know that sda generation is newer (larger value) and most recently > modified, and sdb has not since been modified but needs to be caught > up. As far as I know the only way to do that on Btrfs right now is > a full balance, it doesn't catch up just be being reconnected with a > normal mount. The data on the disks might be inconistent, so resynchronization must read from only the "good" copy. A balance could just spread corruption around if it reads from two out-of-sync mirrors. (Maybe it already does the right thing if sdb was not modified...?). The full resync operation is more like btrfs device replace, except that it's replacing a disk in-place (i.e. without removing it first), and it would not read from the non-"good" disk. > > Chris Murphy-- > To unsubscribe from this list: send the line "unsubscribe linux-btrfs" in > the body of a message to majordomo@vger.kernel.org > More majordomo info at http://vger.kernel.org/majordomo-info.html