From: | Robert Haas <rhaas(at)postgresql(dot)org> |
---|---|
To: | pgsql-committers(at)postgresql(dot)org |
Subject: | pgsql: Avoid having autovacuum workers wait for relation locks. |
Date: | 2011-02-08 03:04:44 |
Message-ID: | E1Pmdsi-0001wG-DQ@gemulon.postgresql.org |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-committers |
Avoid having autovacuum workers wait for relation locks.
Waiting for relation locks can lead to starvation - it pins down an
autovacuum worker for as long as the lock is held. But if we're doing
an anti-wraparound vacuum, then we still wait; maintenance can no longer
be put off.
To assist with troubleshooting, if log_autovacuum_min_duration >= 0,
we log whenever an autovacuum or autoanalyze is skipped for this reason.
Per a gripe by Josh Berkus, and ensuing discussion.
Branch
------
master
Details
-------
http://git.postgresql.org/gitweb?p=postgresql.git;a=commitdiff;h=32896c40ca766146312b28a5a0eb3f66ca0300ed
Modified Files
--------------
doc/src/sgml/config.sgml | 5 +++-
src/backend/commands/analyze.c | 15 ++++++++++++-
src/backend/commands/vacuum.c | 39 ++++++++++++++++++++++++++--------
src/backend/postmaster/autovacuum.c | 14 +++++++++--
src/include/nodes/parsenodes.h | 3 +-
5 files changed, 61 insertions(+), 15 deletions(-)
From | Date | Subject | |
---|---|---|---|
Next Message | Heikki Linnakangas | 2011-02-08 07:06:21 | pgsql: Fix copy-pasto in description of pg_serial, and silence compiler |
Previous Message | Robert Haas | 2011-02-08 03:03:35 | Re: [COMMITTERS] pgsql: Implement genuine serializable isolation level. |