Re: Why copy_relation_data only use wal whenWALarchivingis enabled - Mailing list pgsql-hackers

From Jacky Leng
Subject Re: Why copy_relation_data only use wal whenWALarchivingis enabled
Date
Msg-id ff6cqj$26ie$1@news.hub.org
Whole thread Raw
In response to Why copy_relation_data only use wal when WAL archiving is enabled  ("Jacky Leng" <lengjianquan@163.com>)
Responses Re: Why copy_relation_data only use wal whenWALarchivingis enabled
List pgsql-hackers
> Heikki Linnakangas <heikki@enterprisedb.com> writes:
> I tend to agree that truncating the file, and extending the fsync
> request mechanism to actually delete it after the next checkpoint,
> is the most reasonable route to a fix.
>

How about just allowing to use wal even WAL archiving is disabled?
It seems that recovery of "XLOG_HEAP_NEWPAGE" record will do the
right thing for us, look at "heap_xlog_newpage": XLogReadBuffer
with init=true will extend the block rightly and rebuild it rightly.

Someone may say that it's not worth recording xlog for operations
such as copy_relation_data, but these operations shouldn't happen
frequently. 




pgsql-hackers by date:

Previous
From: "Jacky Leng"
Date:
Subject: Re: Why copy_relation_data only use wal when WALarchiving is enabled
Next
From: "Jacky Leng"
Date:
Subject: Re: Why copy_relation_data only use wal when WALarchiving is enabled