From owner-freebsd-net@FreeBSD.ORG Fri Jun 3 00:14:28 2011 Return-Path: Delivered-To: freebsd-net@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 6D5351065672 for ; Fri, 3 Jun 2011 00:14:28 +0000 (UTC) (envelope-from jwd@SlowBlink.Com) Received: from nmail.slowblink.com (rrcs-24-199-145-34.midsouth.biz.rr.com [24.199.145.34]) by mx1.freebsd.org (Postfix) with ESMTP id 123F88FC1A for ; Fri, 3 Jun 2011 00:14:27 +0000 (UTC) Received: from nmail.slowblink.com (localhost [127.0.0.1]) by nmail.slowblink.com (8.14.3/8.14.3) with ESMTP id p530EPgj081648; Thu, 2 Jun 2011 20:14:25 -0400 (EDT) (envelope-from jwd@nmail.slowblink.com) Received: (from jwd@localhost) by nmail.slowblink.com (8.14.3/8.14.3/Submit) id p530EPaD081647; Thu, 2 Jun 2011 20:14:25 -0400 (EDT) (envelope-from jwd) Date: Thu, 2 Jun 2011 20:14:25 -0400 From: John De Boskey To: Patrick Lamaiziere Message-ID: <20110603001424.GA81480@slowblink.com> References: <20110602203940.GA80549@slowblink.com> <20110603003719.61292e9e@davenulle.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20110603003719.61292e9e@davenulle.org> User-Agent: Mutt/1.4.2.3i Cc: freebsd-net@freebsd.org Subject: Re: Production use of carp? X-BeenThere: freebsd-net@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Networking and TCP/IP with FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 03 Jun 2011 00:14:28 -0000 ----- Patrick Lamaiziere's Original Message ----- > Le Thu, 2 Jun 2011 16:39:40 -0400, > John a ?crit : > > > Instead of running carp on the external interfaces as below: > > > > ifconfig_cxgb0="inet 10.24.99.11 netmask 255.255.0.0" # System 1 > > physical ip ifconfig_cxgb0="inet 10.24.99.12 netmask 255.255.0.0" # > > System 2 physcial ip ifconfig_carp1="vhid 1 pass zfscarp1 advbase 1 > > advskew 100 10.24.99.13 netmask 255.255.0.0" # HA ip used by clients > > ... we instead connect a direct cross-over cable between the two > > systems providing HA/Failover and use a private (backside) network: > > I've missed this... > > As the purpose of carp is to provide a shared ip on a network, I don't > see why you are trying to use it on a cross-over network, between > only two machines? It seems useless to me. > > Regards. I have separate scripts which monitor the external interfaces on the two systems. If, for instance, one of the public ip addresses, 10.24.99.11 were to go down, the monitor script issues a ifconfig carp1 down, causing the service to shift over to partner system. These are actually hooked up with devd. These scripts also shift the virtual ip from one system to the other (as an ifconfig alias). I'm trying to avoid the controlling interface being on the external interfaces. As I said previously, exposing the vhid values to the external net (company internal net) means we have to be careful not to allow the same vhid twice, and to avoid the problem of the switch going down and both systems thinking they should be the master. In general, I attach exported filesystem services to different carp interfaces. I load balance them between the two HA servers. For instance, /vol/data1 is on carp1, /vol/data2 is on carp2. Under normal circumstance, /vol/data1 is "owned" by system A, and /vol/data2 is owned by sysem B. Issuing 'ifconfig carp1 down' on system A causes the export of /vol/data1 to shift over to system B at which point maintanence can be done on system A. The only problem is taking down system A causes the carp interfaces on system B to go down/up a few times. Does that help a bit? Thanks