From: Tim O'Donovan (tim.odonovan at domain sun.com)
Date: Thu 06 Sep 2001 - 17:32:07 IST
Fergal Moran wrote:
> >> From: Fergal Moran [mailto:fergal.moran at domain wasptech.com]
> >> How do I get a globally unique identifier in C/C++?
> > From: McGahon, Dermot [mailto:Dermot.McGahon at domain avocent.com]
> > <snip c++ code for LOCALLY unique identifier>
> > Is that what you mean or something else?
> > Regards,
> > Dermot.
> Not really - I want a GLOBALLY unique identifier - ie. an ID that I know no other machine in the world will ever have - windows uses them extensively - producing them using the unique id of your NIC and the timestamp - I need a linux equivalent.
If your machine has an Ethernet card, why not just
use the MAC Address? That's globally unique. I'm
pretty sure you could find some C++ code on the web
to get the MAC address.
-- Tim O'Donovan, Volume Systems Products Group Sun Microsystems Ireland, Boole House, East Point Business Park, Dublin 3, Ireland Tel : (+353) 1-819-9277 E-Mail:tim.odonovan at domain sun.com
This archive was generated by hypermail 2.1.6 : Thu 06 Feb 2003 - 13:12:01 GMT