Re: pg_system_identifier()

From: Jim Nasby <jim(at)nasby(dot)net>
To: Greg Stark <stark(at)mit(dot)edu>
Cc: Hannu Krosing <hannu(at)2ndquadrant(dot)com>, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, Andres Freund <andres(at)2ndquadrant(dot)com>, Alvaro Herrera <alvherre(at)2ndquadrant(dot)com>, Josh Berkus <josh(at)agliodbs(dot)com>, PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: pg_system_identifier()
Date: 2013-08-25 22:47:33
Message-ID: 521A8985.2040509@nasby.net
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On 8/23/13 11:23 AM, Greg Stark wrote:
> This doesn't generate a unique id. You could back up a standby and restore it and point it at the original master and end up with two standbies with the same id.

If you want to enforce something unique throughout a cluster, I think we're stuck with having the cluster communicate IDs across an entire cluster. AFAIK that's how both Slony and londiste 3 do it.

I think it's also noteworthy that Slony and londiste both rely on the user specifying node identifiers. They don't try to be magic about it. I think there's 2 advantages there:

- Code is simpler
- Users can choose a naming schema that makes sense for them
--
Jim C. Nasby, Data Architect jim(at)nasby(dot)net
512.569.9461 (cell) http://jim.nasby.net

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Michael Paquier 2013-08-26 01:36:54 Re: Hstore: Query speedups with Gin index
Previous Message Pavel Stehule 2013-08-25 18:27:08 Re: Performance problem in PLPgSQL