Re: allow segment size to be set to < 1GiB

From: Andres Freund <andres(at)anarazel(dot)de>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: pgsql-hackers(at)postgresql(dot)org, Peter Geoghegan <pg(at)bowt(dot)ie>
Subject: Re: allow segment size to be set to < 1GiB
Date: 2022-11-09 19:42:17
Message-ID: 20221109194217.jhimtlnp6y7hbbcn@awork3.anarazel.de
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On 2022-11-08 18:28:08 -0800, Andres Freund wrote:
> On 2022-11-07 21:36:33 -0500, Tom Lane wrote:
> > Andres Freund <andres(at)anarazel(dot)de> writes:
> > > On 2022-11-07 12:52:25 -0500, Tom Lane wrote:
> > >> How about instead allowing the segment size to be set in pages?
> >
> > > In addition or instead of --with-segsize/-Dsegsize?
> >
> > In addition to. What I meant by "instead" was to replace
> > your proposal of --with-segsize-mb.
>
> Working on updating the patch.
>
> One semi-interesting bit is that <= 5 blocks per segment fails, because
> corrupt_page_checksum() doesn't know about segments and
> src/bin/pg_basebackup/t/010_pg_basebackup.pl does

A second question: Both autoconf and meson print the segment size as GB right
now. Obviously that'll print out a size of 0 for a segsize < 1GB.

The easiest way to would be to just display the number of blocks, but that's
not particularly nice. We could show kB, but that ends up being large. Or we
can have some code to adjust the unit, but that seems a bit overkill.

Opinions?

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Tom Lane 2022-11-09 19:44:42 Re: allow segment size to be set to < 1GiB
Previous Message Daniel Verite 2022-11-09 19:10:34 Re: psql: Add command to use extended query protocol