[check_postgres] check_postgres_last_autovacuum

Peter Sheats psheats at pbpost.com
Tue Jul 15 13:56:18 UTC 2008


OK, thanks so much for the answers.  It makes sense now.  I guess my goal
was simply to make sure autovacuum was doing what it was supposed to do.  I
see now that it is probably more important to make sure important, highly
used tables are getting vacuumed.

I should be able to work with the script the way it is...perhaps simply
making the docs a little more clear would suffice for future users.

Peter

> 
> Upon re-reading this, the answer is yes to both questions. The script can
> only know when the last time something was autovacuumed, it has no way of
> knowing about why autovacuum may or may not have skipped vacuuming a
> each table the last time it ran. In the example above, you would need
> to either explicitly include the tables you want to check, or include the
> ones you do. You've got a wide range: the people_profile has not been
> autovaced in over a month, while auth_user was vacuumed 18 seconds ago.
> 
> If you would like the action to do something different, just describe
> exactly what you want it to do and we can see about coming up with a new
> action, but this is what this one is designed to do, I'm afraid. We could
> perhaps come up with an action that asks what the latest time *any*
> autovacuum run is (which I think is what Robert's ORDER BY 3 DESC was
> alluding to), but I'm not sure I see the usefulness of that, other than a
> crude measure of if autovacuum is running or not, of which there may be
> better ways to check.



More information about the Check_postgres mailing list