Received: from hcs.hartcomm.com ([63.175.25.2]) by postgresql.org (8.11.3/8.11.1) with ESMTP id f57F8LE58849 for ; Thu, 7 Jun 2001 11:08:21 -0400 (EDT) (envelope-from tbarnard@povn.com) Received: from dev6 (dev5.hartcomm.com [63.175.25.165]) by hcs.hartcomm.com (8.11.2/8.8.7) with SMTP id f57FD3S08928; Thu, 7 Jun 2001 08:13:03 -0700 Message-ID: <003b01c0ef63$aa67bd20$a519af3f@hartcomm.com> From: "Tim Barnard" To: "Tom Lane" Cc: References: <20010606215234.97024.qmail@web10001.mail.yahoo.com> <6257.991867020@sss.pgh.pa.us> Subject: Re: Re: [SQL] maximum number of rows in table - what about oid limits? Date: Thu, 7 Jun 2001 08:08:09 -0700 MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit X-Priority: 3 X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook Express 5.50.4522.1200 X-MimeOLE: Produced By Microsoft MimeOLE V5.50.4522.1200 X-Archive-Number: 200106/241 X-Sequence-Number: 10576 If it does happen, you can just retry the failed object-creation command until you get a nonconflicting OID assignment. Tom, or anyone who'd know for that matter, what is the exact error I would need to look for? Tim ----- Original Message ----- From: "Tom Lane" To: Cc: "Stephan Szabo" ; ; Sent: Wednesday, June 06, 2001 3:37 PM Subject: [GENERAL] Re: [SQL] maximum number of rows in table - what about oid limits? > John Scott writes: > > my question is, since oid's are used by the > > postgres kernel, what effect does oid wrapping have upon > > the stability of the database. > > It doesn't affect stability, if by that you mean potential crashes. > > What can happen after a wrap is that the OID generated for a > newly-created object might conflict with some already-existing object's > OID. If that happens, you get a duplicate-key-insertion error on the > OID index of the relevant system catalog (pg_class, pg_type, etc). > There is a unique index on OID for each system catalog wherein OID > is used to identify objects. It doesn't really matter whether the > same OID is reused in different catalogs or in user tables. > > The odds of this happening seem pretty low, if you've got reasonable > numbers of objects (eg, with a couple thousand tables in a database, > you'd have a 2000/4G = 1 in 2 million chance of collision on pg_class > OID). If it does happen, you can just retry the failed object-creation > command until you get a nonconflicting OID assignment. > > This is certainly not ideal, but it's not nearly as big a problem as > transaction ID wraparound. You can live with it, whereas right now > xact ID wraparound is catastrophic. That we gotta work on, soon. > > regards, tom lane > > ---------------------------(end of broadcast)--------------------------- > TIP 2: you can get off all lists at once with the unregister command > (send "unregister YourEmailAddressHere" to majordomo@postgresql.org) >