Date: Thu, 12 Feb 2009 14:08:21 -0700 From: Tim Judd <tajudd@gmail.com> To: Nikolaj Thygesen <mailinglist@diamondbox.dk> Cc: FreeBSD Questions <freebsd-questions@freebsd.org> Subject: Re: Assigning static ip address Message-ID: <49948FC5.3070008@gmail.com> In-Reply-To: <49947FC4.4000400@diamondbox.dk> References: <49947FC4.4000400@diamondbox.dk>
next in thread | previous in thread | raw e-mail | index | archive | help
Nikolaj Thygesen wrote: > Hi list, > > I've been experimenting and googling for hours w/ no luck. All I > want to do is run dhcp and then replace the ip address of the > interface with a new static ip afterwards. I've been looking at the > /etc/dhclient.conf man pages, but they don't seem to help. I can do it > from rc.conf like: > > ifconfig_em0="inet 1.2.3.4" > > but then I loose all the other dhcp parameters like dns and stuff. Is > it really that hard??? > > thanks - Nikolaj Your rc.conf line is incomplete. Even if that line was complete, your route would be missing Your /etc/resolv.conf gets rewritten by dhclient every time it renews the IP. Given your rc.conf statement is incomplete, is why you lose 100% connectivity. Basic networking on a LAN (meaning: NO INTERNET) is IP address and subnet basic networking ON the internet needs a router in addition to the above full internet working needs DNS server in addition to the above. You don't even hit the Basic w/out Internet. Please either give details from rc.conf, or read it's manpage so we can point you to the manpage again. --Tim
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?49948FC5.3070008>