vitabaks / postgresql_cluster

PostgreSQL High-Availability Cluster (based on Patroni). Automating with Ansible.
https://postgresql-cluster.org
MIT License
1.62k stars 407 forks source link

Automatic configuration of HugePages #697

Closed vitabaks closed 2 months ago

vitabaks commented 3 months ago

Feature: Automatic Configuration of HugePages

Tasks:

  1. Automatic Configuration of HugePages:

    • Implement automatic detection and configuration of the vm.nr_hugepages parameter.
    • Link to the current setting: system.yml#L56.
  2. Pre-check:

    • Add a pre-check for the huge_pages parameter in PostgreSQL.
    • If the huge_pages parameter is set to on, verify that the vm.nr_hugepages kernel parameter is configured with a sufficient value.

Consider sponsoring the project via GitHub or Patreon

rcknr commented 2 months ago

I have just enabled this in my cluster with 1GB pages, so I could contribute to this feature.

vitabaks commented 2 months ago

@rcknr Thank you, I'm already working on it, I'll publish a PR soon and I'll be glad if you take part in the testing.

vitabaks commented 2 months ago

PR: https://github.com/vitabaks/postgresql_cluster/pull/713