From owner-freebsd-stable@freebsd.org Tue May 8 13:04:43 2018 Return-Path: Delivered-To: freebsd-stable@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id A7871FB55CB for ; Tue, 8 May 2018 13:04:43 +0000 (UTC) (envelope-from eugen@grosbein.net) Received: from hz.grosbein.net (unknown [IPv6:2a01:4f8:d12:604::2]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "hz.grosbein.net", Issuer "hz.grosbein.net" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 28F83877F4 for ; Tue, 8 May 2018 13:04:42 +0000 (UTC) (envelope-from eugen@grosbein.net) Received: from eg.sd.rdtc.ru (root@eg.sd.rdtc.ru [62.231.161.221] (may be forged)) by hz.grosbein.net (8.15.2/8.15.2) with ESMTPS id w48D4Dt6072830 (version=TLSv1.2 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Tue, 8 May 2018 15:04:14 +0200 (CEST) (envelope-from eugen@grosbein.net) X-Envelope-From: eugen@grosbein.net X-Envelope-To: darius@dons.net.au Received: from [10.58.0.4] (dadv@[10.58.0.4]) by eg.sd.rdtc.ru (8.15.2/8.15.2) with ESMTPS id w48D3o69046225 (version=TLSv1.2 cipher=DHE-RSA-AES128-SHA bits=128 verify=NOT); Tue, 8 May 2018 20:03:50 +0700 (+07) (envelope-from eugen@grosbein.net) Subject: Re: Userland PPP on ADSL To: "O'Connor, Daniel" , freebsd-stable References: <3D16459D-B083-4CAC-BA9E-D48EF55B5EB0@dons.net.au> From: Eugene Grosbein Message-ID: <5AF1A036.9080305@grosbein.net> Date: Tue, 8 May 2018 20:03:50 +0700 User-Agent: Mozilla/5.0 (Windows NT 6.3; WOW64; rv:38.0) Gecko/20100101 Thunderbird/38.7.2 MIME-Version: 1.0 In-Reply-To: <3D16459D-B083-4CAC-BA9E-D48EF55B5EB0@dons.net.au> Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=4.9 required=5.0 tests=BAYES_00, DATE_IN_FUTURE_96_Q, LOCAL_FROM, RDNS_NONE, SPF_PASS autolearn=no autolearn_force=no version=3.4.1 X-Spam-Report: * 2.7 DATE_IN_FUTURE_96_Q Date: is 4 days to 4 months after Received: date * -0.0 SPF_PASS SPF: sender matches SPF record * -2.3 BAYES_00 BODY: Bayes spam probability is 0 to 1% * [score: 0.0000] * 1.9 RDNS_NONE Delivered to internal network by a host with no rDNS * 2.6 LOCAL_FROM From my domains X-Spam-Level: **** X-Spam-Checker-Version: SpamAssassin 3.4.1 (2015-04-28) on hz.grosbein.net X-BeenThere: freebsd-stable@freebsd.org X-Mailman-Version: 2.1.25 Precedence: list List-Id: Production branch of FreeBSD source code List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 08 May 2018 13:04:43 -0000 08.05.2018 12:08, O'Connor, Daniel wrote: > Hi, > I have several FreeBSD machines setup as routers connected to ADSL modems in bridge mode. ie the FreeBSD box terminates the PPP connection and the ADSL modem doesn't do much. > > This worked well for many moons but a while ago I found issues with the inbuilt PPP and ended up switching to mpd5 which has so far worked flawlessly. > > I was wondering if anyone else had also seen similar issues? > > In my experience PPP will hang for a long time when the ADSL link goes down. It does seem to eventually come back (minutes later) but while it's stuck it will only exit with kill -9. > > This wouldn't be such a big deal but the rc.d script doesn't actually check if the PPP process exits so a naive monitoring script that does 'service ppp restart' will end up with 2 processes which usually screws up firewall rules. There are ways around this (eg have the script check, or set ppp_unit) but it seems like a bug. > > The only log messages I see are.. > May 8 12:27:53 portero ppp[76165]: tun0: LCP: deflink: SendEchoReply(114) state = Opened > May 8 12:27:54 portero ppp[76165]: tun0: LCP: deflink: SendEchoRequest(38) state = Opened > May 8 12:27:54 portero ppp[76165]: tun0: LCP: deflink: RecvEchoReply(38) state = Opened > May 8 12:28:54 portero ppp[76165]: tun0: LCP: deflink: SendEchoRequest(39) state = Opened > May 8 12:29:54 portero ppp[76165]: tun0: LCP: deflink: SendEchoRequest(40) state = Opened > > Does anyone have any suggestions where to start looking? It would be nice if the base tool worked properly for what I feel is a not uncommon scenario :) You have not specified FreeBSD version you use. First, you should check if the ppp process is waiting on some system call when it's hung. Use ps -l or procstat to check it. And you should enable verbose logs in ppp.conf.