From ce450454af770267c92878d949f0323f0232abe3 Mon Sep 17 00:00:00 2001 From: Danilo Reyes Date: Thu, 28 Sep 2023 18:33:06 -0600 Subject: [PATCH] fstab for btrfs snaper and organization --- server/fstab.nix | 101 +++++++++++++++++++++++++++++------------------ 1 file changed, 63 insertions(+), 38 deletions(-) diff --git a/server/fstab.nix b/server/fstab.nix index f611c6d..0d35282 100644 --- a/server/fstab.nix +++ b/server/fstab.nix @@ -89,10 +89,72 @@ "datacow" ]; }; + "/mnt/disk2" = { + device = "/dev/mapper/disk2"; + fsType = "btrfs"; + options = [ + "subvol=@data" + "compress=zstd:3" + "space_cache=v2" + "commit=120" + "datacow" + ]; + }; + "/mnt/seedbox" = { + device = "/dev/mapper/seedbox"; + fsType = "btrfs"; + options = [ + "subvol=@data" + "compress=zstd:3" + "space_cache=v2" + "commit=120" + "datacow" + ]; + }; + "/mnt/parity" = { + device = "/dev/disk/by-uuid/2e437a79-a246-411b-ac21-d03414b14305"; + fsType = "ext4"; + options = [ "defaults" ]; + }; + "/mnt/hnbox" = { + device = "/dev/mapper/hnbox"; + fsType = "btrfs"; + options = [ "compress=zstd:3" "space_cache=v2" "commit=120" "datacow" ]; + }; + "/boot" = { + device = "/dev/disk/by-uuid/c574cb53-dc40-46db-beff-0fe8a4787156"; + fsType = "ext4"; + }; + "/boot/efi" = { + device = "/dev/disk/by-uuid/CBE7-5DEB"; + fsType = "vfat"; + }; + # NEXTCCLOUD "/var/lib/nextcloud/data" = { device = "/mnt/disk1/nextcloud"; options = [ "bind" ]; }; + # BTRFS SNAPER + "/mnt/btrfs/disk1" = { + device = "/dev/mapper/disk1"; + fsType = "btrfs"; + options = [ "compress=zstd:3" "space_cache=v2" "commit=120" "datacow" ]; + }; + "/mnt/btrfs/disk2" = { + device = "/dev/mapper/disk2"; + fsType = "btrfs"; + options = [ "compress=zstd:3" "space_cache=v2" "commit=120" "datacow" ]; + }; + "/mnt/btrfs/seedbox" = { + device = "/dev/mapper/seedbox"; + fsType = "btrfs"; + options = [ "compress=zstd:3" "space_cache=v2" "commit=120" "datacow" ]; + }; + # Jellyfin RO + "/mnt/jellyfin/external" = { + device = "/mnt/seedbox/external"; + options = [ "bind" "ro" ]; + }; "/mnt/jellyfin/media" = { device = "/mnt/disk1/multimedia/media"; options = [ "bind" "ro" ]; @@ -105,44 +167,7 @@ device = "/mnt/seedbox/other/P90x.Mega.Pack"; options = [ "bind" "ro" ]; }; - "/mnt/disk2" = { - device = "/dev/mapper/disk2"; - fsType = "btrfs"; - options = [ - "subvol=@data" - "compress=zstd:3" - "space_cache=v2" - "commit=120" - "datacow" - ]; - }; - "/mnt/hnbox" = { - device = "/dev/mapper/hnbox"; - fsType = "btrfs"; - options = [ "compress=zstd:3" "space_cache=v2" "commit=120" "datacow" ]; - }; - "/mnt/seedbox" = { - device = "/dev/mapper/seedbox"; - fsType = "btrfs"; - options = [ "compress=zstd:3" "space_cache=v2" "commit=120" "datacow" ]; - }; - "/mnt/jellyfin/external" = { - device = "/mnt/seedbox/external"; - options = [ "bind" "ro" ]; - }; - "/mnt/parity" = { - device = "/dev/disk/by-uuid/2e437a79-a246-411b-ac21-d03414b14305"; - fsType = "ext4"; - options = [ "defaults" ]; - }; - "/boot" = { - device = "/dev/disk/by-uuid/c574cb53-dc40-46db-beff-0fe8a4787156"; - fsType = "ext4"; - }; - "/boot/efi" = { - device = "/dev/disk/by-uuid/CBE7-5DEB"; - fsType = "vfat"; - }; + # NFS "/export/disk1" = { device = "/mnt/disk1"; options = [ "bind" ];