On 2019-02-12 1:42 p.m., Andrei Borzenkov wrote: >> > > But if I understand what happens after your patch correctly, replacement > device still does not contain valid data until someone does scrub. So in > either case manual step is required to restore full redundancy. > > Or does "btrfs replace" restore content on replacement device automatically? >
It should.... Qu's example assumes the drive being replaced stays missing, in which case replace is copying all the data that should be on the missing drive from it's mirror source. There should be no difference between the data that used to be there and the data that didn't ever even get written there in the first place. For some reason, my mind last night got stuck on the hypothetical situation where a volume is mounted and used degraded, but then the missing device, presumably not faulty, get's re-added.. then things would go bad quickly. But I concede that scenario falls squarely in the "That's stupid don't do that" category.
signature.asc
Description: OpenPGP digital signature