Elektrine lite

← Feed

@GnuLinuxDude@lemmy.ml

Post #429038

2026-02-23 17:24 UTC

I’m installing 3x2TB HDDs into my desktop pc. The drives are like-new. Basically they will replace an ancient 2tb drive that is failing. The primary purpose will basically be data storage, media, torrents, and some games installed. Losing the drives to failure would not be catastrophic, just annoying. So now I’m faced with how to set up these drives. I think I’d like to do a RAID to present the drives as one big volume. Here are my thoughts, and hopefully someone can help me make the right choice: RAID0: Would have been fine with the risk with 2 drives, but 3 drives seems like it’s tempting fate. But it might be fine, anyhow. RAID1: Lose half the capacity, but pretty braindead setup. Left wondering why pick this over RAID10? RAID10: Lose half the capacity… left wondering why pick this over RAID1? RAID5: Write hole problem in event of sudden shutoff, but I’m not running a data center that needs high reliability. I should probably buy a UPS to mitigate power outages, anyway. Would the parity calculation and all that stuff make this option slow? I’ve also rejected considering things like ZFS or mdadm, because I don’t want to complicate my setup. Straight btrfs is straightforward. I found this page where the person basically analyzed the performance of different RAID levels, but not with BTRFS. larryjordan.com/…/real-world-speed-tests-for-diff… (PDF link with harder numbers in the post). So I’m not even sure if his analysis is at all helpful to me. If anyone has thoughts on what RAID level is appropriate given my use-case, I’d love to hear it! Particularly if anyone knows about RAID1 vs RAID10 on btrfs.

