On Sep 1, 2004, at 5:09 PM, Matthew T. O'Connor wrote:

This is the first report I have heard of pg_autovacuum causing cpu usage spikes. When pg_autovacuum wakes up, it loops through all the databases checking for recent activity and decides if it is time to do something. I would think that pg_autovacuum wouldn't use much CPU during this time since it would be waiting a lot on connection startup and query responses from the server. I suppose that it could use a noticeable amount of CPU if you had a lot of databases for it to loop through and a very small connection time.

Well, I don't have a lot of databases, but I do have tens of thousands of tables, many of which have hundreds of thousands of rows. I don't know if that plays into things.


Are you using pooled connections?

No.

Also is this 7.4.x or 8.0 beta?

Oops. Sorry. It's 7.4.5, specifically.

Can you hook up a debugger and see what it's doing during the CPU spikes?

That's going to be a little tricky because it's a production environment. So far, the spikes haven't hurt too much because they don't last very long. I'll see if I can get anything similar to occur in our development environment.


-tfo


---------------------------(end of broadcast)--------------------------- TIP 7: don't forget to increase your free space map settings

Reply via email to