Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 26 Aug 2011 14:26:24 +0000
From:      Johan Hendriks <Johan@double-l.nl>
To:        "freebsd-questions@freebsd.org" <freebsd-questions@freebsd.org>
Subject:   (no subject)
Message-ID:  <6C3F8332272B7D4DA26909F15F1C90E1E5ABE6@SRV01.double-l.local>

Next in thread | Raw E-Mail | Index | Archive | Help
I am trying to set up CARP under 9.0

I want to know if my assumptions are right.

The master is the server with the lowest advskew, and has the state MASTER,=
 as where the slave will be in state BACKUP.
If the master fails, the slave will be promoted to MASTER.
If the master comes backup, the Master wil be Master again, and the slave f=
alls back to BACKUP.

At least this is what i think should be the case.

I now set up 2 FreeBSD 9.0 Beta1 machines.
One master, and one slave.

/etc/rc.conf on the master

ifconfig_bge0=3D"inet 192.168.50.40 netmask 255.255.255.0"
defaultrouter=3D"192.168.50.150"
# CARP
cloned_interfaces=3D"carp0"
ifconfig_carp0=3D"vhid 1 advskew 10 pass letmepass 192.168.50.45 netmask 25=
5.255.255.0"

On the slave i have the following in /etc/rc.conf

ifconfig_bge0=3D"inet 192.168.50.41 netmask 255.255.255.0"
defaultrouter=3D"192.168.50.150"
# CARP
cloned_interfaces=3D"carp0"
ifconfig_carp0=3D"vhid 1 advskew 20 pass letmepass 192.168.50.45 netmask 25=
5.255.255.0"

And on bothe machines i set
net.inet.carp.preempt=3D1

In my assumption, if i raise the advskew value on the master, i could let t=
hem flip role=92s
So doing ifconfig carp0 advskew 30 on the master should change roles.

However it does not happen

Ifconfig on the master
carp0: flags=3D49<UP,LOOPBACK,RUNNING> metric 0 mtu 1500
        inet 192.168.50.45 netmask 0xffffff00
        nd6 options=3D29<PERFORMNUD,IFDISABLED,AUTO_LINKLOCAL>
        carp: MASTER vhid 1 advbase 1 advskew 30

Ifconfig on the slave
carp0: flags=3D49<UP,LOOPBACK,RUNNING> metric 0 mtu 1500
        inet 192.168.50.45 netmask 0xffffff00
        nd6 options=3D29<PERFORMNUD,IFDISABLED,AUTO_LINKLOCAL>
        carp: BACKUP vhid 1 advbase 1 advskew 20

So even with the higher advskew value the master stays master.

Am i doing something wrong.

Regards,
Johan Hendriks



Want to link to this message? Use this URL: <http://docs.FreeBSD.org/cgi/mid.cgi?6C3F8332272B7D4DA26909F15F1C90E1E5ABE6>