Date: Thu, 22 Mar 2001 11:03:20 +0100 From: Christoph Sold <so@server.i-clue.de> To: Murray Taylor <mtaylor@bytecraft.com.au> Cc: FreeBSD-Questions <freebsd-questions@FreeBSD.ORG> Subject: Re: /etc/hosts format Message-ID: <3AB9CDE8.71855700@i-clue.de> References: <710709BB8B02D311942E00606744181054429F@MELEXC01>
next in thread | previous in thread | raw e-mail | index | archive | help
Murray Taylor schrieb: > > OK I have conflicting information about the format of the /etc/hosts table > > one reference says that the format should be > > 127.0.0.1 localhost localhost.my.domain myname.my.domain > 10.0.0.2 myname.my.domain myname > 10.0.0.3 myfriend.my.domain myfriend > > then another says > > 127.0.0.1 localhost.my.domain localhost > 10.0.0.2 myname.my.domain myname > 10.0.0.3 myfriend.my.domain myfriend > > then another says > > 127.0.0.1 localhost.my.domain localhost > 127.0.0.1 localhost > 10.0.0.2 myname.my.domain myname > 10.0.0.2 myname > 10.0.0.3 myfriend.my.domain myfriend > 10.0.0.3 myfriend > > then another says (note trailing dots on secondary lines) > > 127.0.0.1 localhost.my.domain localhost > 127.0.0.1 localhost.my.domain. > 10.0.0.2 myname.my.domain myname > 10.0.0.2 myname.my.domain. > 10.0.0.3 myfriend.my.domain myfriend > 10.0.0.3 myfriend.my.domain. > > Who is right??? All of them, choose your preferred format. The last entry prohibits adding of the local domain to the trailing dot lines by the resolver library. Unfortunately, since the very same name is already listed without trailing dots, the resolver would try them nonetheless. HTH -Christoph Sold To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?3AB9CDE8.71855700>