On Aug 9, 2006, at 6:59 PM, Christopher Snell wrote:
Hi All,
We're setting up some VLAN routers using a pair of machines. We have
a bunch of VLANs and we're using CARP to provide redunancy.
Currently, there is a carpNNN interface built on top of every vlanNNN
interface, which are themselves built on the actual ethernet
interface. We're using VLAN IDs as high as 1000. The CARP vhid's,
however, can only go as high as 255 per ifconfig(8). Is there a way
to increase this number to match the VLAN limit (4096, I believe)? Or,
perhaps we're doing this wrong and we should be using the same vhid
for every CARP interface? Can somebody enlighten me?
Unless you're using more than 255 VLANs (unlikely), you don't need
that many vhids. Your VLAN id's won't match your vhids, but they
don't need to, even for readability. Use the description value
(ifconfig (8)) or assign it to a named group. If you use a
description in your VLAN, assign that value as your CARP interface
description and group. Then you can simply refer to the group value
when you're looking for an interface. Example:
# ifconfig carp5 group guest
# ifconfig guest
carp5: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> mtu 1500
description: GUEST
carp: MASTER carpdev vlan5 vhid 205 advbase 1 advskew 0
groups: carp guest
inet 10.200.0.1 netmask 0xffffff00 broadcast 10.200.0.255
As far as the limit of 255 goes, you'll notice that the vhid is equal
to the last octet of the virtual mac address for the CARP interface
(can be seen by tcpdump'g CARP traffic on your vlan interface).
HTH.
--
Jason Dixon
DixonGroup Consulting
http://www.dixongroup.net