From owner-freebsd-questions Sun Oct 28 8:38:19 2001 Delivered-To: freebsd-questions@freebsd.org Received: from sg1.indexthis.net (sg1.indexthis.net [66.33.60.115]) by hub.freebsd.org (Postfix) with ESMTP id 218C237B407 for ; Sun, 28 Oct 2001 08:38:15 -0800 (PST) Received: from localhost (pmak@localhost) by sg1.indexthis.net (8.9.3/8.9.3) with ESMTP id LAA25991; Sun, 28 Oct 2001 11:37:53 -0500 Date: Sun, 28 Oct 2001 11:37:52 -0500 (EST) From: Philip Mak X-Sender: To: David Powers Cc: Subject: RE: /etc/hosts doesn't work? In-Reply-To: <000301c15fcc$c267bc70$0401a8c0@daveabit> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG server1# cat /etc/host.conf # $FreeBSD: src/etc/host.conf,v 1.6 1999/08/27 23:23:41 peter Exp $ # First try the /etc/hosts file hosts # Now try the nameserver next. bind # If you have YP/NIS configured, uncomment the next line # nis If I understand that correctly, it means /etc/hosts should take precendence? On Sun, 28 Oct 2001, David Powers wrote: > How is /etc/host.conf configured on the box? > > -----Original Message----- > From: owner-freebsd-questions@FreeBSD.ORG > [mailto:owner-freebsd-questions@FreeBSD.ORG]On Behalf Of Philip Mak > Sent: Sunday, October 28, 2001 10:07 AM > To: freebsd-questions@freebsd.org > Subject: /etc/hosts doesn't work? > > > %cat /etc/resolv.conf > domain buildreferrals.com > nameserver 127.0.0.1 > %cat /etc/hosts > 127.0.0.1 localhost localhost.localdomain > 65.119.108.130 db db.buildreferrals.com > %host db > db.buildreferrals.com has address 66.33.85.240 > > What's happening above? I'm trying to make it so that the host "db" (or > db.buildreferrals.com) points to 65.119.108.130 (as specified in > /etc/hosts) when I look it up from the machine. But when I actually look > up that host, it gives a different address. > > (The DNS will eventually point 'db' to the correct host, but I need it to > work in /etc/hosts for efficiency reasons.) > > > To Unsubscribe: send mail to majordomo@FreeBSD.org > with "unsubscribe freebsd-questions" in the body of the message > To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message