Subject: Re: Multiple IP addresses for a single host in "/etc/hosts"
To: None <tech-net@netbsd.org>
From: Matthias Scheler <tron@lyssa.owl.de>
List: tech-net
Date: 05/30/1999 23:37:09
In article <87btf26swo.fsf@redmail.redback.com>,
	cgd@netbsd.org (Chris G. Demetriou) writes:
> Is there any non-broken code that requires gethostbyname() to return
> exactly one address?

I don't know. We probably won't notice that until we change "libc".

> It seems to me that having multiple lines listing the host in
> /etc/host should behave no differently than DNS lookups where multiple
> A records are returned...

I completely agree.

> Of course, with /etc/hosts there's an efficiency issue (i.e. it'd be
> nice to just fine one match and return, rather than having to scan the
> whole file), but that's perhaps best addressed via a (new)
> nsswitch.conf option.

Something like "files" vs. "files_multi"?

-- 
Matthias Scheler                                http://home.owl.de/~tron/