Uploaded image for project: 'Percona Monitoring and Management'
  1. Percona Monitoring and Management
  2. PMM-7917

Postgres exporter has high CPU usage during Restart


    • Bug
    • Status: Done
    • Critical
    • Resolution: Done
    • 2.15.0, 2.15.1
    • 2.17.0
    • None
    • 3
    • Yes
    • Yes
    • [obsolete] C/S Core


      During Release testing, we discovered that while restarting/upgrading PMM-Server, CPU usage for postgres client instances is very high.



      PMM Server Version: 2.15.1, which was upgraded to 2.16.0 RC
      PMM-Client Version: 2.15.1 which was upgraded to 2.16.0

      Postgres version: percona-distribution for postgresql v13

      Configured in push mode. 


      The issue for High CPU usage observed during: 

      1) Upgrading pmm-server, during the time server, was not reachable, and then the server was up, causing the agent to restart on the client instance.

      This scenario is represented in this picture. 

      2) Client upgrade when pmm-agent was restarted 

      please Note: haven't observed the same behavior on mysql and mongodb client instances. 

      Expected Behaviour: 

      CPU Usage for pmm-client instances with postgres during server upgrade (server not reachable) or pmm-agent restart should not be that high.  


      1) Start PMM-Server
      2) Setup Postgresql Client Instance
      3) Stop PMM-Server Docker container, wait for 5 mins
      4) Restart PMM-Server docker container
      5) Check CPU Usage on Postgresql Client Instance, look at output of top, pmm-agent process is consuming really high CPU, in the picture attached, you can see 197% CPU Usage during restart. 



      Both cases should be tested: PMM server stopped  and PMM serving update


        Issue Links



              denys.kondratenko Denys Kondratenko (Inactive)
              puneet.kala Puneet Kala
              1 Vote for this issue
              6 Start watching this issue



                Smart Checklist