Re: CREATE TABLE, load and freezing - Mailing list pgsql-hackers

From ITAGAKI Takahiro
Subject Re: CREATE TABLE, load and freezing
Date
Msg-id 20080228183958.5F5A.52131E4D@oss.ntt.co.jp
Whole thread Raw
In response to CREATE TABLE, load and freezing  ("Pavan Deolasee" <pavan.deolasee@gmail.com>)
Responses Re: CREATE TABLE, load and freezing  ("Pavan Deolasee" <pavan.deolasee@gmail.com>)
Re: CREATE TABLE, load and freezing  (Florian Pflug <fgp.phlo.org@gmail.com>)
List pgsql-hackers
"Pavan Deolasee" <pavan.deolasee@gmail.com> wrote:

> In a typical scenario, user might create a table and load data in the table as
> part of a single transaction (e.g pg_restore). In this case, it would help if we
> create the tuples in the *frozen* state to avoid any wrap-around related issues
> with the table.

Sounds cool. I recommended users to do VACUUM FREEZE just after initial
loading, but we can avoid it with your method.

> Without this, very large read-only tables would require one round of
> complete freezing if there are lot of transactional activities in the other parts
> of the database. And when that happens, it would generate lots of unnecessary
> IOs on these large tables.

To make things worse, the freezing day comes at once because the first restore
is done in a single or near transactions; The wraparound timings of many
tables are aligned at the same time. Freezing copy will be the solution.

Regards,
---
ITAGAKI Takahiro
NTT Open Source Software Center




pgsql-hackers by date:

Previous
From: Dimitri Fontaine
Date:
Subject: Re: Varlena Type Creation
Next
From: "Pavan Deolasee"
Date:
Subject: Re: CREATE TABLE, load and freezing