carp and vlan at the same time?

Niki Denev nike_d at cytexbg.com
Fri May 30 09:58:11 UTC 2008


Hi Rudy,

On Fri, May 30, 2008 at 12:44 PM, Rudy <crapsh at monkeybrains.net> wrote:
>
> Dear NET,
>
> I have some questions!
>
> [1] vlan & carp
> I have 10.3.1.1/24  10.3.2.1/25 and a 10.3.3.129/25 as gateway IPs each in
> their own vlan.
> How do I get CARP working, or are people using another method to get
> failover working?
>

I'm currently using carp over VLANs over lagg and if works without problems.
So I think you should have no problems running carp over vlan interfaces.


> [2] carp
> Is there a way to get around the requirement to already have an IP in the
> same network as the IP you want to put on a carp device?   I don't think
> freevrrp required another IP...  For example, this command fails:
> # ifconfig carp1 vhid 31 advbase 1 pass TEST 10.3.3.1/24
> ifconfig: ioctl (SIOCAIFADDR): Can't assign requested address
>
> Unless I put a 10.3.3.2/24 IP on my em0, and then make the carp IP
> 10.3.3.1/32.
>

Yes, you need IP's for each of the gateways, and one "virtual" IP for the carp
interface. This is the way carp works.

> [3] vlan
> Final questions: is there any documentation on the "ifconfig em0.99 create"
> syntax?
> Didn't find the dot notation in the man page.  Also, how do you set that up
> in your rc.conf?
>
>  cloned_interfaces="em0.99"   # works.. clone is created
>  ifconfig_em0.99="10.99.0.1/24"  # doesn't work... /etc/rc.d/netif start
> em0.99 doesn't work...
>

You must use underscore instead of the dot. i.e. : ifconfig_em0_99=""
should work.

>
>
> Thanks in advance,
> Rudy
>

Regards,
Niki


More information about the freebsd-net mailing list