Re: dhclient and host resolution

From: Killermink ! (killermink_at_hotmail.com)
Date: 04/18/04

  • Next message: Matthew Seaman: "Re: base system vs. isc-dhcp : dhclient conflicts?"
    To: ohoyer@ohoyer.de
    Date: Sun, 18 Apr 2004 09:45:19 +0000
    
    

    Thats fantastic it works!

    I thought it would be something simple...

    I tried a

    $more /etc/resolv.conf

    But the file did not exist. So I su'ed and

    #echo "nameserver 192.168.2.1" > /etc/resolv.conf

    (this is the correct IP for the Mac)

    then

    #ping www.google.com

    And it worked immediately! Thanks very much, I feel pretty stupid with such
    an easy answer, but shouldn't this info be provided by dhclient? If I move
    to another network, say with a gateway of 10.x.x.x or other, will I have to
    change resolv.conf again? Is there anyway to get this automatically or is
    it a feature of FreeBSD/dhclient?

    Many thanks again!

    ----Original Message Follows----
    From: Olaf Hoyer <ohoyer@ohoyer.de>
    To: Killermink! <killermink@hotmail.com>
    CC: freebsd-questions@freebsd.org
    Subject: Re: dhclient and host resolution
    Date: Sun, 18 Apr 2004 11:21:42 +0200 (CEST)

    On Sun, 18 Apr 2004, Killermink ! wrote:

    > Hello,
    >
    > I have a Apple PowerBook running Panther and have set it to share my
    modem
    > internet connection over the Ethernet port. FreeBSD is connected to this
    > and should get all config via DHCP. When dhclient runs, it successfully
    > gets an IP Address from the Powerbook, and I can ping between machines...
      A
    > quick look at the leases file also shows that it has the Powerbook as the
    > Gateway and as the DNS server. However, I can only get to the Internet
    > from the BSD box using IP addresses, trying a url such as www.google.com
    > always fails as it cant resolve the host, plus the response is immediate
    as
    > if it hasn't tried or waited for a response.
    >

    Well, sound like DNS prblems.

    What is the content of your /etc/resolv.conf?

    then, when there is an entry like:

    nameserver 192.168.1.1

    (192.168.1.1 being the IP of the MAC), then check if the DNS on your MAC
    is working by:
    ####
    nslookup - 192.168.1.1

    set q=any
    freebsd.org
    ####

    Well, then your MAC should resolve some IP and mx data, when not, the
    DNS on your MAC is misfunctional.
    You also can specify DNS in the /etc/resolv.conf that are on the
    outside, or you could run named as caching resolver.

    Therefore, populate /etc/hosts with the IP/name of FreeBSD box, run
    /etc/named/make-localhost
    and then start named.

    In /etc/resolv.conf put a :
    nameserver 127.0.0.1

    as first nameserver statement, and FreeBSD will directly resolve...

    HTH
    Olaf

    --
    Olaf Hoyer        ohoyer@gaff.hhhr.ision.net
    Fuerchterliche Erlebniss geben zu raten,
    ob der, welcher sie erlebt, nicht etwas Fuerchterliches ist.
    (Nietzsche, Jenseits von Gut und Boese)
    _______________________________________________
    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"
    _________________________________________________________________
    It's fast, it's easy and it's free. Get MSN Messenger today! 
    http://www.msn.co.uk/messenger
    _______________________________________________
    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"
    

  • Next message: Matthew Seaman: "Re: base system vs. isc-dhcp : dhclient conflicts?"

    Relevant Pages

    • Re: dhclient and host resolution
      ... > gets an IP Address from the Powerbook, and I can ping between machines... ... Well, sound like DNS prblems. ... (192.168.1.1 being the IP of the MAC), then check if the DNS on your MAC ... Well, then your MAC should resolve some IP and mx data, when not, the ...
      (freebsd-questions)
    • Re: FreeBSD challenged by Internet
      ... FreeBSD is doing something slightly different. ... Yes, it is, it's making IPv6 DNS queries. ... These problems is particularly acute in countries where PPPoA is the ... (where the ISP supports PPPoE over atm). ...
      (freebsd-questions)
    • RE: Cannot Ping Beyond Default Gateway & DHCP Server
      ... The first thing the TW guy did was to plug in his laptop and demonstrate ... says he has never had to change a MAC nor tell the home office to change one. ... Network Diagnostics shows pings to his IP, Default Gateway, and DHCP Server ... Verified manually (pings to those DNS ...
      (microsoft.public.windowsxp.network_web)
    • Ghost DNS entry
      ... Re: Ghost DNS record ... PTR record on all DNS server and I cannot find that record on ... However I can still resolve IP from name using ...
      (microsoft.public.windows.server.dns)
    • FreeBSD Security Advisory FreeBSD-SA-08:06.bind
      ... For general information regarding FreeBSD Security Advisories, ... BIND 9 is an implementation of the Domain Name System (DNS) protocols. ... The lack of source port randomization reduces the amount of data the ...
      (FreeBSD-Security)