Re: pg_system_identifier() - Mailing list pgsql-hackers

From Andres Freund
Subject Re: pg_system_identifier()
Date
Msg-id 20130822164907.GJ17006@awork2.anarazel.de
Whole thread Raw
In response to Re: pg_system_identifier()  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-hackers
On 2013-08-22 12:37:36 -0400, Tom Lane wrote:
> Do we have a reliable way of generating a unique identifier for each slave
> (independently of how that might be exposed)?

I'd like one, but it's not easy. The best I can think of is to mash
together:
* system_identifier
* mac address of primary interface we're listening to
* port
* primary/standby
in some pseudo-cryptographic manner.

But that's less than convincing because it can change after simple
configuration or hardware changes or even reboot :(.

Really identifying a particular host seems hard in anything resembling a
portable solution.

Greetings,

Andres Freund

-- Andres Freund                       http://www.2ndQuadrant.com/PostgreSQL Development, 24x7 Support, Training &
Services



pgsql-hackers by date:

Previous
From: Tom Lane
Date:
Subject: Re: pg_system_identifier()
Next
From: Jeff Janes
Date:
Subject: Allow child table to be missing nullable column from parent.