Modifying options for the existing cluster -- not work for me. And a few questions

  1. I tried to do it several times according to the instructions, I never managed to change the settings, I tried max_connections (PGO v1.2)

  2. It seemed to me a very dubious idea to apply changes in a custom config to start and stop the cluster. ( Pause/resume PostgreSQL Cluster )
    After all, many useful changes in the config require only a reload PG

  3. using “patronictl edit-config” to change the config doesn’t work here. It’s not mentioned in your documentation.

  4. Though, “kubectl edit configmaps cluster1-pgha-config” – works by magically changing the PG config.
    After that, it remains only to make the “patronictl reload\restart”

Is it right to do so?

Yes, and of course thanks for the PGO ))))

1 Like

Hello @Sergey_Zhuravlev ,

  1. How were you doing it?
  2. Sounds like a good improvement, agree. I will check with the team if we can easily change this. How critical is it for you? I assume pg config change is not a change that you would do daily.
  3. The intended way of doing things is through configmaps. (As you mention in (4)).
  4. Are you saying you have to restart patroni manually after changing the configmaps? I thought Pod restart is going to take effect there.
1 Like
  1. How were you doing it?

I did according to the instructions. I created a file with the name and contents as in the instructions. I checked that the deployment has a configmap with the right name. I paused then ran it according to the instructions - the desired changes did not occur in the config.

But this method does not seem good to me, so you can not deal with it)

Moreover, for the initial custom configuration with the bootstrap section, everything works as it should. And that seems to be enough for me.

  1. Sounds like a good improvement, agree. I will check with the team if we can easily change this. How critical is it for you? I assume pg config change is not a change that you would do daily.

every day, of course not

  1. The intended way of doing things is through configmaps. (As you mention in (4)).
  2. Are you saying you have to restart patroni manually after changing the configmaps? I thought Pod
    restart is going to take effect there.

restart only postgres with patronictl restart

The contents of postgresql.conf are 90% of the contents of the configmap cluster_name-pgha-config
But here are a few entries I don’t understand where they appear there, for example:

cluster_name
max_locks_per_transaction
max_prepared_transactions
max_replication_slots
max_worker_processes

and several others
The question is where do they get into postgresql.conf?

Maybe it’s better to ask a new question in the forum?

1 Like

I’m sorry, I noticed these parameters are set in the postgresql launch command for example:

postgres -D /pgdata/vi --config-file=/pgdata/vi/postgresql.conf --listen_addresses=0.0.0.0 --port=5432 --cluster_name=vi --wal_level=logical --hot_standby=on --max_connections=120 --max_wal_senders=6 --max_prepared_transactions=240 --max_locks_per_transaction=64 --track_commit_timestamp=off --max_replication_slots=10 --max_worker_processes=8 --wal_log_hints=on

1 Like