Re: Error with index on unlogged table

Поиск
Список
Период
Сортировка
От Thom Brown
Тема Re: Error with index on unlogged table
Дата
Msg-id CAA-aLv5QO-C27GALdT6CrqMx6GH725999jYyw5fRHbZzXNtkiw@mail.gmail.com
обсуждение исходный текст
Ответ на Re: Error with index on unlogged table  (Michael Paquier <michael.paquier@gmail.com>)
Ответы Re: Error with index on unlogged table  (Andres Freund <andres@2ndquadrant.com>)
Список pgsql-hackers
On 26 March 2015 at 00:55, Michael Paquier <michael.paquier@gmail.com> wrote:
On Thu, Mar 26, 2015 at 1:02 AM, Fabrízio de Royes Mello
<fabriziomello@gmail.com> wrote:
> On Wed, Mar 25, 2015 at 12:46 PM, Fabrízio de Royes Mello
> <fabriziomello@gmail.com> wrote:
>>
>>
>> On Wed, Mar 25, 2015 at 10:53 AM, Andres Freund <andres@2ndquadrant.com>
>> wrote:
>> >
>>
>> > Did you check whether a similar bug was made in other places of
>> > 85b506bb? Could you additionally add a regression test to this end?
>> > Seems like something worth testing.
>> >
>>
>> I'm checking it and adding some regression tests.
>>
>
> I didn't found any other similar bug introduced by 85b506bb.
>
> Attached the original patch provided by Michael with some regression tests.

Thanks for adding a test, this looks fine to me (did some sanity
checks and tutti-quanti for people wondering). On temporary tables
this was failing with an error in md.c...

Thanks to both of you for fixing this.

I still, however, have a problem with the separate and original issue of:

# insert into utest (thing) values ('moomoo');
ERROR:  index "utest_pkey" contains unexpected zero page at block 0
HINT:  Please REINDEX it.

I don't see why the user should need to go re-indexing all unlogged tables each time a standby is promoted.  The index should just be empty and ready to use.

--
Thom

В списке pgsql-hackers по дате отправления:

Предыдущее
От: Stephen Frost
Дата:
Сообщение: Re: GSSAPI, SSPI - include_realm default
Следующее
От: Andres Freund
Дата:
Сообщение: Re: Error with index on unlogged table