I’m having trouble understanding all the benefits of BTRFS and how they’ll apply to me.

Copy on Write and auto-compression seem like they will free up a bit of space.

What other practical benefits will I see from using BTRFS? Are there any noticeable performance benefits?

I use my computer to dual-boot. I don’t need snapshots because I have a custom script for a fresh install. I use my PC for gaming and work. I’ve got an NVMe, two SSD’s and one HDD.

Thanks in advance!

  • lloram239@feddit.de
    link
    fedilink
    arrow-up
    19
    ·
    edit-2
    1 year ago

    Copy on Write and auto-compression seem like they will free up a bit of space.

    That benefit is more theoretical, than practical. The majority of content you have on your drive will be content that is already heavily compressed at the file format level (e.g. images, movies, music) and where additional compression has no effect. So don’t expect any big savings out of the box, you get about 5-15% saving on a regular install.

    The real benefit are in the additional functionality it provides, e.g. you can use copy-on-write to make backups of large games before trying to mod them, backups that you might have previously avoided due to 100GB copies taking so long, with BTRFS it is done in a second.

    As for BTRFS snapshots you seem to have the wrong idea what they are for. With them you can create backups of your whole filesystem within a second, so you can have full backup in case something goes wrong. With the snapper daemon you can easily automate that make new snapshots every hour and expire them when no longer needed. That’s a really useful thing to have and with BTRFS it’s basically free.

    Another big advantage is the ease of partitioning, or the lack of a need for it, with BTRFS subvolumes all your volumes can share the same free space, while still being addressable as separate file systems, e.g. you can have subvolumes for / and /home, without having to guestimate how much space you might need in the future. Can also be abused to install multiple distributions on the same filesystem.

    Also checksums, BTRFS will tell you when your data goes bad.

    • Dreadful6644@lemmy.world
      link
      fedilink
      arrow-up
      5
      ·
      1 year ago

      I thought compression would not help much with disk space as well. I believe it depends on the use case. After switching to btrfs and enabling zstd compression, my Arch install reduced from 100GB to 60 GB in terms of used disk space. Most of the savings are from documentations of development packages.

      • pressanykeynow@iusearchlinux.fyi
        link
        fedilink
        arrow-up
        2
        ·
        1 year ago

        Just for reference

        spoiler

        ~> compsize -x / Processed 699693 files, 766975 regular extents (791577 refs), 360356 inline. Type Perc Disk Usage Uncompressed Referenced
        TOTAL 57% 39G 68G 69G
        none 100% 23G 23G 23G
        zstd 35% 15G 44G 45G
        prealloc 100% 69M 69M 104M
        ~> compsize -x /var/lib/flatpak Processed 340412 files, 115619 regular extents (256345 refs), 209687 inline. Type Perc Disk Usage Uncompressed Referenced
        TOTAL 55% 6.7G 12G 24G
        none 100% 3.6G 3.6G 6.6G
        zstd 36% 3.1G 8.5G 18G
        ~> compsize -x /home/user/.local/share/Steam Processed 219633 files, 1097250 regular extents (1111566 refs), 57457 inline. Type Perc Disk Usage Uncompressed Referenced
        TOTAL 84% 249G 295G 296G
        none 100% 203G 203G 203G
        zstd 50% 46G 91G 92G
        prealloc 100% 36M 36M 36M
        ~> compsize -x /home/user/.local/share/bottles Processed 18582 files, 33406 regular extents (33406 refs), 2366 inline. Type Perc Disk Usage Uncompressed Referenced
        TOTAL 53% 1.8G 3.3G 3.3G
        none 100% 959M 959M 959M
        zstd 36% 907M 2.4G 2.4G

        So it’s 29G(43%) from / + /home, 5.3G(45%) from flatpak packages, 46G(16%) from Steam, 1.5G(47%) from Bottles, ~82G total out of 380G(22%) which is nice