From 514ccb4258b9810f899ceacc0cb6d6485bcbee1f Mon Sep 17 00:00:00 2001 From: Simon Gardling Date: Tue, 3 Mar 2026 15:05:59 -0500 Subject: [PATCH] postgresql: disable full_page_writes --- services/postgresql.nix | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/services/postgresql.nix b/services/postgresql.nix index 474ebe2..3fb4463 100644 --- a/services/postgresql.nix +++ b/services/postgresql.nix @@ -19,6 +19,14 @@ enable = true; package = pkgs.postgresql_16; dataDir = service_configs.postgres.dataDir; + settings = { + # ZFS provides checksumming and atomic writes, making PostgreSQL's + # full_page_writes redundant. Disabling reduces write amplification + # and SSD wear on the zpool. + # Did this in conjunction with setting recordsize=8k + # on the zvolume this is on + full_page_writes = false; + }; }; }