Configurando MPLS TE em Roteadores Huawei
Requisitos: Ter mpls te corretamente configurado nas caixas da rede.
Observação: O túnel TE é aplicado apenas em um sentido, para fazer o caminho de ida e volta é necessário configurar nas duas pontas ajustando o explicit-path de acordo com o caminho desejado.
Itens que vamos configurar:
- explicit-path primário e secundário;
- interface tunnel;
- tunnel-policy;
- VPLS/VPWS onde aplicar.
Configurando o explicit-path
Nesse passo pode se mudar a rota para a desejada e fazer um tracert para pegar os saltos, caso não seja possível é necessário verificar os IPs salto a salto.
system-view explicit-path NOME_QUE_IDENTIFIQUE_A_ROTA_1 next hop IP_SALTO_1 next hop IP_SALTO_2 next hop IP_SALTO_3 next hop IP_SALTO_4 next hop IP_ÚLTIMO_SALTO quit explicit-path NOME_QUE_IDENTIFIQUE_A_ROTA_2 next hop IP_SALTO_1 next hop IP_SALTO_2 next hop IP_SALTO_3 next hop IP_SALTO_N include loose next hop IP_ÚLTIMO_SALTO quit
Observação: O include loose serve para que o equipamento calcule o caminho até o salto desejado, recomendo usar o IP de LoopBack da caixa para evitar quedas do túnel por queda de interface.
Configurando a interface túnel
Abaixo segue um dos possíveis métodos de configuração. Alguns parâmetros podem ser retirados e mesmo assim o túnel vai subir e funcionar, porém pode ter um comportamento diferente do esperado em caso de comutação de rota ou após queda do túnel.
Observação: Recomendo usar o ID da interface e do túnel os mesmo e, se possível, o mesmo ID da vlan ou do circuito para facilitar as verificações futuras.
interface Tunnel TUNNEL_ID ip address unnumbered interface LoopBack X tunnel-protocol mpls te destination IP_REMOTE_LOOPBACK mpls te tunnel-id TUNNEL_ID mpls te record-route mpls te path explicit-path NOME_QUE_IDENTIFIQUE_A_ROTA_1 mpls te path explicit-path NOME_QUE_IDENTIFIQUE_A_ROTA_2 secondary mpls te backup hot-standby mode revertive wtr 15 mpls te backup ordinary best-effort mpls te reserved-for-binding statistic enable
Detalhamento dos comandos acima:
mpls te backup hot-standby mode revertive wtr 15: usado para reverter o túnel para a rota principal após o retorno dela. Nesse caso quando a rota principal subir o tráfego vai voltar para a rota principal 15 segundos após o retorno dela. Se esse comando não for aplicado o tráfego vai ficar na rota secundária até ela cair.
mpls te backup ordinary best-effort: usado para, caso as rotas principal e secundária caiam, o equipamento calcular a próxima melhor rota, caso exista.
Configurando a tunnel-policy
A configuração da tunnel-policy é bem simples e sem mistérios.
tunnel-policy NOME_QUE_IDENTIFIQUE_O_DESTINO tunnel binding destination IP_REMOTE_LOOPBACK te Tunnel TUNNEL_ID
Após seguir os passos acima é necessário verificar se o túnel subiu antes de aplicar nos transportes, caso não tenha subido e ele for aplicado o serviço ficará indisponível.
Verificação com saída esperada:
display mpls te tunnel-interface Tunnel TUNNEL_ID
Tunnel Name : Tunnel TUNNEL_ID
Signalled Tunnel Name: -
Tunnel State Desc : Primary CR-LSP Up and HotBackup CR-LSP Up
Tunnel Attributes :
Active LSP : Primary LSP
Traffic Switch : -
Session ID : 2
Ingress LSR ID : x.x.x.x Egress LSR ID: y.y.y.y
Admin State : UP Oper State : UP
Signaling Protocol : RSVP
FTid : 2
Tie-Breaking Policy : None Metric Type : TE
Bfd Cap : None
Reopt : Disabled Reopt Freq : -
Inter-area Reopt : Disabled
Auto BW : Disabled Threshold : -
Current Collected BW: - Auto BW Freq : -
Min BW : - Max BW : -
Offload : Disabled Offload Freq : -
Low Value : - High Value : -
Readjust Value : -
Offload Explicit Path Name: -
Tunnel Group : Primary
Interfaces Protected: -
Excluded IP Address : -
Referred LSP Count : 0
Primary Tunnel : - Pri Tunn Sum : -
Backup Tunnel : -
Group Status : Up Oam Status : None
IPTN InLabel : - Tunnel BFD Status : -
BackUp LSP Type : Hot-Standby BestEffort : Enabled
Secondary HopLimit : -
BestEffort HopLimit : -
Secondary Explicit Path Name: NOME_QUE_IDENTIFIQUE_A_ROTA_2
Secondary Affinity Prop/Mask: 0x0/0x0
BestEffort Affinity Prop/Mask: 0x0/0x0
IsConfigLspConstraint: -
Hot-Standby Revertive Mode: Revertive
Hot-Standby Overlap-path: Disabled
Hot-Standby Switch State: CLEAR
Bit Error Detection: Disabled
Bit Error Detection Switch Threshold: -
Bit Error Detection Resume Threshold: -
Ip-Prefix Name : -
P2p-Template Name : -
PCE Delegate : No LSP Control Status : Local control
Path Verification : -
Entropy Label : None
Associated Tunnel Group ID: - Associated Tunnel Group Type: -
Auto BW Remain Time : - Reopt Remain Time : -
Metric Inherit IGP : None
Binding Sid : - Reverse Binding Sid : -
Self-Ping : Disable Self-Ping Duration : 1800 sec
FRR Attr Source : - Is FRR degrade down : -
Primary LSP ID : x.x.x.x:17118 LSP State : UP LSP Type : Primary Configured Attribute Information: Setup Priority : 7 Hold Priority: 7 IncludeAll : 0x0 IncludeAny : 0x0 ExcludeAny : 0x0 Affinity Prop/Mask : 0x0/0x0 Resv Style : SE Actual Attribute Information: Setup Priority : 7 Hold Priority: 7 IncludeAll : 0x0 IncludeAny : 0x0 ExcludeAny : 0x0 Metric Type : TE Metric : Unknown Configured Bandwidth Information: CT0 Bandwidth(Kbit/sec): 0 CT1 Bandwidth(Kbit/sec): 0 CT2 Bandwidth(Kbit/sec): 0 CT3 Bandwidth(Kbit/sec): 0 CT4 Bandwidth(Kbit/sec): 0 CT5 Bandwidth(Kbit/sec): 0 CT6 Bandwidth(Kbit/sec): 0 CT7 Bandwidth(Kbit/sec): 0 Actual Bandwidth Information: CT0 Bandwidth(Kbit/sec): 0 CT1 Bandwidth(Kbit/sec): 0 CT2 Bandwidth(Kbit/sec): 0 CT3 Bandwidth(Kbit/sec): 0 CT4 Bandwidth(Kbit/sec): 0 CT5 Bandwidth(Kbit/sec): 0 CT6 Bandwidth(Kbit/sec): 0 CT7 Bandwidth(Kbit/sec): 0 Explicit Path Name : NOME_QUE_IDENTIFIQUE_A_ROTA_1 Hop Limit: - Record Route : Enabled Record Label : Disabled Route Pinning : Disabled FRR Flag : Disabled IdleTime Remain : - BFD Status : - Soft Preemption : Disabled Reroute Flag : Enabled Pce Flag : Normal Path Setup Type : CSPF Create Modify LSP Reason: - Self-Ping Status : -
Backup LSP ID : x.x.x.x:39846 IsBestEffortPath : No LSP State : UP LSP Type : Hot-Standby Configured Attribute Information: Setup Priority : 7 Hold Priority: 7 IncludeAll : 0x0 IncludeAny : 0x0 ExcludeAny : 0x0 Affinity Prop/Mask : 0x0/0x0 Resv Style : SE Actual Attribute Information: Setup Priority : 7 Hold Priority: 7 IncludeAll : 0x0 IncludeAny : 0x0 ExcludeAny : 0x0 Metric Type : TE Metric : Unknown Configured Bandwidth Information: CT0 Bandwidth(Kbit/sec): 0 CT1 Bandwidth(Kbit/sec): 0 CT2 Bandwidth(Kbit/sec): 0 CT3 Bandwidth(Kbit/sec): 0 CT4 Bandwidth(Kbit/sec): 0 CT5 Bandwidth(Kbit/sec): 0 CT6 Bandwidth(Kbit/sec): 0 CT7 Bandwidth(Kbit/sec): 0 Actual Bandwidth Information: CT0 Bandwidth(Kbit/sec): 0 CT1 Bandwidth(Kbit/sec): 0 CT2 Bandwidth(Kbit/sec): 0 CT3 Bandwidth(Kbit/sec): 0 CT4 Bandwidth(Kbit/sec): 0 CT5 Bandwidth(Kbit/sec): 0 CT6 Bandwidth(Kbit/sec): 0 CT7 Bandwidth(Kbit/sec): 0 Explicit Path Name : NOME_QUE_IDENTIFIQUE_A_ROTA_2 Hop Limit: - Record Route : Enabled Record Label : Disabled Route Pinning : Disabled FRR Flag : Disabled IdleTime Remain : - BFD Status : - Soft Preemption : Disabled Reroute Flag : Enabled Pce Flag : Normal Path Setup Type : CSPF Create Modify LSP Reason: - Self-Ping Status : -
Caso a saída do comando esteja com algum dos itens em DOWN será necessário verificar IPs inseridos nas configurações, explicit-path, se os comandos de MPLS TE estão corretamente aplicados nas caixas e dentro das áreas OSPF dos caminhos.
Aplicando o túnel TE em VSIs
Após verificar que o túnel subiu e que as rotas principal e backup estão UP vamos aplicar o túnel no serviço para um peer da VSI:
vsi VSI_NAME tnl-policy NOME_QUE_IDENTIFIQUE_O_DESTINO
Aplicando o túnel TE em L2VC
Após verificar que o túnel subiu e que as rotas principal e backup estão UP vamos aplicar o túnel no serviço:
interface Vlanif XX mpls l2vc z.z.z.z L2VC_ID tunnel-policy NOME_QUE_IDENTIFIQUE_O_DESTINO
Observação: Na linha do mpls l2vc você deve manter outros parâmetros que já esteja usando no túnel para não causar a queda dele.