nixos/solitary: Tune PostgreSQL settings
This commit is contained in:
parent
d6c769d236
commit
8ce932e9af
1 changed files with 13 additions and 0 deletions
|
@ -529,6 +529,19 @@ in {
|
||||||
rum
|
rum
|
||||||
];
|
];
|
||||||
|
|
||||||
|
settings = {
|
||||||
|
max_connections = 128;
|
||||||
|
|
||||||
|
shared_buffers = "768MB";
|
||||||
|
huge_pages = "try";
|
||||||
|
huge_page_size = "2MB";
|
||||||
|
work_mem = "16MB";
|
||||||
|
|
||||||
|
effective_io_concurrency = 128;
|
||||||
|
|
||||||
|
wal_compression = "zstd";
|
||||||
|
};
|
||||||
|
|
||||||
initialScript = pkgs.writeText "init.psql" ''
|
initialScript = pkgs.writeText "init.psql" ''
|
||||||
CREATE ROLE "matrix-synapse";
|
CREATE ROLE "matrix-synapse";
|
||||||
CREATE DATABASE "matrix-synapse" OWNER "matrix-synapse"
|
CREATE DATABASE "matrix-synapse" OWNER "matrix-synapse"
|
||||||
|
|
Loading…
Reference in a new issue