How do you avoid having all tcp/ip traffic routed through MGMT0 when your default route gateway is on the same vlan as the MGMT0 interface.

In our environment switches are set to use a default gateway (to the firewall) on our “Management” vlan (40) and are configured with in-band management ip’s on the vlan 40 interface.

I have two SN2010’s which I want to create MLAGs on. According to the documentation, you have to use the Out-of-band MGMT0 interface. So if I have them on vlan 40 and the routing table forces MGMT0 to be attached to the default vrf route, it ought to mean that all traffic without a static route will be passed through the 1Gb MGMT0 interface, which seems like a bad way to do things.

Ideally, if the default route has to be bound to a specific interface, I’d like to bind it to the vlan 40 interface - is that possible?

Hi Alistair,

If the default route on the switch is set to a next hop that is being provided by DHCP (default for the mgmt0 interface), the solution would be to disable DHCP, configure a static IP address on the mgmt interface, and then configure a new static default route with the next-hop IP of the gateway/firewall. Consider the following changes (which will need to be run from the serial console port or you will lose connectivity):

(config) # no interface mgmt0 DHCP

(config) # interface mgmt0 ip address x.x.x.x /x

(config) # ip default-gateway <---------points to a gateway IP address off of VLAN 55 as seen down below

After making the above changes, the route table should reflect the new default route going out the VLAN interface.:

(config) # show ip route


F: Failed to install in H/W

B: BFD protected (static route)

i: BFD session initializing (static route)

x: protecting BFD session failed (static route)

c: consistent hashing

p: partial programming in H/W

VRF Name default: mgmt0 direct 0/0

default vlan55 static 1/1 vlan55 direct 0/0 vlan56 direct 0/0

Please note: The next-hop address must be within the range of one of the IP interfaces on the system. In the example above, the vlan55 interface IP is The gateway IP is on the same subnet as the VLAN interface.

Just for clarification, the mgmt0 interface needs to be on the same subnet as the MLAG VIP. The IPL addresses of the switches are on their own subnet. Please see the following link for more information: