From 434b3bfe8130141f355b52b18ee4831d04085322 Mon Sep 17 00:00:00 2001 From: Ryan Yin Date: Thu, 21 Dec 2023 17:10:11 +0800 Subject: [PATCH] feat: enable zram --- modules/nixos/base/misc.nix | 2 ++ 1 file changed, 2 insertions(+) diff --git a/modules/nixos/base/misc.nix b/modules/nixos/base/misc.nix index 1ece2e0e..737be3d6 100644 --- a/modules/nixos/base/misc.nix +++ b/modules/nixos/base/misc.nix @@ -30,6 +30,8 @@ # Enable in-memory compressed devices and swap space provided by the zram kernel module. # By enable this, we can store more data in memory instead of fallback to disk-based swap devices directly, # and thus improve I/O performance when we have a lot of memory. + # + # https://www.kernel.org/doc/Documentation/blockdev/zram.txt zramSwap = { enable = true; # one of "lzo", "lz4", "zstd"