From owner-freebsd-current@FreeBSD.ORG Fri Feb 3 09:35:21 2012 Return-Path: Delivered-To: freebsd-current@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 3D1FE106566C for ; Fri, 3 Feb 2012 09:35:21 +0000 (UTC) (envelope-from andrew.hobbs@ai.net) Received: from ginga.ai.net (ginga.ai.net [205.134.166.19]) by mx1.freebsd.org (Postfix) with ESMTP id 04D6E8FC0C for ; Fri, 3 Feb 2012 09:35:20 +0000 (UTC) Received: from ginga.ai.net ([205.134.166.19]) by ginga.ai.net ([205.134.166.19]) with mapi; Fri, 3 Feb 2012 04:35:19 -0500 From: Andrew Hobbs To: Sergey Kandaurov Date: Fri, 3 Feb 2012 04:35:16 -0500 Thread-Topic: CARP on -CURRENT Thread-Index: AczheGMg3AgG5eGOTtiOMwRX6/gYrgA3Fuzg Message-ID: References: In-Reply-To: Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: acceptlanguage: en-US Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 Cc: "freebsd-current@freebsd.org" Subject: RE: CARP on -CURRENT X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 03 Feb 2012 09:35:21 -0000 > -----Original Message----- > From: Sergey Kandaurov [mailto:pluknet@gmail.com]=20 > Sent: Thursday, February 02, 2012 2:00 AM > To: Andrew Hobbs > Cc: freebsd-current@freebsd.org > Subject: Re: CARP on -CURRENT > > On 2 February 2012 04:26, Andrew Hobbs wrote: > > I much appreciate the responses and I was able to get CARP functioning= =20 > > using the new ifconfig syntax under -CURRENT. Having done that, CARP=20 > > is now acting as it should, though now I have a new challenge with=20 > > devd and automatic firing of scripts during CARP failover. It appears=20 > > that the documented method of doing this at=20 > > http://www.freebsd.org/doc/handbook/disks-hast.html no longer works=20 > > with the suggested devd.conf setup; notify 30 { > > =A0 =A0 =A0 =A0match "system" "IFNET"; > > =A0 =A0 =A0 =A0match "subsystem" "carp0"; > > =A0 =A0 =A0 =A0match "type" "LINK_UP"; > > =A0 =A0 =A0 =A0action "/usr/local/sbin/carp-hast-switch master"; }; > > > > notify 30 { > > =A0 =A0 =A0 =A0match "system" "IFNET"; > > =A0 =A0 =A0 =A0match "subsystem" "carp0"; > > =A0 =A0 =A0 =A0match "type" "LINK_DOWN"; > > =A0 =A0 =A0 =A0action "/usr/local/sbin/carp-hast-switch slave"; > > > > Is it likely that the triggers associated with CARP for devd have chang= ed due to the recent new CARP overhaul? Does anyone know what the new trigg= ers may be? > > > > You will need to change this to something like (as taken from man carp): > match "system" "CARP"; > match "subsystem" "[0-9]+@"; > match "type" "(MASTER|BACKUP)"; > > The subsystem now is generated as > snprintf(subsys, IFNAMSIZ+5, "%u@%s", sc->sc_vhid, sc->sc_carpdev->if_xna= me); > > -- > wbr, > pluknet Thanks for the info. I was able to get the triggers firing from devd. I als= o noticed that the man page on 'carp' references a "carpcontrol.sh" script = as an action. Has this script been prototyped anywhere yet?=20 -Andrew