Re: UUIDs in core WAS: 9.4 Proposal: Initdb creates a single table

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: UUIDs in core WAS: 9.4 Proposal: Initdb creates a single table
Дата
Msg-id 438.1398536316@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Re: UUIDs in core WAS: 9.4 Proposal: Initdb creates a single table  (Martijn van Oosterhout <kleptog@svana.org>)
Список pgsql-hackers
Martijn van Oosterhout <kleptog@svana.org> writes:
> On Fri, Apr 25, 2014 at 04:18:18PM +0100, Greg Stark wrote:
>> Which isn't to say they're a bad idea but like everything else in
>> engineering there are tradeoffs and no such thing as a free lunch.
>> You can avoid depleting the entropy pool by including data you expect
>> to be unique as a kind of fake entropy -- which quickly gets you back
>> to looking for things like MAC address to avoid duplicates across
>> systems.

> ISTM you could use the database identifier we already have to at least
> produce "UUID"s which are unique amongst PostgreSQL instances. That
> might be something worth aiming for?

It's worth noting in this connection that we've never tried hard to ensure
that "database identifiers" are actually unique.  One potentially serious
issue is that slave servers will have the same identifier as their master.

Also, I think there's a still-open issue that creation of the identifier
has a thinko about using OR instead of XOR, resulting in way few bits of
freedom than it should have even with the limited amount of entropy used.
        regards, tom lane



В списке pgsql-hackers по дате отправления:

Предыдущее
От: David Fetter
Дата:
Сообщение: Re: Decrease MAX_BACKENDS to 2^16
Следующее
От: Andres Freund
Дата:
Сообщение: Re: Decrease MAX_BACKENDS to 2^16