Sunteți pe pagina 1din 4

Interface Bonding 802.

3ad (LACP) with Mikrotik


and Cisco
Bonding (also called port trunking or link aggregation) can be configured quite easily on RouterOS-
Based devices.

Having 2 NICs (ether1 and ether2) in each router (Router1 and Router2), it is possible to get maximum
data rate between 2 routers, by aggregating port bandwidth.

To add a bonding interface on Router1 and Router2:

/interface bonding add slaves=ether1,ether2

(bonding interface needs a couple of seconds to get connectivity with its peer)

Link Monitoring:
Currently bonding in RouterOS supports two schemes for monitoring a link state of slave devices:
MII and ARP monitoring. It is not possible to use both methods at a time due to restrictions in the
bonding driver.

ARP Monitoring:
ARP monitoring sends ARP queries and uses the response as an indication that the link is
operational. This also gives assurance that traffic is actually flowing over the links. If balance-rr and
balance-xor modes are set, then the switch should be configured to evenly distribute packets across
all links. Otherwise all replies from the ARP targets will be received on the same link which could
cause other links to fail. ARP monitoring is enabled by setting three properties link-monitoring, arp-ip-
targets and arp-interval. Meaning of each option is described later in this article. It is possible to
specify multiple ARP targets that can be useful in a High Availability setups. If only one target is
set, the target itself may go down. Having an additional targets increases the reliability of the ARP
monitoring.

MII Monitoring:
MII monitoring monitors only the state of the local interface. In RouterOS it is possible to
configure MII monitoring in two ways:

MII Type 1: device driver determines whether link is up or down. If device driver does not support
this option then link will appear as always up.
MII Type 2: deprecated calling sequences within the kernel are used to determine if link is up. This
method is less efficient but can be used on all devices. This mode should be set only if MII type 1 is
not supported.

Main disadvantage is that MII monitoring can’t tell if the link actually can pass the packets or not
even if the link is detected as up.
MII monitoring is configured setting desired link-monitoring mode and mii-interval.

Configuration Example: 802.3ad (LACP) with Cisco Catalyst GigabitEthernet Connection.

/inteface bonding add slaves=ether1,ether2 \


mode=802.3ad lacp-rate=30secs \
link-monitoring=mii-type1 \
transmit-hash-policy=layer-2-and-3

Other part configuration (assuming the aggregation switch is a Cisco device, usable in
EtherChannel / L3 environment):

!
interface range GigabitEthernet 0/1-2
channel-protocol lacp
channel-group 1 mode active
!
interface PortChannel 1
no switchport
ip address XXX.XXX.XXX.XXX XXX.XXX.XXX.XXX
!

Or for EtherChannel / L2 environment:

!
interface range GigabitEthernet 0/1-2
channel-protocol lacp
channel-group 1 mode active
!
interface PortChannel 1
switchport
switchport mode access
swichport access vlan XX
!

Tags: 802.3ad, Bonding, Cisco, EtherChannel, LACP, Mikrotik


Interface Bonding 802.3ad (LACP) con Mikrotik y
Cisco
La vinculación (también llamada enlace de puertos o agregación de enlaces) se puede configurar con
bastante facilidad en los dispositivos basados en RouterOS.

Al tener 2 NIC ( ether1 y ether2 ) en cada enrutador ( Router1 y Router2 ), es posible obtener la
velocidad de datos máxima entre 2 enrutadores, agregando el ancho de banda del puerto.

Para agregar una interfaz de enlace en Router1 y Router2:

/ interfaz de unión agregar esclavos = éter1, éter2

(la interfaz de enlace necesita un par de segundos para obtener conectividad con su par)

Monitoreo de enlaces:
Actualmente, el enlace en RouterOS admite dos esquemas para monitorear un estado de enlace de
dispositivos esclavos: monitoreo MII y ARP. No es posible utilizar ambos métodos a la vez debido
a restricciones en el controlador de enlace.

Monitoreo ARP:
La supervisión de ARP envía consultas de ARP y utiliza la respuesta como una indicación de que el
enlace está operativo. Esto también garantiza que el tráfico fluye realmente a través de los
enlaces. Si se establecen los modos balance-rr y balance-xor, entonces el conmutador debe
configurarse para distribuir uniformemente los paquetes en todos los enlaces. De lo contrario, todas
las respuestas de los objetivos ARP se recibirán en el mismo enlace, lo que podría hacer que otros
enlaces fallen. La monitorización ARP se habilita configurando tres propiedades de monitorización de
enlaces, arp-ip-target y arp-interval . El significado de cada opción se describe más adelante en este
artículo. Es posible especificar múltiples objetivos ARP que pueden ser útiles en una configuración
de alta disponibilidad. Si solo se establece un objetivo, el objetivo en sí puede bajar. Tener objetivos
adicionales aumenta la fiabilidad de la monitorización ARP.

Monitoreo MII:
La supervisión de MII solo supervisa el estado de la interfaz local. En RouterOS es posible
configurar el monitoreo MII de dos maneras:

MII Tipo 1: el controlador del dispositivo determina si el enlace está activo o inactivo. Si el
controlador del dispositivo no admite esta opción, el enlace aparecerá como siempre arriba.
MII Tipo 2: las secuencias de llamada en desuso dentro del kernel se utilizan para determinar si el
enlace está activo. Este método es menos eficiente pero se puede utilizar en todos los
dispositivos. Este modo se debe configurar solo si MII tipo 1 no es compatible.

La principal desventaja es que el monitoreo MII no puede decir si el enlace puede pasar los
paquetes o no, incluso si se detecta que el enlace está activo.
La supervisión de MII está configurada configurando el modo de supervisión de enlacedeseado y mii-
intervalo .

Ejemplo de configuración: 802.3ad (LACP) con Cisco Catalyst GigabitEthernet


Connection.

/ Inteface bonding add slaves = ether1, ether2 \


mode = 802.3ad lacp-rate = 30secs \
monitorización de enlace = mii-tipo1 \
transmit-hash-policy = layer-2-and-3

Configuración de otra parte (asumiendo que el conmutador de agregación es un dispositivo de


Cisco, utilizable en el entorno EtherChannel / L3):

!
Rango de interfaz GigabitEthernet 0 / 1-2
lacp de protocolo de canal
modo canal-grupo 1 activo
!
interfaz PortChannel 1
no switchport
dirección ip XXX.XXX.XXX.XXX XXX.XXX.XXX.XXX
!

O para el entorno EtherChannel / L2:

!
Rango de interfaz GigabitEthernet 0 / 1-2
lacp de protocolo de canal
modo canal-grupo 1 activo
!
interfaz PortChannel 1
puerto de conmutación
acceso al modo switchport
swichport access vlan XX
!

Etiquetas: 802.3ad , Enlace , Cisco , EtherChannel , LACP , Mikrotik

S-ar putea să vă placă și