From: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
---|---|
To: | Jean-Christophe Praud <jc(at)steek(dot)com> |
Cc: | pgsql-general(at)postgresql(dot)org |
Subject: | Re: vacuum won't even start |
Date: | 2009-09-09 16:14:40 |
Message-ID: | 2131.1252512880@sss.pgh.pa.us |
Views: | Whole Thread | Raw Message | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-general |
Jean-Christophe Praud <jc(at)steek(dot)com> writes:
> I've a problem on a heavy loaded database: vacuums don't work since
> about a week. All I got is:
> mybase=# vacuum verbose analyze public.mytable;
> INFO: vacuuming "public.mytable"
> (I stop it after hours)
> Looking with top and iotop, I see the process takes some cpu and disk io
> time during several minutes, then it seems to fall asleep.
> The process isn't locked according to pg_stat_activity.
When vacuum wants to clean up a particular table page, it will wait
until no other process is examining that page; and this wait is not
visible in pg_locks. Perhaps you have got some queries referencing
those tables that have stopped midway and are just sitting?
Although pg_locks won't immediately show the wait, it could be useful
to help identify the culprit --- look for other processes holding
any type of lock on the table the vacuum is stuck on, and then go to
pg_stat_activity to see how old their current query is.
regards, tom lane
From | Date | Subject | |
---|---|---|---|
Next Message | Jean-Christophe Praud | 2009-09-09 16:27:15 | Re: vacuum won't even start |
Previous Message | Alvaro Herrera | 2009-09-09 16:11:45 | Re: vacuum won't even start |