Re: 4 billion + oids

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: "Andrew Bartley" <abartley(at)evolvosystems(dot)com>
Cc: pgsql-general(at)postgresql(dot)org
Subject: Re: 4 billion + oids
Date: 2003-03-24 06:46:36
Message-ID: 7252.1048488396@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

"Andrew Bartley" <abartley(at)evolvosystems(dot)com> writes:
> We have found this to be a major problem. It seems once the OIDs wrap; we =
> constantly get errors due to "Cannot insert a duplicate key into unique ind=
> ex pg_class_oid_index". There are about 3,000 entries in pg_class at this =
> stage.

Once the OID counter wraps, there's certainly some risk of OID
collisions. However, if you have only 3000 entries in pg_class it's
hard to see why the odds would be worse than 3000/4billion or less than
one failure in 1 million tries. I think there is something you have not
told us.

The nearby suggestions to minimize the rate of OID consumption seem
rather beside the point from here ... what I'd wonder about is why you
need as many as three thousand tables. Reducing that footprint should
reduce the odds of OID collision.

regards, tom lane

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Joel Rodrigues 2003-03-24 06:49:22 Re: PostgreSQL downloads compressed with bzip2 instead of
Previous Message Tamir Halperin 2003-03-24 05:11:50 Re: FW: [NOVICE] From a real novice