From: Tom Lane <tgl@sss.pgh.pa.us>
To: Natalie Wenz <nataliewenz@ebureau.com>
Cc: pgsql-admin <pgsql-admin@postgresql.org>
Cc: Joshua D. Drake <jd@commandprompt.com>
Cc: david.g.johnston@gmail.com
Subject: Re: pg_toast oid limits
Date: Wed, 26 Oct 2016 18:35:36 -0400
Message-ID: <10802.1477521336@sss.pgh.pa.us> (raw)
In-Reply-To: <8B647628-89BE-43FE-B538-973BF85A79A9@ebureau.com>
References: <A88C1E63-DB62-43C6-B8EC-E78D07574690@ebureau.com>
<24095.1477509777@sss.pgh.pa.us>
<8B647628-89BE-43FE-B538-973BF85A79A9@ebureau.com>
List-Unsubscribe: <mailto:majordomo@postgresql.org?body=unsub%20pgsql-admin>
Natalie Wenz <nataliewenz@ebureau.com> writes:
> I'm a little confused about the limit. Is it 4 billion oids for the whole database, or just per table? I keep coming back to this line, from https://wiki.postgresql.org/wiki/TOAST :
Per table --- the problem is you need a unique 4-byte chunk_id for each
toasted field value.
> "If you exceed 4 billion of these rows across all tables (remember this is a global shared wrapping counter), then the OID counter "wraps" which might cause significant slowdown as you approach the 4B row limit."
Um. That could use improvement, couldn't it. The numbers are sourced
from a global counter, but as the counter wraps around it's possible for
the same number to be re-used in different toast tables. You only start
to see a problem when the density of already-used numbers in a particular
toast table gets too high, so that the system has to spend a long time
searching for the next free number.
regards, tom lane
--
Sent via pgsql-admin mailing list (pgsql-admin@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-admin
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients using the --to and --cc options:
reply via email
To: pgsql-admin@postgresql.org
Cc: tgl@sss.pgh.pa.us, nataliewenz@ebureau.com, jd@commandprompt.com, david.g.johnston@gmail.com
Subject: Re: pg_toast oid limits
In-Reply-To: <10802.1477521336@sss.pgh.pa.us>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox