From owner-freebsd-net@FreeBSD.ORG Wed Dec 10 08:41:23 2003 Return-Path: Delivered-To: freebsd-net@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 7567516A4CE for ; Wed, 10 Dec 2003 08:41:23 -0800 (PST) Received: from mx01.bos.ma.towardex.com (a65-124-16-8.svc.towardex.com [65.124.16.8]) by mx1.FreeBSD.org (Postfix) with ESMTP id 87CAA43D21 for ; Wed, 10 Dec 2003 08:41:22 -0800 (PST) (envelope-from haesu@mx01.bos.ma.towardex.com) Received: by mx01.bos.ma.towardex.com (TowardEX ESMTP 3.0p11_DAKN, from userid 1001) id 3A50C2F8F9; Wed, 10 Dec 2003 11:41:27 -0500 (EST) Date: Wed, 10 Dec 2003 11:41:27 -0500 From: James To: Andrea Venturoli Message-ID: <20031210164127.GA92069@scylla.towardex.com> References: <200312101324.hBADOUc8064056@soth.ventu> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <200312101324.hBADOUc8064056@soth.ventu> User-Agent: Mutt/1.4.1i cc: freebsd-net@freebsd.org Subject: Re: Two ISP connections X-BeenThere: freebsd-net@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Networking and TCP/IP with FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 10 Dec 2003 16:41:23 -0000 > Hello. > I have a server with two ISP connections: a flat ADSL with an ISP and pay-per-traffic HDSL with another. > I'd like to use ADSL whenever possible, but switch to HDSL in case the first line drops. > Any pointer? > > bye & Thanks > av. Write a script and cronjob it to check every 5 minutes. The script should: a) ping both ISP gateways or use other means to check connectivity b) If the primary connection is down, remove the default route and point the default route to backup ISP. c) If using NAT, flush the nat rules, and re-map the internal network to backup ISP's IP address. d) If the primary ISP is back online, do vice versa to switch back. That's one way of doing it. You can also write a daemon too that's more robust than a simple shell script. -J -- James Jun (formerly Haesu) Network Operations TowardEX Technologies, Inc. Consulting, colocation, web hosting, network design and implementation http://www.towardex.com | james@towardex.com Cell: (978)394-2867 | Office: (978)263-3399 Ext. 170 Fax: (978)263-0033 | AIM: GigabitEthernet0 NOC: http://www.twdx.net | POC: HAESU-ARIN, HDJ1-6BONE