Re: [PATCH] Infinite loop while acquiring new TOAST Oid

From: Nikita Malakhov <hukutoc(at)gmail(dot)com>
To: Andres Freund <andres(at)anarazel(dot)de>
Cc: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, pgsql-hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: [PATCH] Infinite loop while acquiring new TOAST Oid
Date: 2022-11-28 22:27:24
Message-ID: CAN-LCVMM0fD9praKnJ4Lf4co_pK-+z-K6dYpyVQEFU+CYKD68Q@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

I've missed that -

>4 billion external datums
>typically use a lot of space.

Not quite so. It's 8 Tb for the minimal size of toasted data (about 2 Kb).
In my practice tables with more than 5 billions of rows are not of
something out
of the ordinary (highly loaded databases with large amounts of data in use).

On Tue, Nov 29, 2022 at 1:12 AM Nikita Malakhov <hukutoc(at)gmail(dot)com> wrote:

> Hi,
>
> I'll check that tomorrow. If it is so then there won't be a problem keeping
> old tables without re-toasting.
>
> On Tue, Nov 29, 2022 at 1:10 AM Andres Freund <andres(at)anarazel(dot)de> wrote:
>
>> Hi,
>>
>> On 2022-11-28 16:57:53 -0500, Tom Lane wrote:
>> > As I said before, I think there's a decent argument that some people
>> > will want the option to stay with 4-byte TOAST OIDs indefinitely,
>> > at least for smaller tables.
>>
>> I think we'll need to do something about the width of varatt_external to
>> make
>> the conversion to 64bit toast oids viable - and if we do, I don't think
>> there's a decent argument for staying with 4 byte toast OIDs. I think the
>> varatt_external equivalent would end up being smaller in just about all
>> cases.
>> And as you said earlier, the increased overhead inside the toast table /
>> index
>> is not relevant compared to the size of toasted datums.
>>
>> Greetings,
>>
>> Andres Freund
>>
>
>
> --
> Regards,
> Nikita Malakhov
> Postgres Professional
> https://postgrespro.ru/
>

--
Regards,
Nikita Malakhov
Postgres Professional
https://postgrespro.ru/

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Dmitry Koval 2022-11-28 22:30:14 Re: Add SPLIT PARTITION/MERGE PARTITIONS commands
Previous Message Tom Lane 2022-11-28 22:24:29 Re: [PATCH] Infinite loop while acquiring new TOAST Oid