mirror of
https://github.com/RGBCube/ncc
synced 2025-07-28 02:27:44 +00:00
feat: tune kernel huge pages
This commit is contained in:
parent
c2acac6f3e
commit
7ef87ccfcd
1 changed files with 4 additions and 1 deletions
|
@ -1,6 +1,9 @@
|
|||
{ self, ... }: {
|
||||
imports = [(self + /modules/postgresql.nix)];
|
||||
|
||||
# postgres -C shared_memory_size_in_huge_pages -D /var/lib/postgresql/<version>.
|
||||
boot.kernel.sysctl."vm.nr_hugepages" = 5265;
|
||||
|
||||
# Generated by <https://pgconfigurator.cybertec.at/>
|
||||
services.postgresql.settings = {
|
||||
# Connectivity
|
||||
|
@ -11,7 +14,7 @@
|
|||
shared_buffers = "10240 MB";
|
||||
work_mem = "64 MB";
|
||||
maintenance_work_mem = "620 MB";
|
||||
huge_pages = "try"; # TODO: Tune kernel: <https://www.postgresql.org/docs/current/static/kernel-resources.html#LINUX-HUGE-PAGES>
|
||||
huge_pages = "try";
|
||||
effective_cache_size = "45 GB";
|
||||
effective_io_concurrency = 100;
|
||||
random_page_cost = 1.25;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue