diff options
author | aszlig <aszlig@nix.build> | 2022-03-24 20:16:17 +0100 |
---|---|---|
committer | aszlig <aszlig@nix.build> | 2022-03-24 20:16:17 +0100 |
commit | 39b6928367e79fe098b6d21c8eb39fe94e851a15 (patch) | |
tree | 1dbf8d6cff683f18d1f94c9b11b7562802ccfb1b /machines/aszlig/dnyarri.nix | |
parent | 0d6339c1327d07f8bcb5dfe05d1ed54551baf2d9 (diff) |
machines/dnyarri: Use async discard for root FS
Another thing that was lurking around in configuration.nix, so it has been battle-tested for weeks. Given that all the layers from the hardware up to the LUKS container with the filesystem support discard, it does make sense to enable it. The disadvantage of using discard with LUKS is that attackers can now gain information about the file system in use. However, this is already public knowledge so given that discard increases performance, I decided to enable it despite some warnings[1] out there. [1]: https://asalor.blogspot.com/2011/08/trim-dm-crypt-problems.html Signed-off-by: aszlig <aszlig@nix.build>
Diffstat (limited to 'machines/aszlig/dnyarri.nix')
-rw-r--r-- | machines/aszlig/dnyarri.nix | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/machines/aszlig/dnyarri.nix b/machines/aszlig/dnyarri.nix index 68498109..89f4434c 100644 --- a/machines/aszlig/dnyarri.nix +++ b/machines/aszlig/dnyarri.nix @@ -80,7 +80,9 @@ in { "/" = { label = "dnyarri-root"; fsType = "btrfs"; - options = [ "autodefrag" "space_cache" "compress=zstd" "noatime" ]; + options = [ + "autodefrag" "space_cache" "compress=zstd" "noatime" "discard=async" + ]; }; }; |