From owner-freebsd-questions Wed May 24 15:29:27 2000 Delivered-To: freebsd-questions@freebsd.org Received: from dan.emsphone.com (dan.emsphone.com [199.67.51.101]) by hub.freebsd.org (Postfix) with ESMTP id DA9F537BD90 for ; Wed, 24 May 2000 15:29:23 -0700 (PDT) (envelope-from dan@dan.emsphone.com) Received: (from dan@localhost) by dan.emsphone.com (8.9.3/8.9.3) id RAA23830; Wed, 24 May 2000 17:29:20 -0500 (CDT) (envelope-from dan) Date: Wed, 24 May 2000 17:29:20 -0500 From: Dan Nelson To: Lowell Gilbert Cc: freebsd-questions@FreeBSD.ORG Subject: Re: uuidgen or other GUID-generating utility Message-ID: <20000524172920.A19867@dan.emsphone.com> References: <27E4B476932BD211945B00805FE67AF5089DE1E3@lnxdayexch05.lexis-nexis.com> <20000524161737.A2307@dan.emsphone.com> <44bt1v7glr.fsf@lowellg.ne.mediaone.net> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.2i In-Reply-To: <44bt1v7glr.fsf@lowellg.ne.mediaone.net>; from "Lowell Gilbert" on Wed May 24 18:01:20 GMT 2000 X-OS: FreeBSD 5.0-CURRENT Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG In the last episode (May 24), Lowell Gilbert said: > Dan Nelson writes: > > No, FreBSD doesn't have a program to pull the ethernet address and > > print a guid formatted like Linux's "uuidgen -t". I don't imagine > > that the program would be hard to port to FreeBSD, though. > > Well, you could do that from the command line, too, using ifconfig(8) > to get the ethernet address, and date(1) to get the time, and an > assortment of text utilities to grab just the pieces you want. Ten After a bit of digging I found that a uuid has an internal structure. http://www.ics.uci.edu/pub/ietf/webdav/uuid-guid/draft-leach-uuids-guids-01.txt tells you how you have to format one, and includes sample code. Put your MAC address in the file called "nodeid" and you're set. Side note: Considering the fact that MS uses UUIDs almost everywhere, it's amazing that nowhere on Microsoft's development site could I find a description of a UUID more detailed than "unique 128-bit identifier". -- Dan Nelson dnelson@emsphone.com To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message