Skip to content

Commit 7ba58ef

Browse files
committed
nixos/system/boot: set some kernel memory pressure config
1 parent 8612132 commit 7ba58ef

1 file changed

Lines changed: 7 additions & 0 deletions

File tree

modules/nixos/system/boot/default.nix

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,13 @@ in
3333
boot = {
3434
initrd.systemd.network.wait-online.enable = false;
3535

36+
kernel.sysctl = {
37+
"vm.swappiness" = 10;
38+
"vm.vfs_cache_pressure" = 50;
39+
"vm.dirty_ratio" = 15;
40+
"vm.dirty_background_ratio" = 5;
41+
};
42+
3643
kernelParams =
3744
lib.optionals cfg.plymouth [ "quiet" ]
3845
++ lib.optionals cfg.silentBoot [

0 commit comments

Comments
 (0)