Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unable to reflect postgresql parameter changes after executing playbook #550

Closed
kumarashish071092 opened this issue Jan 11, 2024 · 13 comments

Comments

@kumarashish071092
Copy link

kumarashish071092 commented Jan 11, 2024

I have added below entries in vars/main.yml file :

log_checkpoints = on
log_connections = on
log_disconnections =on
log_lock_waits=0
log_temp_files=0
log_autovacuum_min_duration=0
log_error_verbosity=default
log_statement=off
log_min_duration_statement=10
log_line_prefix = '%t [%p]: db=%d,user=%u,app=%a,client=%h '

After executing the playing the changes were not reflected in the database.

I have also added "pending_restart: false" and "pending_restart: true" and made modifications in the config_pgcluster.yml as well .

the query "select * from pg_settings where pending_restart is true;" is also giving null data.

what am I missing here?

@vitabaks
Copy link
Owner

vitabaks commented Jan 11, 2024

@kumarashish071092 please attach

  1. the variables file main.yml
  2. the ansible playbook execution log
  3. the result of the patronictl show-config command

@kumarashish071092
Copy link
Author

kumarashish071092 commented Jan 11, 2024 via email

@kumarashish071092
Copy link
Author

@vitabaks any update here? I am trying few options but still it is not reflecting.

@vitabaks
Copy link
Owner

vitabaks commented Jan 16, 2024

Please provide all information for analysis:

  1. the variables file main.yml
  2. the ansible playbook execution log
  3. the result of the patronictl show-config command

@vitabaks
Copy link
Owner

To change the Postgres configuration in a cluster using automation:

  1. change the parameters in the postgresql_parameters variable. You can also specify the pending_restart: true variable so that Postgres is automatically restarted if a parameter change requires a restart.
  2. run config_pgcluster.yml playbook to apply changes.

@vitabaks
Copy link
Owner

@kumarashish071092 Judging by ansible.log, you ran deploy_pgcluster.yml, but you need config_pgcluster.yml to manage the cluster parameters after deployment.

@vitabaks
Copy link
Owner

@kumarashish071092 Is the problem still relevant?

@sapisuper
Copy link

@vitabaks the problem still relevant, I also facing this problem.

@sapisuper
Copy link

please see the attachment, I will provided main.yml, ansible execution log and result from patronictl show-config

issue-postgresql_cluster.zip

@vitabaks
Copy link
Owner

vitabaks commented Mar 6, 2024

@sapisuper Have you tried this on version 1.9.0 according to the instructions?

@vitabaks
Copy link
Owner

vitabaks commented Mar 6, 2024

according to the ansible log, I see that the task "Update conf file" has been completed

TASK [../../roles/patroni/config : Update conf file "/etc/patroni/patroni.yml"] ***********************************************************************************************************************************************************
changed: [172.16.11.99]
changed: [172.16.11.25]
changed: [172.16.12.156]

but I do not see the task "Update postgresql parameters in DCS". Since no changes have been made to the DCS so you don't see the changes. Code here

Please attach an archive of the entire postgresql_cluster directory so that I can analyze all the changes you have made.

@sapisuper
Copy link

@vitabaks hi Vita, thanks for you feedback I will check later.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants