RE: [HACKERS] Vacuum analyze bug CAUGHT

From: "Hiroshi Inoue" <Inoue(at)tpf(dot)co(dot)jp>
To: "Michael Simms" <grim(at)argh(dot)demon(dot)co(dot)uk>, <pgsql-hackers(at)postgreSQL(dot)org>
Subject: RE: [HACKERS] Vacuum analyze bug CAUGHT
Date: 1999-09-10 06:42:53
Message-ID: 000a01befb57$b55ab5e0$2801007e@cadzone.tpf.co.jp
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Hi

Vacuum couldn't preserve consistency without locking.
I'm anxious about locking for system tables.

>
> Hi
>
> Okee, I have caught the vacuum analyse crash that was giving me a load of
> grief
>

[snip]

>
> Then, in psql, I run and get the following result:
>
> -----------
>
> crashtest=> vacuum analyze;
> NOTICE: Rel pg_type: TID 4/3: InsertTransactionInProgress 129915
> - can't shrink relation
> NOTICE: Rel pg_attribute: TID 23/5: InsertTransactionInProgress
> 129915 - can't shrink relation
> NOTICE: Rel pg_attribute: TID 23/6: InsertTransactionInProgress
> 129915 - can't shrink relation
> NOTICE: Rel pg_attribute: TID 23/7: InsertTransactionInProgress
> 129915 - can't shrink relation
> NOTICE: Rel pg_attribute: TID 23/8: InsertTransactionInProgress
> 129915 - can't shrink relation
> NOTICE: Rel pg_attribute: TID 23/9: InsertTransactionInProgress
> 129915 - can't shrink relation
> NOTICE: Rel pg_attribute: TID 23/10: InsertTransactionInProgress
> 129915 - can't shrink relation
> NOTICE: Rel pg_attribute: TID 23/11: InsertTransactionInProgress
> 129915 - can't shrink relation
> NOTICE: Rel pg_attribute: TID 23/12: InsertTransactionInProgress
> 129915 - can't shrink relation
> NOTICE: Rel pg_class: TID 3/22: InsertTransactionInProgress
> 129915 - can't shrink relation

CREATE TABLE doesn't lock system tables till end of transaction.
It's a cause of these NOTICE messages.

Should we lock system tables till end of transaction ?

Moreover CREATE TABLE doesn't acquire any lock for pg_attribute
^^^^^^^^^^^^^^^^^^^^^^^^^^^^
while tuples are inserted into pg_attribute.
Concurrent vacuum may corrupt pg_attribute.

Regards.

Hiroshi Inoue
Inoue(at)tpf(dot)co(dot)jp

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Vadim Mikheev 1999-09-10 06:49:58 Re: [HACKERS] Vacuum analyze bug CAUGHT
Previous Message Jacques B. Dimanche 1999-09-10 06:25:47 Re: [ADMIN] How to use pg_log ?