161609Sbostic.\" Copyright (c) 1983, 1991, 1993 261609Sbostic.\" The Regents of the University of California. All rights reserved. 320821Smckusick.\" 449644Scael.\" %sccs.include.redist.roff% 520821Smckusick.\" 6*65101Smckusick.\" @(#)hosts.5 8.2 (Berkeley) 12/11/93 736757Sbostic.\" 849644Scael.Dd 949644Scael.Dt HOSTS 5 1049644Scael.Os BSD 4.2 1149644Scael.Sh NAME 1249644Scael.Nm hosts 1349644Scael.Nd host name data base 1449644Scael.Sh DESCRIPTION 1520821SmckusickThe 1649644Scael.Nm hosts 1720821Smckusickfile contains information regarding 1828183Sbloomthe known hosts on the network. 1920821SmckusickFor each host a single line should be present 2020821Smckusickwith the following information: 2149644Scael.Bd -unfilled -offset indent 2220821Smckusickofficial host name 2320821SmckusickInternet address 2420821Smckusickaliases 2549644Scael.Ed 2649644Scael.Pp 2720821SmckusickItems are separated by any number of blanks and/or 2820821Smckusicktab characters. A ``#'' indicates the beginning of 2920821Smckusicka comment; characters up to the end of the line are 3020821Smckusicknot interpreted by routines which search the file. 3149644Scael.Pp 3228183SbloomWhen using the name server 3349644Scael.Xr named 8 , 3428183Sbloomthis file provides a backup when the name server 3528183Sbloomis not running. 3628183SbloomFor the name server, it is suggested that only a few addresses 3728183Sbloombe included in this file. 3828183SbloomThese include address for the local interfaces that 3949644Scael.Xr ifconfig 8 4028183Sbloomneeds at boot time and a few machines on the local network. 4149644Scael.Pp 4228183SbloomThis file may be created from the official host 4320821Smckusickdata base maintained at the Network Information Control 4449644ScaelCenter 4549644Scael.Pq Tn NIC , 4649644Scaelthough local changes may be required 4720821Smckusickto bring it up to date regarding unofficial aliases 4849644Scaeland/or unknown hosts. As the data base maintained at 4949644Scael.Tn NIC 50*65101Smckusickis incomplete, use of the name server is recommended for 5149644Scaelsites on the 5249644Scael.Tn DARPA 5349644ScaelInternet. 5449644Scael.Pp 5520821SmckusickNetwork addresses are specified in the conventional 5649644Scael``.'' (dot) notation using the 5749644Scael.Xr inet_addr 3 5849644Scaelroutine 5920821Smckusickfrom the Internet address manipulation library, 6049644Scael.Xr inet 3 . 6120821SmckusickHost names may contain any printable 6220821Smckusickcharacter other than a field delimiter, newline, 6320821Smckusickor comment character. 6449644Scael.Sh FILES 6549644Scael.Bl -tag -width /etc/hosts -compact 6649644Scael.It Pa /etc/hosts 6749644ScaelThe 6849644Scael.Nm hosts 6949644Scaelfile resides in 7049644Scael.Pa /etc . 7149644Scael.El 7249644Scael.Sh SEE ALSO 7349644Scael.Xr gethostbyname 3 , 7449644Scael.Xr ifconfig 8 , 7549644Scael.Xr named 8 7649644Scael.Rs 7749644Scael.%T "Name Server Operations Guide for BIND" 7849644Scael.Re 7949644Scael.Sh HISTORY 8049644ScaelThe 8149644Scael.Nm 8249644Scaelfile format appeared in 8349644Scael.Bx 4.2 . 84