Open zard14 opened 1 year ago
@tshcherban is this because we had a fix for it before, but now we have upstream changes: https://github.com/percona/postgres_exporter/blob/main/cmd/postgres_exporter/server.go#L72
https://github.com/prometheus-community/postgres_exporter/pull/655
?
Description
HI I check the document, and it can limit monitor account conncetion number.
ALTER USER monitor CONNECTION LIMIT 2;
https://docs.percona.com/percona-monitoring-and-management/setting-up/client/postgresql.html#create-a-database-account-for-pmm
Because I find out if I have five user db, each userdb will open 4 connections, and there will be 20 ilde connctions finally.
If I limit user account "monitor" number as 2, there are only two connections right, but there will be bunch of fatal errors in postgresql log like this.
2022-11-16 01:07:52.590 -04 [493080] monitor@postgres 192.168.XXX.XXX(44096)FATAL: too many connections for role "monitor"
All suggestions are welcome, Thank you!
Expected Results
1.No fatal errors in postgresql
Actual Results
bunch of fatal errors in postgresql log like this.
2022-11-16 01:07:52.590 -04 [493080] monitor@postgres 192.168.XXX.XXX(44096)FATAL: too many connections for role "monitor"
Version
pmm server 2.32 pmm client 2.32
Steps to reproduce
No response
Relevant logs
No response
Code of Conduct