From owner-freebsd-arch Sat Oct 13 21:18:53 2001 Delivered-To: freebsd-arch@freebsd.org Received: from peter3.wemm.org (c1315225-a.plstn1.sfba.home.com [24.14.150.180]) by hub.freebsd.org (Postfix) with ESMTP id D904137B403; Sat, 13 Oct 2001 21:18:47 -0700 (PDT) Received: from overcee.netplex.com.au (overcee.wemm.org [10.0.0.3]) by peter3.wemm.org (8.11.0/8.11.0) with ESMTP id f9E4IlM95379; Sat, 13 Oct 2001 21:18:47 -0700 (PDT) (envelope-from peter@wemm.org) Received: from wemm.org (localhost [127.0.0.1]) by overcee.netplex.com.au (Postfix) with ESMTP id 33E0C3810; Sat, 13 Oct 2001 21:18:47 -0700 (PDT) (envelope-from peter@wemm.org) X-Mailer: exmh version 2.3.1 01/18/2001 with nmh-1.0.4 To: Doug Barton Cc: Dag-Erling Smorgrav , arch@FreeBSD.org Subject: Re: Generating host.conf for backward compatibility In-Reply-To: <20011013153357.R40455-100000@master.gorean.org> Date: Sat, 13 Oct 2001 21:18:47 -0700 From: Peter Wemm Message-Id: <20011014041847.33E0C3810@overcee.netplex.com.au> Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Doug Barton wrote: > On Sat, 13 Oct 2001, Peter Wemm wrote: > > > Dag-Erling Smorgrav wrote: > > > --=-=-= > > > > > > In our eagerness to switch from host.conf to nsswitch.conf, we forgot > > > that old binaries and libraries (COMPAT_* and tons of third-party > > > software for which sources might not even be available) still expect > > > to find /etc/host.conf, and may not work (correctly) if it doesn't > > > exist. > > > > I'm a bit puzzled as to why this makes a difference. The old libc resolver > > defaulted to "dns","files" if host.conf was missing. The file is and > > always was optional. > > > > Of course, that doesn't help you if you use a NIS hosts map, or if you're > > expecting /etc/hosts to override DNS lookups. > > I know that when I was running -current before the recent stdio > changes made COMPAT4X mandatory, I used 4.x binaries without difficulty. > The two most notable examples are cvsup and Yahoo! messenger. Once I > installed the compat stuff those binaries stopped working. I haven't had a > chance to test Dag-Erling's theory yet, since I've still got ATA issues to > solve before I can move my workstation back to -current. > > Here's an ugly thought.... what would happen if /etc/host.conf > existed, but its contents were missing or invalid? The more I think about > this.... I vaguely recall futzing around with /etc/host.conf around the > time of the nsswitch.conf change, and I may have left an empty file > hanging around to test some rc* stuff. This would certainly explain it if that is what happened. Your 4.x binaries would have ended up not being able to resolve anything. > If that's the case, I apologize if > this has been a waste of time... although it might be nice to build > something into libc that says "If the contents of > /etc/{host|nsswitch}.conf don't make any sense, fall back to the default." > > Looking for somewhere to hide... > > Doug > -- > "We will not tire, we will not falter, and we will not fail." > - George W. Bush, President of the United States > September 20, 2001 > > Do YOU Yahoo!? > > > Cheers, -Peter -- Peter Wemm - peter@FreeBSD.org; peter@yahoo-inc.com; peter@netplex.com.au "All of this is for nothing if we don't go to the stars" - JMS/B5 To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message