From owner-freebsd-questions@FreeBSD.ORG Sat May 3 06:10:08 2003 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 4C34A37B401 for ; Sat, 3 May 2003 06:10:08 -0700 (PDT) Received: from grover.logicsquad.net (ppp350.sa.padsl.internode.on.net [150.101.245.93]) by mx1.FreeBSD.org (Postfix) with SMTP id 06A6C43FAF for ; Sat, 3 May 2003 06:10:06 -0700 (PDT) (envelope-from paulh@logicsquad.net) Received: (qmail 2452 invoked by uid 1000); 3 May 2003 13:10:04 -0000 Date: Sat, 3 May 2003 22:40:04 +0930 From: "Paul A. Hoadley" To: Adam Message-ID: <20030503131004.GB2072@grover.logicsquad.net> References: <20030503011200.GA93080@grover.logicsquad.net> <1051957713.45399.8.camel@jake> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1051957713.45399.8.camel@jake> User-Agent: Mutt/1.4i cc: freebsd-questions@freebsd.org Subject: Re: auto restarting a ppp connection X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 03 May 2003 13:10:08 -0000 On Sat, May 03, 2003 at 06:28:34AM -0400, Adam wrote: > On Fri, 2003-05-02 at 21:12, Paul A. Hoadley wrote: > > On Fri, May 02, 2003 at 09:44:33PM +0800, Paul Hamilton wrote: > > > > > I have tried to put the whole routine into a script, ie, find the > > > pid, kill it, wait, then restart the ppp connection. The idea, was > > > that I could link it with a ping tester, then when I miss 'x' number > > > of pings, restart the connection. This is what I used:- > > > > Here is a script Aaron Hill wrote that does precisely that: > > > > http://logicsquad.net/freebsd/pingmonitor-how-to.html > > > > Run it with cron as frequently as you like. Instructions for > > customising it are on that page. > > Is this script really any better than enabling LQR and setting up an > automatic reconnect on disconnection in the ppp.conf? The short answer is yes, it was for me. I ran PPPoE with /usr/sbin/ppp for a couple of years using '-ddial' mode and with LQR enabled. ppp really would get completely wedged about once a month (continuous uptime throughout), and was not resetting the connection despite the fact that the link was completely dead. It is not clear whether it was ISP-related, though I suspect so, since I have not seen this behaviour since I switched ISPs about 6 months ago. Over the years I've seen it reported (a completely wedged /usr/sbin/ppp) on this list several times. The problem with debugging it is that it's very hard to reproduce -- it can take weeks of uptime to occur, and it's never clear what precipitates it. If the OP is finding that a kill -9 is the only way to fix his problem, then he's probably observing the same behaviour. I don't use it anymore, but the script seems like a reasonable workaround. -- Paul. mailto:paulh@logicsquad.net mailto:phoadley@maths.adelaide.edu.au