Am Sun, 3 Apr 2016 18:51:07 -0600 schrieb Chris Murphy <lists@xxxxxxxxxxxxxxxxx>: > > BTW: Is it possible to use my backup drive (it's btrfs single-data > > dup-metadata, single device) as a seed device for my newly created > > btrfs pool (raid0-data, raid1-metadata, three devices)? > > Yes. > > I just tried doing the conversion to raid1 before and after seed > removal, but with the small amount of data (4GiB) I can't tell a > difference. It seems like -dconvert=raid with seed still connected > makes two rw copies (i.e. there's a ro copy which is the original, and > then two rw copies on 2 of the 3 devices I added all at the same time > to the seed), and the 'btrfs dev remove' command to remove the seed > happened immediately, suggested the prior balances had already > migrated copies off the seed. This may or may not be optimal for your > case. > > Two gotchas. > > I ran into this bug: > btrfs fi usage crash when volume contains seed device > https://bugzilla.kernel.org/show_bug.cgi?id=115851 > > And there is a phantom single chunk on one of the new rw devices that > was added. Data,single: Size:1.00GiB, Used:0.00B > /dev/dm-8 1.00GiB > > It's still there after the -dconvert=raid1 and separate -mconvert=raid > and after seed device removal. A balance start without filters removes > it, chances are had I used -dconvert=raid1,soft it would have vanished > also but I didn't retest for that. Good to know, thanks. > > I guess the > > seed source cannot be mounted or modified... > > ? In the following sense: I should disable the automounter and backup job for the seed device while I let my data migrate back to main storage in the background... My intention is to use fully my system while btrfs migrates the data from seed to main storage. Then, afterwards I'd like to continue using the seed device for backups. I'd probably do the following: 1. create btrfs pool, attach seed 2. recreate my original subvolume structure by snapshotting the backup scratch area multiple times into each subvolume 3. rearrange the files in each subvolume to match their intended use by using rm and mv 4. reboot into full system 4. remove all left-over snapshots from the seed 5. remove (detach) the seed device 6. rebalance 7. switch bcache to write-back mode (or attach bcache only now) -- Regards, Kai Replies to list-only preferred. -- To unsubscribe from this list: send the line "unsubscribe linux-btrfs" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html
