From e1a10b1536ad7df486edb45d621521c96bc510af Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=B6rg=20Thalheim?= Date: Tue, 23 Jul 2019 09:04:03 +0100 Subject: [PATCH] enable fstrim on SSDs This will run TRIM once a week using a systemd timer. Running TRIM regularly will improves the performance and increases the SSDs lifespan. Since it is based on the utillinux no additional package is required. --- common/pc/ssd/default.nix | 2 ++ 1 file changed, 2 insertions(+) diff --git a/common/pc/ssd/default.nix b/common/pc/ssd/default.nix index af0b495..00922e6 100644 --- a/common/pc/ssd/default.nix +++ b/common/pc/ssd/default.nix @@ -4,4 +4,6 @@ boot.kernel.sysctl = { "vm.swappiness" = lib.mkDefault 1; }; + + services.fstrim.enable = lib.mkDefault true; }