From owner-freebsd-questions@FreeBSD.ORG Sat Oct 20 13:14:34 2012 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 6F881C22 for ; Sat, 20 Oct 2012 13:14:34 +0000 (UTC) (envelope-from rwmaillists@googlemail.com) Received: from mail-ee0-f54.google.com (mail-ee0-f54.google.com [74.125.83.54]) by mx1.freebsd.org (Postfix) with ESMTP id EA1008FC08 for ; Sat, 20 Oct 2012 13:14:33 +0000 (UTC) Received: by mail-ee0-f54.google.com with SMTP id c50so610631eek.13 for ; Sat, 20 Oct 2012 06:14:26 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=date:from:to:subject:message-id:in-reply-to:references:x-mailer :mime-version:content-type:content-transfer-encoding; bh=KHDVuazM/x0Ce1wgojkac8/aFmv05mTntJAuZw6FxOU=; b=MIml3oNk0Uml+MqRaxOTzmRI+wiJ8huS3eDS/U5xyZMl9X7jk91t0V/XkA25skB1WA OAeBlxWlo3BF22SPjNPtV0hEROZCun12tCLqUCmW196OtMFtWta9bpdmknoXOx8XHgwo NfwM32HTlVc0dc7dlk3EY8GWdf00po/49yVHvaxIOa6ku+G4s3bQfyKVEIJzRlovY4Fn QLgQx8AAtqPfIBBvEVPiU/Hm2aPtEW104nIBlfeWgvtvq4z3aVJ8BW1l7FalqE0M4lIw gxDkoobJQ3MTBn6bC+DJ09k1OWvDI9aQgvHyaNzX7FUpY/1/Nezbzh48bGo0mRPWvSdn NaMg== Received: by 10.14.214.133 with SMTP id c5mr5511253eep.8.1350738866914; Sat, 20 Oct 2012 06:14:26 -0700 (PDT) Received: from gumby.homeunix.com (87-194-105-247.bethere.co.uk. [87.194.105.247]) by mx.google.com with ESMTPS id 7sm6990547eeg.5.2012.10.20.06.14.25 (version=SSLv3 cipher=OTHER); Sat, 20 Oct 2012 06:14:26 -0700 (PDT) Date: Sat, 20 Oct 2012 14:14:22 +0100 From: RW To: freebsd-questions@freebsd.org Subject: Re: pppoe configuration and dns name resolution Message-ID: <20121020141422.5beef665@gumby.homeunix.com> In-Reply-To: References: X-Mailer: Claws Mail 3.8.1 (GTK+ 2.24.6; amd64-portbld-freebsd8.3) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 20 Oct 2012 13:14:34 -0000 On Sat, 20 Oct 2012 09:42:31 +0530 Jack wrote: > Hi again, > > This time I disabled DHCP on my fxp0 interface and > in my adsl modem too. > But the problem still exists. > > This time I tried both approaches: > assigned an IP address explicitly to fxp0, and > then no explicit assignment to fxp0. I'd leave fxp0 unset until you've fixed the other problems - it's not necessary for PPP. Modems and routers in PPPoE bridging mode don't normally require any adjustment or other access so there's probably no need to assign address anyway. > I still don' get why FreeBSD is having trouble > connecting via PPP. The original problem you quoted was with DNS and that's explained by the DHCP on fxp0 overwriting resolv.conf with the router/modem's own non-functional DNS proxy. As regards ppp.conf mine was simply: default: set log Phase tun command adsl: set device PPPoE:vr0 set authname set authkey add default HISADDR > ppp_adsl_unit="0" > > > I tried to specify tun0 interface explicitly, > but still no luck. > When I start ppp using: > service ppp start > It shows tun0 is busy. Don't try to specify the tun device number. I've noticed in the past that occasionally tun0 becomes unusable and ppp will switch to tun1. I've seen this happen when I've been restarting ppp a lot. > From my understanding it shoud not matter whether fxp0 is > assigned the ip address via DHCP server on local lan or via > manually - at least this concept works on windows. > > But in FreeBSD, if I enable dhcp on fxp0, then > /etc/resolv.conf is created each time I boot in FreeBSD, > so the only nameserver being 192.168.1.1, ie adsl > modem ethernet interface. > Even if I edit it to include nameservers of my ISP or OpenDNS > this file is created each time FreeBSD boots, and these entries > are lost, with only entry being 192.168.1.1 > There's no good reason to use DHCP in this case, you can simply set a static private IP address (typically a high address in the same /24 as the modem). If you really must use DHCP then it can be reconfigured globally or per interface (type apropos dhclient). I notice that the original resolv.conf you quoted was set by resolvconf. I've never used this so I can't comment on whether it's helping or hindering. I suspect it aimed at laptops switching between different networks.