Replies (10)

  • @kaki@sh.itjust.works 2026-02-23 18:02

    I setup BTRFS RAID1 on my NAS recently, here's what I gathered on BTRFS RAID levels: - RAID1 vs RAID10: * RAID10 theoretically offers better performance (stripping), but the BTRFS implementation isn't well optimized so you don't get that much of a performance boost compared to RAID1. * RAID1 may also waste less disk space when using disks of different sizes compared to RAID10, here's a simulator to check: https://www.carfax.org.uk/btrfs-usage/ . In your case it doesn't matter since all your disks are the same size. - RAID5/6: * It's not only the write-hole, scrubbing is also broken (huge read amplification make performance unusable on large file systems). * RAID5/6 is slower than everything else (not a BTRFS problem, it's just parity calculations). * I believe the BTRFS developers are getting (relatively) closer to fixing RAID5/6 these days, but they still don't recommend using it. Switching between BTRFS RAID modes can be done pretty easily later without creating a new filesystem, so you could always switch to it later once it's fixed. In your case, I'd probably use RAID1 or RAID10 for data, and RAID1c3 for metadata. EDIT: just saw that you don't care that much about losing the data. In that case you don't need any fancy RAID thing, as someone else said just add all your disks in single mode (the default), way simpler and you don't lose any disk space.

    Open ##2968428

  • @MentalEdge@sopuli.xyz 2026-02-23 18:05

    If you just want to combine their capacities, and don't need redundancy, just use single mode? No need to use a raid mode for multi-device btrfs. Edit: You could also do two volumes. Split each drive in half. Use the first half of each drive for a raid1c2 volume to get 1.5TB of redundant storage for important data. Use the second half of each drives for a raid0 volume to get 3TB of faster storage for games.

    Open ##2968429

  • @Shimitar@downonthestreet.eu 2026-02-23 17:46

    Setup a raid5 with mdadm, format that with btrfs. Using btrfs for raid is not recomended by btrfs itself. But setting up a raid5 mdadm array is very simple and let you use btrfs. I agree that zfs is too much. Edit: with three drives, raid1 doesn't make sense. Raid10 i never seen it in over 20y being used by anybody.

    Open ##2968430

  • @Svinhufvud@sopuli.xyz 2026-02-23 18:36

    With 3 drives I would go with BTRFS RAID1. You get half the capacity, can lose any one of the drives, and it is really simple. If you were to add drives later on to increase the array size, I might consider RAID10, but if you plan on sticking with 3 drives, I would go with RAID1 instead. RAID0 offers no redundancy, so I would skip it. RAID5/6 are [not recommended](https://btrfs.readthedocs.io/en/latest/btrfs-man5.html#raid56-status-and-recommended-practices) for use in production.

    Open ##2968431

  • @antsu@discuss.tchncs.de 2026-02-23 18:32

    Briefly addressing the RAID types you mentioned: - **RAID-0:** OH NO OH GOD PLEASE NO AHHHHHHH - **RAID-1:** There's nothing wrong with it, but it feels very weird to me that BTRFS can do RAID-1 over 3 disks. It's still technically 2 copies of every block, meaning you can in theory lose any single drive and still recover the data, but idk, it just *feels wrong*. - **RAID-10:** Again, weird that BTRFS allows this with an odd amount of disks. From what I can find, this has no advantage over RAID-1 with 3 disks and can in fact perform worse. - **RAID-5:** It's probably fine if you have backups, and you get the most usable space out of your disks, but performance will take a hit, and scrubs are terribly slow. Now, you mentioned not wanting ZFS due to complexity, but really, it is no more complex to manage than BTRFS. It's fairly easy to get it working on any modern Linux distro (Ubuntu has support out-of-the-box, Debian has it packaged as a DKMS module, Arch has it in AUR, and so on). With ZFS, you could create a RAID-Z1 (equivalent to a RAID-5) without any of the performance penalties or risks that BTRFS RAID-5 has. Both have pretty much them same features, with the main difference that ZFS can't be "re-balanced" to a different disk layout like BTRFS can, but it will also generally not corrupt your data if you look at it wrong. Everything else maps pretty much 1:1 between them. Both support: - Transparent compression - Transparent checksums - Scrubbing - Snapshots - Block-level transfers (btrfs-send / zfs-send) - Fairly intuitive CLI - Filesystem (BTRFS) == Pool (ZFS) - Subvolume (BTRFS) == Dataset (ZFS)

    Open ##2968432

  • @notagoblin@lemmy.world 2026-02-23 22:02

    I built a franken-server from some bits awhile ago using old disks of different sizes. The disks were formatted individually with BTRFS (Mostly any FS would do) and then a mergerfs pool setup across all the drives. I got full use of all my old drives. Sizes varied between 1TB and 6TB, gave me 20Tb of usable space. Mergerfs has no redundancy and no parity although it is designed to work with snapraid. If a drive is lost only the data on that drive is lost, you just need to replace that one drive, the data on the other drives remains intact. The loss of a drive in a Raid0 or JBOD array, results in the loss of the whole array and all the data. Some sort of backup is probarbly appropriate. https://trapexit.github.io/mergerfs/latest/ Might be worth a look.

    Open ##2968433

  • @Cyber@feddit.uk 2026-02-24 22:44

    I built my own NAS from Arch (btw) and wanted to just install standard packages and use standard tools (ie gparted, clonezilla, etc). I've got btrfs RAID5 running fine. Had loads of power outages (we had water meeting electrics) and have no problems at all. Of course, RAID is not a backup, so all my important stuff is on Hetzner too. I don't really follow the ZFS news, but I understand that resizing / adding new drives is / was a problem, plus, back when I built this, I would've needed kernel patching... there's a higher chance of those causing a problem - for my use case - than btrfs, so if you're like me, just crack on and enjoy the easy life.

    Open ##2968434

  • @doodoo_wizard@lemmy.ml 2026-02-24 03:30

    It kinda seems like you don’t need to be using btrfs. If the possibility of your kernel updates breaking scared you off zfs, a system that has been in very widespread use for just going off the dome twice as long as btrfs has been around, why do you think using btrfs is somehow okay? I’m not trying to suggest you use zfs either. E: I went and looked and zfs has been in widespread use for around twice as long as btrfs has been marked as *stable*. It’s worth mentioning too that since being marked as stable btrfs has suffered from a silent data corruption bug.

    Open ##2968435

  • @mech@feddit.org 2026-02-23 17:26

    >guidance on BTRFS RAID Don't.

    Open ##2968436

  • @GnuLinuxDude@lemmy.ml 2026-02-23 20:23

    Damn. And I thought 3 disks was risky...

    Open ##2968451