Re: stats collector process high CPU utilization - Mailing list pgsql-performance

From Tom Lane
Subject Re: stats collector process high CPU utilization
Date
Msg-id 1116.1171038786@sss.pgh.pa.us
Whole thread Raw
In response to Re: stats collector process high CPU utilization  (Benjamin Minshall <minshall@intellicon.biz>)
Responses Re: stats collector process high CPU utilization  (Benjamin Minshall <minshall@intellicon.biz>)
List pgsql-performance
Benjamin Minshall <minshall@intellicon.biz> writes:
> When I checked on the server this morning, the huge stats file has
> returned to a normal size.  I set up a script to track CPU usage and
> stats file size, and it appears to have decreased from 90MB down to
> about 2MB over roughly 6 hours last night.  The CPU usage of the stats
> collector also decreased accordingly.

> The application logs indicate that there was no variation in the
> workload over this time period, however the file size started to
> decrease soon after the nightly pg_dump backups completed.  Coincidence
> perhaps?

Well, that's pretty interesting.  What are your vacuuming arrangements
for this installation?  Could the drop in file size have coincided with
VACUUM operations?  Because the ultimate backstop against bloated stats
files is pgstat_vacuum_tabstat(), which is run by VACUUM and arranges to
clean out any entries that shouldn't be there anymore.

It's sounding like what you had was just transient bloat, in which case
it might be useful to inquire whether anything out-of-the-ordinary had
been done to the database right before the excessive-CPU-usage problem
started.

            regards, tom lane

pgsql-performance by date:

Previous
From: Benjamin Minshall
Date:
Subject: Re: stats collector process high CPU utilization
Next
From: Gábriel Ákos
Date:
Subject: Recreate big table