Path: utzoo!mnetor!tmsoft!torsqnt!news-server.csri.toronto.edu!cs.utexas.edu!samsung!rex!uflorida!mlb.semi.harris.com!algol.mlb.semi.harris.com!del From: del@algol.mlb.semi.harris.com (Don Lewis) Newsgroups: comp.unix.questions Subject: Re: Now that resolver is used, mail ignores 'mailhost' in /etc/hosts Keywords: resolver, sun, hosts Message-ID: <1990Dec18.234957.29846@mlb.semi.harris.com> Date: 18 Dec 90 23:49:57 GMT References: <1990Nov30.135031.25038@uunet!unhd> <114205@uunet.UU.NET> Sender: news@mlb.semi.harris.com Organization: Harris Semiconductor, Melbourne FL Lines: 31 Nntp-Posting-Host: algol.mlb.semi.harris.com In article <114205@uunet.UU.NET> rbj@uunet.UU.NET (Root Boy Jim) writes: >In article <1990Nov30.135031.25038@uunet!unhd> rg@unhd.unh.edu (Roger Gonzalez ) writes: >>System: Sun 3/160 running SunOS 4.1, *no* YP > >>I had been having problems getting ftp, telnet, finger, etc. to use the >>nameserver. I received a suggestion to rebuild /usr/lib/libc.so with >>the inclusion of some .o's from libresolv.a. This worked pretty well; >>all address resolution was now done through the nameserver. Unfortunately, >>this makes /etc/hosts completely ignored. Its not *that* intolerable, >>but the /etc/hosts contained some convenient nicknames for local machines >>that the resolver doesn't know about. C'est la vie. > >So add your nicknames to your nameserver database with CNAME records. >The easiest place is in your named.local file. I put things there >because (1) the info never changes (2) this is the one domain that >everyone is an authority for. Purists may groan, as the information >really doesn't "belong" there, but it works. There is also an environment variable "HOSTALIASES" that you can set to a file name that contains aliases for hosts and the actual host names. You could put "mailhost whatever" in a file, and set the HOSTALIASES variable before starting sendmail. This feature allows users to define their own host aliases as well (it'll probabably break things if users uses these aliases in mail addresses unless the addresses are somehow canonicalized). This appears to be undocumented in the Sun man pages. I found out about it by looking at the Berkeley code and doing a strings on Sun's libresolve.a. -- Don "Truck" Lewis Harris Semiconductor Internet: del@mlb.semi.harris.com PO Box 883 MS 62A-028 Phone: (407) 729-5205 Melbourne, FL 32901