Forum Discussion

rmd1023's avatar
rmd1023
Icon for Nimbostratus rankNimbostratus
May 26, 2016

MAC address masquerade configuration for multi-VLAN trunk interface

I've got a 2-device LTM cluster with a 2-port LACP-bundle trunk that has several VLANs on it, and I'm looking at deploying MAC masquerade. Currently, the LTM cluster does not have masquerade configured. I've been looking at https://support.f5.com/kb/en-us/solutions/public/13000/500/sol13502.html for configuration instructions. Do I only need to set a single virtual MAC, or do I need to specify a virtual MAC for each VLAN? If only one, will it iterate through virtual MACs for each VLAN like it does with the predefined MAC addresses? Or will it end up using the same MAC address for each VLAN?

 

For example, currently, the (anonymized) MAC address for the eth0 interface is:

 

eth0 Link encap:Ethernet HWaddr DE:AD:BE:EF:00:01

 

But each VLAN IP interface has a VLAN-specific MAC address that's the same as the base eth0 MAC address with a different last byte. I.e.:

 

MYVLAN1 Link encap:Ethernet HWaddr DE:AD:BE:EF:00:07

 

MYVLAN2 Link encap:Ethernet HWaddr DE:AD:BE:EF:00:08

 

MYVLAN3 Link encap:Ethernet HWaddr DE:AD:BE:EF:00:09

 

MYVLAN4 Link encap:Ethernet HWaddr DE:AD:BE:EF:00:0A

 

If I configure my LTM and go to Device Management->Traffic Groups->traffic-group-1 and enter 2B:AD:BE:EF:00:01 in the "MAC Masquerade Address" field, will my interface MAC addresses be like this?

 

eth0 Link encap:Ethernet HWaddr 2B:AD:BE:EF:00:01

 

MYVLAN1 Link encap:Ethernet HWaddr 2B:AD:BE:EF:00:07

 

MYVLAN2 Link encap:Ethernet HWaddr 2B:AD:BE:EF:00:08

 

etc

 

or will each VLAN have the same virtual MAC, like this:

 

eth0 Link encap:Ethernet HWaddr 2B:AD:BE:EF:00:01

 

MYVLAN1 Link encap:Ethernet HWaddr 2B:AD:BE:EF:00:01

 

MYVLAN2 Link encap:Ethernet HWaddr 2B:AD:BE:EF:00:01

 

Thanks!

 

  • MAC address masquerading will only affect objects that are in the according traffic-group, in your example above "traffic-group-1". Your non-floating interface IPs should belong to the "local-only" traffic group and thus be not affected when changing this setting. The masqued MAC address for the floating objects that belong to traffic-group-1 (floating self IPs, virtual addresses, SNAT addresses and so on) will be the same for all objects though (no incrementing). But that is also the case without MAC masquerading. The only difference is that the used MAC address will no longer differ between both cluster members when using MAC masquerading.