
On Wed, 10 Dec 2014, Toby Corkindale <toby@dryft.net> wrote:
On 10 December 2014 at 13:06, Russell Coker <russell@coker.com.au> wrote:
On Wed, 10 Dec 2014, Toby Corkindale <toby@dryft.net> wrote:
Let's say I want to have 2TB of storage. In that case, I'd purchase two 2TB drives, mirror them in btrfs, done.[1]
mkfs.btrfs -m raid1 -d raid1 /dev/disk/by-id/foo1 /dev/disk/by-id/foo2
Actually buy at least 3TB disks. The MSY prices are $92 and $123
[snip]
I was really just using the size as an arbitrary amount for example's sake. I haven't looked recently to see what sort of sizes are good value, but I would expect people using this advice to do so, yes.
I know, but avoiding drive replacements as much as possible is a really good strategy that should be considered.
Note that "btrfs replace" is MUCH faster than a balance or delete operation.
Thanks Russell, that's interesting to know. Might not be an option for someone if they only have four or five ports, but sounds good if you do have a spare.
Even if you have no spare ports it's an option. Transferring data over USB 2.0 is usually a lot faster than a BTRFS balance or remove. So one option would be to put the disk to be replaced in a USB-SATA caddy and for the duration of the replace operation. The "btrfa replace" operation has a -r flag to only read from the original disk if the other disks don't have the data. When you use this in the normal situation there will be almost no reads from the original disk. BTRFS balance and remove are REALLY slow. It's so slow that it's the subject of regular bug reports on the mailing list.
Another possibility is to use an old PC with a few disks in a RAID-5 or RAID-6 array for local backup. I've been considering getting a large tower PC filled with old disks (~1TB capacity) in a BTRFS RAID-5 configuration for local backup. The noise and heat of all the disks wouldn't matter as I'd only turn it on when doing a backup.
You start getting into higher failure rates there -- old drives, lots of them, frequently getting spun up and down..
True. But RAID-5 with checksums should cope with that reasonably well, and RAID-6 is even better. The way ZFS uses multiple copies of metadata is the best, hopefully BTRFS will get that feature soon. -- My Main Blog http://etbe.coker.com.au/ My Documents Blog http://doc.coker.com.au/