What about using the MAC address in conjunction with the current time stamp. Or the IP address. Or username + time + MAC address. Lost of choices.
-----Original Message-----
From: Neil Parker [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, February 20, 2002 4:00 PM
To: [EMAIL PROTECTED]
Subject: [EUG-LUG:1695] Re: Globally unique Identifiers?
On Wed, 20 Feb 2002, Larry Price wrote:
>My question to you all is, what's a good way to generate a GLOBALLY unique
>ID (the rfc's specify that it is world-unique, not just unique to message)
>
>My first idea was to use an md5 hash of the filename and date, but I can
>see some problems with that.
>
>Is there a good way to guarantee that CID's are acceptably unique?
If you're on an Internet-connected machine, start with the fully-qualified
domain name. Then you only need to make the rest unique within your
machine, which can often be done by using the current time stamp and
process ID. If you need to have a single process be able generate several
CIDs within less than 1 second, append a serial number (which need only be
unique within the process).
Schemes like this have a long history of successful use...USENET article
numbers and e-mail Message-IDs (which are both supposed to be globally
unique, I think) are often generated this way.
- Neil Parker, [EMAIL PROTECTED]
