Re: Drawbacks of using BYTEA for PK?

From: David Garamond <lists(at)zara(dot)6(dot)isreserved(dot)com>
To: pgsql-general(at)postgresql(dot)org
Subject: Re: Drawbacks of using BYTEA for PK?
Date: 2004-01-15 05:52:43
Message-ID: 40062AAB.400@zara.6.isreserved.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Alex Satrapa wrote:
> David Garamond wrote:
>
>> Remember that /sbin/ifconfig output usually include MAC address too.
>> Not that MAC addresses are 100% unique, but that should increase the
>> uniqueness.
>
> How do you increase uniqueness? Either a value is unique or it isn't -

Ok, let's say "mathematically unique" and "practically unique". I was
referring to the second one.

> if you've got multiple hosts on the network with the same network
> address, you're in big trouble!
>
> 32 bits for an IP address is a huge number space... but why you'd really
> need that much space as a base for your GUID is beyond me.

The point of using /sbin/ifconfig output (and then hashing it to get a
128bit number) is because the output contains MAC address and IP
address. IP addresses are not unique, particularly in intranet or
clustering situation. MAC addresses are more likely to be unique, but
I've heard stories about cheap ethernet cards having duplicate MAC's,
and beside in many cases MAC addresses can be altered by software.

The probability of both MAC and IP address (and other strings in
/sbin/ifconfig output) being totally the same for two hosts is of course
much smaller, and thus the term "increase [the practical] uniqueness."

--
dave

In response to

Browse pgsql-general by date

  From Date Subject
Next Message David Garamond 2004-01-15 05:55:02 Re: Drawbacks of using BYTEA for PK?
Previous Message LitelWang 2004-01-15 05:35:32 about postgres odbc on wondows