date and time created 89/07/02 20:11:52 by mckusick
[unix-history] / usr / src / lib / libc / compat-43 / gethostid.3
.\" Copyright (c) 1983 The Regents of the University of California.
.\" All rights reserved.
.\"
.\" Redistribution and use in source and binary forms are permitted
.\" provided that the above copyright notice and this paragraph are
.\" duplicated in all such forms and that any documentation,
.\" advertising materials, and other materials related to such
.\" distribution and use acknowledge that the software was developed
.\" by the University of California, Berkeley. The name of the
.\" University may not be used to endorse or promote products derived
.\" from this software without specific prior written permission.
.\" THIS SOFTWARE IS PROVIDED ``AS IS'' AND WITHOUT ANY EXPRESS OR
.\" IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED
.\" WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
.\"
.\" @(#)gethostid.3 6.4 (Berkeley) %G%
.\"
.TH GETHOSTID 2 ""
.UC 5
.SH NAME
gethostid, sethostid \- get/set unique identifier of current host
.SH SYNOPSIS
.nf
.ft B
hostid = gethostid()
long hostid;
.PP
.ft B
sethostid(hostid)
long hostid;
.fi
.SH DESCRIPTION
.I Sethostid
establishes a 32-bit identifier for the
current processor that is intended to be unique among all
UNIX systems in existence. This is normally a DARPA Internet
address for the local machine. This call is allowed only to the
super-user and is normally performed at boot time.
.PP
.I Gethostid
returns the 32-bit identifier for the current processor.
.SH SEE ALSO
hostid(1), gethostname(2)
.SH BUGS
32 bits for the identifier is too small.