Obtaining a unique, "unchangeable" number associated with an SGI workstation

Wiltse Carpenter wiltse at oceana.esd.sgi.com
Wed Jan 10 16:25:06 AEST 1990


In article <12817 at phoenix.Princeton.EDU>, ams at fourier.Princeton.EDU (Andrew Simms) writes:
> ...they would like to obtain a
> read-only number (such as a motherboard serial number) that
> could be used as a key to operate the software only on that
> machine.
> 
> p.s.  Ethernet addresses won't quite do it, since it needs
> 	to run on machines without ethernet boards.
> ----------------------------------------------------------------------

The sysid(3C) call returns a machine identifier string that is unique
for all SGI machines.  The implementation is somewhat different on the
various 4D models, but it is currently based on the E-net address in
all of them.  You are right that machines without Ethernet boards, or
with boards that get swapped will not return unique values.  On the
4D/2x models however, the E-net address is stored on the chassis so
that a swap of the electronics module will not affect the address or
the return from the sysid() call and all machines have one.

Please also be aware that the gethostid(2) call is not the thing
to use for this purpose on SGI machines since the super-user can
set with sethostid(2) to any legal value.

One more thing to be warned about: Do not use the mapping of the E-net
address in the sysid call to obtain the E-net address itself!  On
future versions of our machines we may well come up with a better
source for the serial number which may not have anything to do with the
E-net address.

	-Wiltse



More information about the Comp.sys.sgi mailing list