From owner-freebsd-questions@FreeBSD.ORG Thu Feb 12 22:58:10 2009 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 7B5F81065676 for ; Thu, 12 Feb 2009 22:58:10 +0000 (UTC) (envelope-from jerrymc@gizmo.acns.msu.edu) Received: from gizmo.acns.msu.edu (gizmo.acns.msu.edu [35.8.1.43]) by mx1.freebsd.org (Postfix) with ESMTP id 1BC0C8FC0A for ; Thu, 12 Feb 2009 22:58:09 +0000 (UTC) (envelope-from jerrymc@gizmo.acns.msu.edu) Received: from gizmo.acns.msu.edu (localhost [127.0.0.1]) by gizmo.acns.msu.edu (8.13.6/8.13.6) with ESMTP id n1CMu5OI078972; Thu, 12 Feb 2009 17:56:05 -0500 (EST) (envelope-from jerrymc@gizmo.acns.msu.edu) Received: (from jerrymc@localhost) by gizmo.acns.msu.edu (8.13.6/8.13.6/Submit) id n1CMu55d078971; Thu, 12 Feb 2009 17:56:05 -0500 (EST) (envelope-from jerrymc) Date: Thu, 12 Feb 2009 17:56:05 -0500 From: Jerry McAllister To: Nikolaj Thygesen Message-ID: <20090212225605.GA78907@gizmo.acns.msu.edu> References: <49947FC4.4000400@diamondbox.dk> <200902121916.54861.gnemmi@gmail.com> <499496BA.6040706@diamondbox.dk> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <499496BA.6040706@diamondbox.dk> User-Agent: Mutt/1.4.2.2i Cc: Gonzalo Nemmi , freebsd-questions@freebsd.org Subject: Re: Assigning static ip address X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 12 Feb 2009 22:58:10 -0000 On Thu, Feb 12, 2009 at 10:38:02PM +0100, Nikolaj Thygesen wrote: > Gonzalo Nemmi wrote: > >On Thursday 12 February 2009 6:00:04 pm Nikolaj Thygesen wrote: > > > >Could you plase configure your /etc/rc.conf file to something like this? > > > >ifconfig_ed0="inet 192.168.1.105 netmask 255.255.255.0" > >defaultrouter="192.168.1.1" > > > >Where "defaultrouter" is the IP of your dhcp server and tell me what > >happens? > > > >Regards > > > When I do, I get: > > em0: flags=8843 metric 0 mtu 1500 > options=19b > ether 00:1b:21:1b:fd:bd > inet6 fe80::21b:21ff:fe1b:fdbd%em0 prefixlen 64 scopeid 0x1 > inet 192.168.1.105 netmask 0xffffff00 broadcast 192.168.1.255 > media: Ethernet autoselect (1000baseTX ) > status: active > > I still get no connectivity until i run "dhclient em0" which gives me: > > em0: flags=8843 metric 0 mtu 1500 > options=19b > ether 00:1b:21:1b:fd:bd > inet6 fe80::21b:21ff:fe1b:fdbd%em0 prefixlen 64 scopeid 0x1 > inet 192.168.1.105 netmask 0xffffff00 broadcast 192.168.1.255 > inet 10.0.0.2 netmask 0xffffff00 broadcast 10.0.0.255 > media: Ethernet autoselect (1000baseTX ) > status: active > > adding what I guess is called an alias 10.0.0.2 ip?!?! I'm not that much > of an expert in these matters, and I'm a bit puzzled why, at first > (before calling dhclient), it can't resolve addresses eventhough > "/etc/resolv.conf" contains all my dns's. I think you need to turn off dhclient in /etc/rc.conf - or don't turn it on. Also, make sure your resolv.conf is correct and the default router is correctly set in /etc/rc.conf to your gateway address. It looks like your ifconfig might be correct, but either or both of resolv.conf or default router is wrong or dhclient is running and clobbering them. ////jerry > > br - N > > _______________________________________________ > freebsd-questions@freebsd.org mailing list > http://lists.freebsd.org/mailman/listinfo/freebsd-questions > To unsubscribe, send any mail to "freebsd-questions-unsubscribe@freebsd.org"