diff --git a/pillar/role/postgresql/init.sls b/pillar/role/postgresql/init.sls index 612a558..a5ecfe4 100644 --- a/pillar/role/postgresql/init.sls +++ b/pillar/role/postgresql/init.sls @@ -12,6 +12,15 @@ profile: check_postgres_locks: "/usr/lib/nagios/plugins/check_postgres_locks --warning='60' --critical='total=50:waiting=1:exclusive=20'" check_postgres_wal_files: "/usr/lib/nagios/plugins/check_postgres_wal_files --critical='120' --warning='100'" +sysctl: + params: + ## https://www.postgresql.org/docs/current/static/kernel-resources.html + # Members of group my-hugetlbfs(2021) can allocate "huge" Shared memory segment + vm.hugetlb_shm_group: 1000 + # echo $(grep ^VmPeak /proc/$(head -n 1 /var/lib/pgsql/data/postmaster.pid)/status | awk '" " { print $2 }')/2048 | bc + vm.nr_hugepages: 6415 + vm.overcommit_memory: 2 + zypper: packages: postgresql: {}