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

Background worker does not work properly in PostgreSQL 9.6 #141

Closed
keithf4 opened this issue Sep 28, 2016 · 2 comments
Closed

Background worker does not work properly in PostgreSQL 9.6 #141

keithf4 opened this issue Sep 28, 2016 · 2 comments

Comments

@keithf4
Copy link
Collaborator

keithf4 commented Sep 28, 2016

When monitoring the postgresql log, it has been observed that the loop inside the main, static background worker process that starts a dynamic background for each database using pg_partman does not appear to pause between dynamic bgw registrations. This causes excessive system load and can also cause postgresql log files to fill up extremely fast depending on logging levels.

This problem does not exist in 9.4 or 9.5

As a workaround for now, the bgw can be disabled in postgresql.conf by removing the entry from the shared_preload_libraries option and scheduling the run_maintenance() plpgsql function to run via an external process (cron, etc).

@keithf4
Copy link
Collaborator Author

keithf4 commented Dec 20, 2016

For anyone else that reads this, current status and discussion are under the below thread on the bugs list. Title of the thread is misleading as that was my initial diagnosis of the problem. The problem has now been narrowed down to a change in the Latch handling code in 9.6

https://www.postgresql.org/message-id/flat/CAB7nPqTrRjdcV_e4gJdNRqgHSdoX15vVwMqGpukFU6AfdS8mqg%40mail.gmail.com#CAB7nPqTrRjdcV_e4gJdNRqgHSdoX15vVwMqGpukFU6AfdS8mqg@mail.gmail.com

@keithf4
Copy link
Collaborator Author

keithf4 commented Dec 23, 2016

Root cause identified. Waiting on response to see if it's a bug that can be fixed or if it has to be worked around somehow

https://www.postgresql.org/message-id/flat/CAG1_KcDdckBorU3B7H-eGmpcGM9HQMnYfSNOKMU3HWsx-rPcrg%40mail.gmail.com#CAG1_KcDdckBorU3B7H-eGmpcGM9HQMnYfSNOKMU3HWsx-rPcrg@mail.gmail.com

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

No branches or pull requests

1 participant