Host ID.

John Baldwin jhb at freebsd.org
Tue Apr 10 21:55:16 UTC 2007


On Monday 09 April 2007 15:07, Pawel Jakub Dawidek wrote:
> On Mon, Apr 09, 2007 at 01:35:39PM -0400, Jung-uk Kim wrote:
> > On Sunday 08 April 2007 11:13 am, Pawel Jakub Dawidek wrote:
> > > On Sun, Apr 08, 2007 at 10:04:16PM +0900, gnn at freebsd.org wrote:
> > > > I noted that someone mentioned using a network based ID.  Since
> > > > EUI-64 are unique I would suspect they would be the best source
> > > > for this on systems that don't naturally have a hostid concept. 
> > > > See Appendix A of RFC 2373 for how to create an EUI-64 Interface
> > > > Identifier.
> > > >
> > > > The only problem with this approach that I see is that if you
> > > > remove that interface (that is it was on a card not on your
> > > > motherboard) then it goes away.  Perhaps generating this and
> > > > storing it, no matter what the future network configuration of
> > > > the system is, is the right way to go.
> > >
> > > So why not generate it and be done with it? And what if you move
> > > your card to another box were you're planning to install new
> > > system?
> > 
> > Actually uuidgen(2) uses uuid(3) and uuid(3) generates UUID version 1 
> > string, i.e., it is based on timestamp and MAC address already. :-)
> 
> But in my proposal we generate UUID only once and store it as it is,
> which means are keep the same UUID even if network card has changed.
> 
> > > I'd really like to make it simple and consistent on all archs, so
> > > one knows exactly what to expect.
> > 
> > Agreed.  But I also agree with imp, i.e., we have to utilize hardware 
> > UUID if it is available and valid for the platform.
> 
> I don't agree. As Robert pointed out there are situation you would like
> to share the same UUID between many hosts.
> 
> I'm committing as it is, we may change it in the future.

Actually, I think it would be quite useful to use a hardware-defined ID if
it exists.  I think DES's suggestion of only using it when generating
/etc/hostid strikes the right balance.

-- 
John Baldwin


More information about the freebsd-arch mailing list