SlideShare uma empresa Scribd logo
1 de 84
Baixar para ler offline
1Tutorial BGP - GTER
BGP v4 – Tutorial
17º GTER
Caio Klein
2Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 2Tutorial BGP - GTER
Agenda
Introdução ao BGP v4
Protocolo BGP e Atributos
iBGP e eBGP
Políticas de Roteamento BGP
Intervalo
Escalando o iBGP Full Mesh
Route Reflection
Confederations
Novas facilidades do BGP
Route Damping
3Tutorial BGP - GTER
Introdução ao BGP v4
4Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 4Tutorial BGP - GTER
BGP – Border Gateway Protocol v4
Algumas referências do BGP v4
RFCs 1771 e 1772 - BGP v4
RFCs 1965 - Autonomous System Confederations
RFC 1966 - Route Reflection
RFC 1997 - Communities
RFC 2270 - Dedicated AS’s
RFC 2283 - MBGP
RFC 2385 - BGP MD5 Authentication
RFC 2439 - Route Damping
RFC 2842 - Capabilities Negotiation
5Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 5Tutorial BGP - GTER
Autonomous System (AS)
O que é um AS?
Grupo de roteadores
• Administrados com uma política comum de
roteamento
• Operam sob a mesma administração técnica
• Percebidos externamente como um único domínio
de roteamento
Inteiro de 16 bits (1-65535)
64512-65535 AS - Privados
6Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 6Tutorial BGP - GTER
Internet - Coleção de ASs
Técnicas de IGP não são aplicáveis neste ambiente. É
necessário maior escalabilidade
Protocolo deve refletir acordos entre ASs - Flexibilidade
AS 9999
AS 8888 AS 7777
7Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 7Tutorial BGP - GTER
O que é o BGP?
BGP é um protocolo de roteamento do tipo inter-
domínio que transmite informações de prefixos
BGP é um protocolo do tipo “path vector”
Similar ao “distance vector”
BGP percebe a Internet como uma coleção de
autonomous systems (AS)
BGP suporta CIDR
Roteadores BGP trocam informações de
roteamento entre “peers”
8Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 8Tutorial BGP - GTER
Fundamentos do BGP
Rotas consistem de
Destino – usualmente prefixo IP
Informações que descrevem o caminho até o
destino
• Atributos
Peers BGP anunciam NLRI entre si em
mensagens do tipo “update”
O BGP compara o AS path e outros atributos
para selecionar o melhor caminho
Rotas indisponíveis podem ser anunciadas
Rotas não alcançáveis são removidas
(withdrawn)
9Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 9Tutorial BGP - GTER
Analisando rotas BGP
Olhando entrada específica na tabela de roteamento
user@host> show route 172.16.0.0 extensive
inet.0: 6 destinations, 6 routes (5 active, 0 holddown, 1 hidden)
+ = Active Route, - = Last Active, * = Both
172.16.0.0/12 (1 entry, 1 announced)
TSI:
BGP_Sync_Any dest 172.16.0.0/12 MED 0
*BGP Preference: 170/-101
Nexthop: 11.1.1.1 via fe-0/0/0.0, selected
State: <Active Int Ext>
Local AS: 29 Peer AS: 29
Age: 1d 9:46:54 Metric2: 0
Task: BGP_29.11.1.1.1+1048
Announcement bits (2): 0-KRT 2-BGP_Sync_Any
AS path: 9999 8888 7777 I
BGP next hop: 11.1.1.1
Localpref: 100
Router ID: 172.18.1.1
10Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 10Tutorial BGP - GTER
Conexões BGP
BGP utiliza conexões TCP
TCP port 179
Serviços TCP
• Fragmentation, Acknowledgments, Checksums,
Sequencing e Flow Control
Sem descoberta automática de vizinho
Atualizações do BGP são incrementais
Sem “refreshes” regulares
Exceto no estabelecimento da sessão quando
o volume de roteamento pode ser grande
11Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 11Tutorial BGP - GTER
BGP Peering
Sessões BGP são estabelecidas entre peers
BGP Speakers
Dois tipos de sessões de peering
E-BGP (externo) peers AS's diferentes
I-BGP (interno) peers dentro do mesmo AS
Ainda é necessário o interior gateway protocol
(IGPs)
IGP conecta os BGP speakers dentro do AS
IGP anuncia rotas internas
12Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 12Tutorial BGP - GTER
BGP Peering
eBGP Peering
AS 9999AS 8888 AS 7777
iBGP Peering
ISIS
OSPFISIS
13Tutorial BGP - GTER
Mensagens do BGPv4
14Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 14Tutorial BGP - GTER
Mensagens do Protocolo BGP
Quatro tipos de mensagem
Open
Update
Notification
Keepalive
Utilizam um cabeçalho em comum
15Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 15Tutorial BGP - GTER
Cabeçalho Comum
19 bytes de comprimento
Utilizado para autenticação
Marker Field (16 bytes)
Length Field (2 bytes) Type Field (1 byte)
16Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 16Tutorial BGP - GTER
Mensagem Open
Após uma conexão TCP ser estabelecida, os
peers BGP trocam mensagens “open”para
criar uma conexão BGP
Sobre uma conexão BGP os peers trocam
outras mensagens BGP e dados como
informações de roteamento
17Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 17Tutorial BGP - GTER
Mensagem Open
Marker Field
Length Field Type Field Version (1 byte)
My Autonomous System Hold Time
BGP Identifier
Opt. Parameters
Length
Optional Parameters
(Variable Length)
18Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 18Tutorial BGP - GTER
Mensagem Update
Cada “update” contem um anúncio de caminho
com seus atributos e destinos
Muitos destinos (prefixos) podem compartilhar
o mesmo caminho
Sistemas BGP utilizam essa informação para
construir um gráfico descrevendo as relações
entre todos os ASs
19Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 19Tutorial BGP - GTER
Mensagem Update
Mensagens que possuem os mesmos atributos
devem ser agrupadas num mesmo update
Withdrawn Routes Length (2 octets)
Header
Path Attributes (Variable Length)
Withdrawn Routes (Variable)
Total Path Attributes (2 octets)
~ ~
Network Layer Reachability information (Variable Length)
20Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 20Tutorial BGP - GTER
Mensagem Keepalive
Sistemas BGP trocam mensagens keepalive
para determinar se um link ou peer falhou ou
não está mais disponível
Mensagens são trocadas frequentemente
para o tempo de “hold” não expirar
Intervalos de 30s entre keepalives e hold timer
de 90s são default (JUNOS)
• Hold timer é negociado entre peers
Contem apenas o BGP header (19 bytes)
21Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 21Tutorial BGP - GTER
Mensagem Notification
Sistemas BGP enviam mensagens
“notification” quando uma condição de erro é
detectada
Após o envio da mensagem “notification” as
sessões BGP e a conexão TCP são
encerradas
Mensagem “notification” consiste de
• Cabeçalho BGP
• Código de erro
• Subcódigo
• Dados que descrevem o erro
22Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 22Tutorial BGP - GTER
Mensagens “notification”
Códigos de erro
1 – Message header error
2 – Open message error
3 – Update message error
4 – Hold timer expired
5 – Finite state machine error
6 – Cease
23Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 23Tutorial BGP - GTER
Estados de sessão BGP
3-Active 2-Connect
4-OpenSent
5-OpenConfirm
1-Idle
6-Established
OPEN
OPEN
KEEPALIVE
KEEPALIVE
UPDATE
NOTIFICATION
Waiting for
a Start Event
Waiting for
TCP Connection
Trying to
acquire a peer
Waiting for an
OPEN message
from a peer
Waiting for a
KEEPALIVE or
NOTIFICATION
from a peer
Neighbor negotiation
is complete
KEEPALIVE
NOTIFICATION
NOTIFICATION
A Stop event
24Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 24Tutorial BGP - GTER
Show BGP Neighbor
user@host> show bgp neighbor
Peer: 11.1.1.2+179 AS 29 Local: 11.1.1.1+1048 AS 29
Type: Internal State: Established Flags: <>
Last State: OpenConfirm Last Event: RecvKeepAlive
Last Error: None
Options: <Preference HoldTime>
Holdtime: 90 Preference: 170
Number of flaps: 1
Error: "Cease" Sent: 1 Recv: 0
Peer ID: 11.1.1.2 Local ID: 0.0.0.0 Active Holdtime: 90
NLRI advertised by peer: unicast
NLRI for this session: unicast
Group Bit: 0 Send state: in sync
Table inet.0
Active Prefixes: 0
Received Prefixes: 0
Suppressed due to damping: 0
Table inet.2
Active Prefixes: 0
Received Prefixes: 0
Suppressed due to damping: 0
Last traffic (seconds): Received 25 Sent 21 Checked 21
Input messages: Total 4143 Updates 0 Octets 78717
Output messages: Total 4156 Updates 10 Octets 79303
Output Queue[0]: 0
Output Queue[1]: 0
25Tutorial BGP - GTER
Atributos
26Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 26Tutorial BGP - GTER
Atributos BGP
AS-path
BGP nexthop
Local-preference
MED
Origin
Diferenças entre iBGP e eBGP
27Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 27Tutorial BGP - GTER
AS-Path
Sequência de ASs que a rota atravessou
Usado para detecção de loop
Aplicação de políticas
AS 9999
11.1.0.0/16
AS 8888
11.2.0.0/16
AS 7777
11.3.0.0/16
AS 6666
11.4.0.0/16
Prefixo AS-Path
11.1.0.0/16 7777 8888 9999
11.2.0.0/16 7777 8888
11.3.0.0/16 7777
11.4.0.0/16 I
28Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 28Tutorial BGP - GTER
Next-hop
eBGP – endereço do neighbor externo
iBGP – Next-hop do eBGP
BGP speaker deve conhecer caminho para o
next-hop
AS 9999
AS 8888
11.2.0.0/16
AS 7777
11.3.0.0/16
Prefixo Next-hop
11.2.0.0/16 11.2.1.1
11.3.0.0/16 11.2.1.1
11.2.1.1
11.2.1.2
29Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 29Tutorial BGP - GTER
Resolvendo Next-hops BGP
2 métodos comuns
Nexthop self
• Ajusta endereço de BGP Nexthop quando anuncia
para peers internos
Passive interface
• Adiciona subnet de enlace externo à base de
dados do IGP
• Permite roteador peer ser “pingado” a partir de
uma rede interna
30Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 30Tutorial BGP - GTER
Next-hop Self
Roteador eBGP modifica o next-hop da rota
aprendida para o endereço da loopback
Roteadores iBGP devem conhecer loopbacks via
IGP
AS 9999
AS 8888
11.2.0.0/16
AS 7777
11.3.0.0/16
Prefixo Next-hop
11.2.0.0/16 11.2.1.1
11.3.0.0/16 11.2.1.1
11.2.1.1
11.2.1.2
loopback
11.3.1.1
Prefixo Next-hop
11.2.0.0/16 11.3.1.1
11.3.0.0/16 11.3.1.1
Política Next-Hop Self
OSPF
31Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 31Tutorial BGP - GTER
Passive interface
Estende o roteamento IGP até as interfaces
externas
Funciona apenas quando peers utilizam IP das
interfaces
AS 8888
11.2.0.0/16
AS 7777
11.3.0.0/16
11.2.1.1
11.2.1.2
Prefixo Next-hop
11.2.0.0/16 11.2.1.1
11.3.0.0/16 11.2.1.1
Insere interface
“passive”no
roteamento IGP
AS 9999
OSPF
32Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 32Tutorial BGP - GTER
Next-hop em iBGP
Geralmente next-hop é loopback do roteador iBGP
Roteamento recursivo
IGP deve informar sobre loopbacks
Prefixo Next-hop
11.2.100.0/24 11.2.2.2
11.2.101.0/24 11.2.2.1
Loopback
11.2.2.2
Loopback
11.2.2.1
AS 8888
11.2.100.0/24
11.2.101.0/24
33Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 33Tutorial BGP - GTER
Local Preference
Determina melhor caminho para tráfego saínte
Caminho com maior local-preference vence
Local-preference default 100 (JUNOS)
AS 9999
11.1.0.0/16
AS 8888
AS 7777
AS 6666
Prefixo Local Pref
11.1.0.0/16 100
*11.1.0.0/16 120
100
120
34Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 34Tutorial BGP - GTER
Multi-Exit Descriminator (MED)
Inter-AS não transitivo
Determina melhor caminho para tráfego entrante
Seu uso deve ser acordado entre ASs
AS 9999
11.1.0.0/16
AS 8888
500
600
Prefixo MED
*11.1.0.0/16 500
11.1.0.0/16 600
35Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 35Tutorial BGP - GTER
Origin
Informa a origem do prefixo
Influencia seleção do melhor caminho
Três tipos:
IGP – configurada de forma explícita no BGP
(agregado, policy)
EGP – gerada pelo EGP
Incomplete – redistribuida por outro protocolo
de roteamento
36Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 36Tutorial BGP - GTER
Exterior BGP (eBGP)
Utilizado para passar rotas entre ASs
Características
BGP nexthop é modificado
AS-Path é adicionado
Peer geralmente entre endereços de
interfaces físicas
AS-Path é utilizado como mecanismo de
prevenção de loop de roteamento
37Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 37Tutorial BGP - GTER
Exterior BGP
eBGP Peering
AS 9999AS 8888 AS 7777
38Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 38Tutorial BGP - GTER
Interior BGP (iBGP)
iBGP é utilizado no interior de um AS
Next-hop BGP não é modificado
AS-Path não é adicionado
É implementado tipicamente com peers
totalmente interconectados (full mesh)
Análise de AS-PATH não é aplicável para
prevenir loops internos
Roteador não pode repassar via iBGP rotas
aprendidas através de outros peers iBGP
39Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 39Tutorial BGP - GTER
Interior BGP
iBGP Peering
AS 9999
AS 7777AS 8888
40Tutorial BGP - GTER
Política de Roteamento BGP
“Routing Policy”
41Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 41Tutorial BGP - GTER
JUNOS Route Preference
Nexthop é alcançável?
-1 = Not reachable
Preferência menor
0 = directly connected
5 = static routes
7 = RSVP
9 = LDP
10 = OSPF internal
15 = ISIS L1 internal
18 = ISIS L2 internal
100 = RIP
130 = Aggregate or generated
150 = OSPF external
160 = ISIS L1 external
165 = ISIS L2 external
170 = BGP
42Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 42Tutorial BGP - GTER
Seleção de rotas BGP - JUNOS
Menor “route preference”
Maior “local preference”
AS-path mais curto
Menor “Origin” (IGP < EGP < incomplete)
Menor MED
Externa sobre “confederation” sobre interna
Menor métrica do IGP
Menor “cluster list”
Menor router-id
43Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 43Tutorial BGP - GTER
Anúncio de rotas BGP - JUNOS
Regras de anúncio BGP default
Apenas rotas ativas
• Todas as rotas aprendidas via BGP (exceto regra iBGP)
• Anúncio de rotas inativas é possível via configuração
É necessário configuração explícita para:
• Anunciar rotas estáticas
• Anunciar rotas agregadas
• Anunciar rota default
• Redistribuir rotas no BGP
44Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 44Tutorial BGP - GTER
Routing Policy
Controla as transferências de informações de
roteamento entre a tabela de roteamento e cada
protocolo de roteamento
Informação de roteamento entrante pode ser
ignorada ou modificada
Informação de roteamento saínte pode ser
suprimida ou modificada
45Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 45Tutorial BGP - GTER
Quando aplicar uma política
Não se quer importar para a tabela de
roteamento todas as rotas aprendidas
Não se quer anunciar todas as rotas da tabela de
roteamento para os roteadores vizinhos
Se deseja que um protocolo receba rotas a partir
de outro protocolo
Se deseja modificar informações associadas a
uma rota
46Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 46Tutorial BGP - GTER
Routing Policy
Políticas de entrada afetam o que vai para a
tabela de roteamento
Políticas de saída manipulam o conteúdo da
tabela de roteamento que é exportado
47Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 47Tutorial BGP - GTER
Sintaxe de uma política no JUNOS
Sintaxe básica
policy-options {
policy-statement nome-politica {
term nome-termo {
from {
condicao-de-match;
}
to {
condicao-de-match;
}
then {
acao;
}
}
acao-final;
}
}
!!
48Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 48Tutorial BGP - GTER
Visualização de rotas BGP
Rotas recebidas de um peer antes de aplicar uma policy
Rotas anunciadas para um peer específico
user@host> show route advertising-protocol bgp 11.1.1.2
inet.0: 10 destinations, 10 routes (8 active, 0 holddown, 2 hidden)
Prefix Nexthop MED Lclpref AS path
10.0.0.0/8 Self 100 I
172.16.0.0/12 Self 100 I
user@host> show route receive-protocol bgp 11.1.1.1
inet.0: 6 destinations, 6 routes (5 active, 0 holddown, 1 hidden)
Prefix Nexthop MED Lclpref AS path
10.0.0.0/8 11.1.1.1 100 I
172.16.0.0/12 11.1.1.1 100 I
49Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 49Tutorial BGP - GTER
Políticas muito utilizadas
Filtro de rotas “marcianas”
Filtros de tamanho de prefíxo
Anuncia agregado e suprime específicas
Preferência por rotas de clientes sobre qualquer
outra
Preferência por rotas de peers sobre rotas de trânsito
Marcação de rotas com communities
50Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 50Tutorial BGP - GTER
Communities
Marcação dada a um grupo de prefixos que
partilham uma propriedade em comum
Decisões de roteamento podem estar baseadas
na community da rota
Facilita e simplifica o controle das informações de
rotas
Deveria ser marcada pelo roteador de entrada
RFC 1997 and 1998
51Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 51Tutorial BGP - GTER
Well Known Communities
NO_EXPORT (0xFFFFFF01)
Não anuncia para outros peers eBGP
NO_ADVERTISE (0xFFFFFF02)
Não anuncia para nenhum peer
NO_EXPORT_SUBCONFED (0xFFFFFF03)
Não anuncia para outros ASs, incluindo
membros de uma confederation
52Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 52Tutorial BGP - GTER
Exemplos de Communities
AS#:120
Rotas de clientes
Marca “local preference” para 120
AS#:110
Rotas backup de clientes
AS#:90
Rotas de “Private peer”
AS#:80
Rotas de trânsito
AS#:70
Rotas de “Public peer”
53Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 53Tutorial BGP - GTER
Exemplo de configuração
policy-statement TRANSITO-IN {
term REJEITA-TAM-PREF {
from policy TAM-PREF;
then reject;
}
term REJEITA-MARCIANAS {
from policy MARCIANAS;
then reject;
}
term PERMITE-RESTO {
then {
community set TRANSIT-ROUTES;
local-preference 80;
accept;
}
}
}
community TRANSIT-ROUTES members 6666:70;
Inspeção de rotas de entrada
54Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 54Tutorial BGP - GTER
Agregação de rotas
Sumarização de um grupo de rotas com prefixo em
comum
Reduz a tabela de rotas, anúncios de roteamento e
instabilidade
routing-options {
aggregate {
route 8.8.0.0/16; {
passive;
}
}
55Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 55Tutorial BGP - GTER
Agregação de rotas
policy-options {
policy-statement SUPPRESS-SPECIFICS {
from route-filter 8.8/16 longer reject;
}
Supressão explícita das rotas contribuíntes
Atributo “atomic-aggregate”
Indica perda de informação devido à agregação
Atributo “aggregator”
Especifica o nº do AS e o router-id do roteador
agregador
RFC 2519
56Tutorial BGP - GTER
Escalando o iBGP Full Mesh
57Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 57Tutorial BGP - GTER
Escalando o iBGP Full Mesh
Problema N2
1 roteador novo deve possuir peer com todos
os outros. Os outros devem adicionar peer
com o roteador novo
Adiciona sobrecarga de processamento TCP
Aumenta tamanho das tabelas de roteamento
2 métodos para escalar
Route Reflection (RFC 2796)
Confederations (RFC 1965)
58Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 58Tutorial BGP - GTER
Route Reflection
Permite um peer iBGP anunciar uma rota
aprendida via iBGP para outro peer iBGP
Reduz iBGP full mesh
RR apenas reflete o melhor caminho
RR não modifica os atributos BGP
59Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 59Tutorial BGP - GTER
AS 9999AS 8888 AS 7777
Route Reflection
iBGP Full Mesh Peering
RR Peering
60Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 60Tutorial BGP - GTER
Route Reflection
Isso não cria a possibilidade de loops?
Novos atributos
Cluster-id
• Identifica o “route reflection cluster”
• Adicionado à rota pelo RR
Cluster-list
• Sequência de cluster-ids que um update
atravessou
• Similar ao AS-path list
Originator-id
• Identifica o roteador que originou a rota no AS
• Adicionado à rota pelo RR
61Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 61Tutorial BGP - GTER
Exemplo de Configuração
routing-options {
autonomous-system 6666;
}
protocols {
bgp {
damping;
group ibgp-mesh {
export [ nexthopself send-connected ];
local-address 8.8.254.253;
peer-as 6666;
neighbor 1.2.3.4;
neighbor 2.3.4.5;
neighbor 3.4.5.6;
}
group rr-cluster {
cluster 1.1.1.1;
export [ nexthopself send-connected ];
local-address 8.8.254.253;
peer-as 6666;
neighbor 4.5.6.7;
62Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 62Tutorial BGP - GTER
RJO
CTAPAE
SDR
Full iBGP Mesh
Route Reflection
SPO
BSA
RR
Cluster
1.1.1.1
RR
Cluster
2.2.2.2
eBGP Peering
AS 7777
Route Reflection
63Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 63Tutorial BGP - GTER
Route Reflection redundante
É possível fazer full-mesh de clientes de um RR
No-client-reflect
• RR não reflete rotas intra-cluster
64Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 64Tutorial BGP - GTER
Confederations
Outro método de reduzir o iBGP full mesh
Quebra o AS em múltiplos sub-ASs
Sub-ASs
Podem utilizar número de AS privados
iBGP full mesh dentro do sub-AS ou RR
AS é visto externamente como único AS
Sub-ASs não contabilizados como AS-path hops
65Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 65Tutorial BGP - GTER
RJO
SDR
Full iBGP Mesh
Route Reflection
eBGP Peering
Confederations
Confederation 6666
Central Sub-AS 65100
(ISIS)
SPO POP
Sub-AS
65102
(OSPF)
PAE POP
Sub-AS
65101 (ISIS)
Peer ISP
Peer ISP
Peer ISP
Peer ISP Clientes
Clientes
66Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 66Tutorial BGP - GTER
Confederation BGP
cBGP (ou e-iBGP)
É eBGP ou iBGP?
BGP nexthop
AS-path
Local-preference
67Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 67Tutorial BGP - GTER
Confederations/RRs
Vantagens de confederations sobre RR?
Anexação de outro ISP
Pode facilitar a migração/integração de redes
adquiridas
Pode rodar múltiplos IGPs
Desvantagens
Migração abrupta de uma rede iBGP full mesh
Aparenta ser um pouco mais complicado
Roteamento sub-ótimo dentro da confederation
68Tutorial BGP - GTER
Novas Funcionalidades no BGP v4
69Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 69Tutorial BGP - GTER
Negociação de Capacidades
Permite negociação de capacidades entre peers
BGP
RFC 1771
Se a mensagem de Open contém
funcionalidade não suportada, envia
Notification com subcode 4 “Unsupported
Optional Parameter” e termina sessão
Não facilita a introdução de novas
funcionalidade no BGP
RFC 2842
70Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 70Tutorial BGP - GTER
Communities Estendidas
Duas melhorias importantes
Faixa estendida (4 para 8 octetos)
Adiciona campo TYPE (2 octetos)
Route target community
Identifica o destino da rota
Route origin community
Identifica a origem da rota
Utilizada para controlar a distribuição de MPLS
VPNs
draft-ramachandra-bgp-ext-communities-04.txt
71Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 71Tutorial BGP - GTER
Communities Estendidas
[edit]
policy-options {
community test-a members [target:9999:70];
community test-b members [target:1.1.1.1:90];
community test-c members [origin:6666:110];
}
72Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 72Tutorial BGP - GTER
Capacidade de Route Refresh
Forma dinâmica de requisitar o re-anúncio de
rotas de um peer
JUNOS guarda cópias inalteradas de todas as
rotas na RIB-In
draft-ietf-idr-bgp-route-refresh-01.txt
user@host> clear bgp neighbor 11.1.1.1 soft-inbound
user@host> show route receive-protocol bgp 11.1.1.1
73Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 73Tutorial BGP - GTER
MBGP
Extensão que permite o BGP carregar
informação de múltiplas camadas de rede e
famílias de endereços
Utilizado para Multicast
Utilizado pelo MPLS VPNs para carregar labels
MP_REACH_NLRI
• VPN-IPv4 + Label
user@host# set nlri [ multicast | unicast | any ]
74Tutorial BGP - GTER
Route Damping
75Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 75Tutorial BGP - GTER
Route Damping
Reduz a carga de “update” para rotas bem
comportadas
Geralmente aplicado para rotas eBGP
Pode ser usado com confederation
Configurado a partir de um conjunto de
parâmetros que inspecionam a atividade das
rotas mal comportadas
Deve-se habilitar o BGP damping
Quantos ISPs ainda utilizam damping?
RFC 2439
76Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 76Tutorial BGP - GTER
AS 8888
AS 7777
Route Flap Damping
Rotas instáveis
anunciadas e
removidas pelo
AS 7777
AS 8888 aguarda
as rotas
estabilizarem
para aceitá-las
77Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 77Tutorial BGP - GTER
Damping—Figura de Mérito
Nova rota recebe figura de mérito 0
Figura de mérito incrementa a cada incidente
Withdrawn route–1000
Mudança de atributo–500
Rota é suprimida quando a figura de mérito
excede o limiar de supressão
Limiar de supressão default é 3000
Rota é reutilizada quando a figura de mérito cai
abaixo do limiar de reutilização
Limiar de reutilização default é 750
78Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 78Tutorial BGP - GTER
Damping—Figura de Mérito
Decaimento exponencial
Reduz a figura de mérito com o tempo
Half-life default de 15 min
Limite máximo de tempo de supressão
Default é 60 min
Figura de mérito máxima
Limita incremento quando o teto é atingido
Determinado por fórmula
Não configurável de forma explícita
79Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 79Tutorial BGP - GTER
Route Damping
Figure
of Merit
Time
Suppressed
Reused
750
3000
1000
2000
Flap 1
Flap 2
Flap 3
Flap 4
Flap 5
Half-life Half-life
80Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 80Tutorial BGP - GTER
Damping—Configuração
Definição de parâmetros de damping é
semelhante à definição de community
policy-options {
damping name {
half-life minutes;
max-suppress minutes;
reuse number;
suppress number;
}
}
81Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 81Tutorial BGP - GTER
Damping—Example
policy-options {
policy-statement damp {
from {
route-filter 11/8 exact damping high;
route-filter 15/8 exact damping medium;
route-filter 0/0 upto /24 damping none;
}
then accept;
}
damping high {
half-life 15;
suppress 3000;
reuse 2500;
max-suppress 50;
}
damping medium {
half-life 3;
max-suppress 4;
}
damping none {
disable;
}
}
82Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 82Tutorial BGP - GTER
Show BGP Summary
Informações básicas sobre neighbors BGP
user@host> show bgp summary
Groups: 12 Peers: 26 Unestablished peers: 2
Peer AS InPkt OutPkt OutQ Flaps Last Up/Dn State|#Act/Recv/Damp
131.103.0.2 45 1225 55263 50511 2 18:22:14 47769/50591/67
192.168.1.1 33 911 0 0 0 18:22:27 Active
192.168.1.97 23 10458 2201 41043 0 18:22:03 0/0/0
192.168.1.100 432 10458 163 17643 0 17:01:18 Active
…
83Tutorial BGP - GTER
Perguntas?
caio@juniper.net
84Tutorial BGP - GTER
Obrigado!

Mais conteúdo relacionado

Mais procurados (20)

Conceitos e configurações do ether channel
Conceitos e configurações do ether channelConceitos e configurações do ether channel
Conceitos e configurações do ether channel
 
Camada de rede parte1
Camada de rede   parte1Camada de rede   parte1
Camada de rede parte1
 
JornadasFCCN2015-LigacaoRCTScomPeeringBGPv3
JornadasFCCN2015-LigacaoRCTScomPeeringBGPv3JornadasFCCN2015-LigacaoRCTScomPeeringBGPv3
JornadasFCCN2015-LigacaoRCTScomPeeringBGPv3
 
Endereçamento IPv6
Endereçamento IPv6Endereçamento IPv6
Endereçamento IPv6
 
Roteamento Bgp
Roteamento BgpRoteamento Bgp
Roteamento Bgp
 
R&C 0501 07 1
R&C 0501 07 1R&C 0501 07 1
R&C 0501 07 1
 
Ccna final 4_atualizado
Ccna final 4_atualizadoCcna final 4_atualizado
Ccna final 4_atualizado
 
Roteamento de pacotes
Roteamento de pacotesRoteamento de pacotes
Roteamento de pacotes
 
Conteúdo de IPV6
Conteúdo de IPV6Conteúdo de IPV6
Conteúdo de IPV6
 
Rotas estáticas IPv6
Rotas estáticas IPv6Rotas estáticas IPv6
Rotas estáticas IPv6
 
Cisco Call Manager - Ambiente e Topologias
Cisco Call Manager - Ambiente e TopologiasCisco Call Manager - Ambiente e Topologias
Cisco Call Manager - Ambiente e Topologias
 
Ospf multiárea para o CCNA
Ospf multiárea para o CCNAOspf multiárea para o CCNA
Ospf multiárea para o CCNA
 
Eigrp IPv6
Eigrp IPv6Eigrp IPv6
Eigrp IPv6
 
Redes Avançadas - 2.IPv6
Redes Avançadas - 2.IPv6Redes Avançadas - 2.IPv6
Redes Avançadas - 2.IPv6
 
Camada rede
Camada redeCamada rede
Camada rede
 
Implementação de Redes com Alta Disponibilidade
Implementação de Redes com Alta DisponibilidadeImplementação de Redes com Alta Disponibilidade
Implementação de Redes com Alta Disponibilidade
 
Ospfv3
Ospfv3Ospfv3
Ospfv3
 
Etherchannel
EtherchannelEtherchannel
Etherchannel
 
(10) network
(10) network(10) network
(10) network
 
Roteamento
RoteamentoRoteamento
Roteamento
 

Destaque

Construir una matriz de datos en pasw statistics
Construir una matriz de datos en pasw statisticsConstruir una matriz de datos en pasw statistics
Construir una matriz de datos en pasw statisticsVirginiaRoldan9
 
оспанова мадина+мир и гармония+клиенты
оспанова мадина+мир и гармония+клиентыоспанова мадина+мир и гармония+клиенты
оспанова мадина+мир и гармония+клиентыprogrammist
 
Lesson planamberlincolnofficemix
Lesson planamberlincolnofficemixLesson planamberlincolnofficemix
Lesson planamberlincolnofficemixAmber Erin LaJaunie
 
1.4 Backing Storage Media and Devices
1.4 Backing Storage Media and Devices1.4 Backing Storage Media and Devices
1.4 Backing Storage Media and DevicesHaa'Meem Mohiyuddin
 
5 things you should be doing with your content strategy but aren't
5 things you should be doing with your content strategy but aren't5 things you should be doing with your content strategy but aren't
5 things you should be doing with your content strategy but aren'tGina Om
 
Fairfax County Parkway Study Meeting, June 2016
Fairfax County Parkway Study Meeting, June 2016Fairfax County Parkway Study Meeting, June 2016
Fairfax County Parkway Study Meeting, June 2016VDOT Northern Virginia
 
Elaboración tablas de frecuencia en pasw
Elaboración tablas de frecuencia en paswElaboración tablas de frecuencia en pasw
Elaboración tablas de frecuencia en paswVirginiaRoldan9
 

Destaque (19)

Portafolio electrónico
Portafolio electrónicoPortafolio electrónico
Portafolio electrónico
 
Verbal phrases
Verbal phrasesVerbal phrases
Verbal phrases
 
Construir una matriz de datos en pasw statistics
Construir una matriz de datos en pasw statisticsConstruir una matriz de datos en pasw statistics
Construir una matriz de datos en pasw statistics
 
Desparasitantes Internos
Desparasitantes InternosDesparasitantes Internos
Desparasitantes Internos
 
оспанова мадина+мир и гармония+клиенты
оспанова мадина+мир и гармония+клиентыоспанова мадина+мир и гармония+клиенты
оспанова мадина+мир и гармония+клиенты
 
1.3 Control Output Devices
1.3 Control Output Devices1.3 Control Output Devices
1.3 Control Output Devices
 
Project SoliType
Project SoliTypeProject SoliType
Project SoliType
 
Rosmarysbolivartarea4 iv
Rosmarysbolivartarea4 ivRosmarysbolivartarea4 iv
Rosmarysbolivartarea4 iv
 
Lesson planamberlincolnofficemix
Lesson planamberlincolnofficemixLesson planamberlincolnofficemix
Lesson planamberlincolnofficemix
 
1.4 Backing Storage Media and Devices
1.4 Backing Storage Media and Devices1.4 Backing Storage Media and Devices
1.4 Backing Storage Media and Devices
 
5 things you should be doing with your content strategy but aren't
5 things you should be doing with your content strategy but aren't5 things you should be doing with your content strategy but aren't
5 things you should be doing with your content strategy but aren't
 
Cr15 A Directors v1.0
Cr15 A Directors v1.0Cr15 A Directors v1.0
Cr15 A Directors v1.0
 
Fairfax County Parkway Study Meeting, June 2016
Fairfax County Parkway Study Meeting, June 2016Fairfax County Parkway Study Meeting, June 2016
Fairfax County Parkway Study Meeting, June 2016
 
Elaboración tablas de frecuencia en pasw
Elaboración tablas de frecuencia en paswElaboración tablas de frecuencia en pasw
Elaboración tablas de frecuencia en pasw
 
Dokument 14
Dokument 14Dokument 14
Dokument 14
 
Sources of data
Sources of dataSources of data
Sources of data
 
Medium (Entre Twitter y WordPress)
Medium (Entre Twitter y WordPress)Medium (Entre Twitter y WordPress)
Medium (Entre Twitter y WordPress)
 
Desparasitantes internos
Desparasitantes internosDesparasitantes internos
Desparasitantes internos
 
Seminario 9
Seminario 9Seminario 9
Seminario 9
 

Semelhante a Tutorial BGP - Atributos e Nexthop

Semelhante a Tutorial BGP - Atributos e Nexthop (20)

Introdução ao BGP
Introdução ao BGPIntrodução ao BGP
Introdução ao BGP
 
R&C 0502 07 2
R&C 0502 07 2R&C 0502 07 2
R&C 0502 07 2
 
R&C 0502 07 2
R&C 0502 07 2R&C 0502 07 2
R&C 0502 07 2
 
Cap04b
Cap04bCap04b
Cap04b
 
Border Gateway Protocol - BGP - Apresentação
Border Gateway Protocol - BGP - ApresentaçãoBorder Gateway Protocol - BGP - Apresentação
Border Gateway Protocol - BGP - Apresentação
 
R&c 05 14_2 - Protocolo IP (Parte 2)
R&c 05 14_2 - Protocolo IP (Parte 2)R&c 05 14_2 - Protocolo IP (Parte 2)
R&c 05 14_2 - Protocolo IP (Parte 2)
 
BGP.ppt
BGP.pptBGP.ppt
BGP.ppt
 
Roteamento
RoteamentoRoteamento
Roteamento
 
Apresentação de Protocolos de Roteamento IP
Apresentação de Protocolos de Roteamento IPApresentação de Protocolos de Roteamento IP
Apresentação de Protocolos de Roteamento IP
 
02-Flowspec_GTER29
02-Flowspec_GTER2902-Flowspec_GTER29
02-Flowspec_GTER29
 
IP Internet Balanceamento e Redundância
IP Internet Balanceamento e RedundânciaIP Internet Balanceamento e Redundância
IP Internet Balanceamento e Redundância
 
Osp fv3
Osp fv3Osp fv3
Osp fv3
 
Redes de computadores II - 2.Servicos de Camada de Rede IP
Redes de computadores II - 2.Servicos de Camada de Rede IPRedes de computadores II - 2.Servicos de Camada de Rede IP
Redes de computadores II - 2.Servicos de Camada de Rede IP
 
Redes I -7.Introdução ao TCP/IP
Redes I -7.Introdução ao TCP/IPRedes I -7.Introdução ao TCP/IP
Redes I -7.Introdução ao TCP/IP
 
Redes De Computadores Internet
Redes De Computadores   InternetRedes De Computadores   Internet
Redes De Computadores Internet
 
Redes de computadores II - 1.Arquitetura TCP/IP
Redes de computadores II - 1.Arquitetura TCP/IPRedes de computadores II - 1.Arquitetura TCP/IP
Redes de computadores II - 1.Arquitetura TCP/IP
 
R&c 05 14_1 - Protocolo IP (Parte 1)
R&c 05 14_1 - Protocolo IP (Parte 1)R&c 05 14_1 - Protocolo IP (Parte 1)
R&c 05 14_1 - Protocolo IP (Parte 1)
 
Prova final 1
Prova final 1Prova final 1
Prova final 1
 
Camada de Rede
Camada de RedeCamada de Rede
Camada de Rede
 
Roteamento Intra-SA e Inter-SA
Roteamento Intra-SA e Inter-SARoteamento Intra-SA e Inter-SA
Roteamento Intra-SA e Inter-SA
 

Tutorial BGP - Atributos e Nexthop

  • 1. 1Tutorial BGP - GTER BGP v4 – Tutorial 17º GTER Caio Klein
  • 2. 2Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 2Tutorial BGP - GTER Agenda Introdução ao BGP v4 Protocolo BGP e Atributos iBGP e eBGP Políticas de Roteamento BGP Intervalo Escalando o iBGP Full Mesh Route Reflection Confederations Novas facilidades do BGP Route Damping
  • 3. 3Tutorial BGP - GTER Introdução ao BGP v4
  • 4. 4Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 4Tutorial BGP - GTER BGP – Border Gateway Protocol v4 Algumas referências do BGP v4 RFCs 1771 e 1772 - BGP v4 RFCs 1965 - Autonomous System Confederations RFC 1966 - Route Reflection RFC 1997 - Communities RFC 2270 - Dedicated AS’s RFC 2283 - MBGP RFC 2385 - BGP MD5 Authentication RFC 2439 - Route Damping RFC 2842 - Capabilities Negotiation
  • 5. 5Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 5Tutorial BGP - GTER Autonomous System (AS) O que é um AS? Grupo de roteadores • Administrados com uma política comum de roteamento • Operam sob a mesma administração técnica • Percebidos externamente como um único domínio de roteamento Inteiro de 16 bits (1-65535) 64512-65535 AS - Privados
  • 6. 6Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 6Tutorial BGP - GTER Internet - Coleção de ASs Técnicas de IGP não são aplicáveis neste ambiente. É necessário maior escalabilidade Protocolo deve refletir acordos entre ASs - Flexibilidade AS 9999 AS 8888 AS 7777
  • 7. 7Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 7Tutorial BGP - GTER O que é o BGP? BGP é um protocolo de roteamento do tipo inter- domínio que transmite informações de prefixos BGP é um protocolo do tipo “path vector” Similar ao “distance vector” BGP percebe a Internet como uma coleção de autonomous systems (AS) BGP suporta CIDR Roteadores BGP trocam informações de roteamento entre “peers”
  • 8. 8Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 8Tutorial BGP - GTER Fundamentos do BGP Rotas consistem de Destino – usualmente prefixo IP Informações que descrevem o caminho até o destino • Atributos Peers BGP anunciam NLRI entre si em mensagens do tipo “update” O BGP compara o AS path e outros atributos para selecionar o melhor caminho Rotas indisponíveis podem ser anunciadas Rotas não alcançáveis são removidas (withdrawn)
  • 9. 9Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 9Tutorial BGP - GTER Analisando rotas BGP Olhando entrada específica na tabela de roteamento user@host> show route 172.16.0.0 extensive inet.0: 6 destinations, 6 routes (5 active, 0 holddown, 1 hidden) + = Active Route, - = Last Active, * = Both 172.16.0.0/12 (1 entry, 1 announced) TSI: BGP_Sync_Any dest 172.16.0.0/12 MED 0 *BGP Preference: 170/-101 Nexthop: 11.1.1.1 via fe-0/0/0.0, selected State: <Active Int Ext> Local AS: 29 Peer AS: 29 Age: 1d 9:46:54 Metric2: 0 Task: BGP_29.11.1.1.1+1048 Announcement bits (2): 0-KRT 2-BGP_Sync_Any AS path: 9999 8888 7777 I BGP next hop: 11.1.1.1 Localpref: 100 Router ID: 172.18.1.1
  • 10. 10Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 10Tutorial BGP - GTER Conexões BGP BGP utiliza conexões TCP TCP port 179 Serviços TCP • Fragmentation, Acknowledgments, Checksums, Sequencing e Flow Control Sem descoberta automática de vizinho Atualizações do BGP são incrementais Sem “refreshes” regulares Exceto no estabelecimento da sessão quando o volume de roteamento pode ser grande
  • 11. 11Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 11Tutorial BGP - GTER BGP Peering Sessões BGP são estabelecidas entre peers BGP Speakers Dois tipos de sessões de peering E-BGP (externo) peers AS's diferentes I-BGP (interno) peers dentro do mesmo AS Ainda é necessário o interior gateway protocol (IGPs) IGP conecta os BGP speakers dentro do AS IGP anuncia rotas internas
  • 12. 12Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 12Tutorial BGP - GTER BGP Peering eBGP Peering AS 9999AS 8888 AS 7777 iBGP Peering ISIS OSPFISIS
  • 13. 13Tutorial BGP - GTER Mensagens do BGPv4
  • 14. 14Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 14Tutorial BGP - GTER Mensagens do Protocolo BGP Quatro tipos de mensagem Open Update Notification Keepalive Utilizam um cabeçalho em comum
  • 15. 15Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 15Tutorial BGP - GTER Cabeçalho Comum 19 bytes de comprimento Utilizado para autenticação Marker Field (16 bytes) Length Field (2 bytes) Type Field (1 byte)
  • 16. 16Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 16Tutorial BGP - GTER Mensagem Open Após uma conexão TCP ser estabelecida, os peers BGP trocam mensagens “open”para criar uma conexão BGP Sobre uma conexão BGP os peers trocam outras mensagens BGP e dados como informações de roteamento
  • 17. 17Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 17Tutorial BGP - GTER Mensagem Open Marker Field Length Field Type Field Version (1 byte) My Autonomous System Hold Time BGP Identifier Opt. Parameters Length Optional Parameters (Variable Length)
  • 18. 18Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 18Tutorial BGP - GTER Mensagem Update Cada “update” contem um anúncio de caminho com seus atributos e destinos Muitos destinos (prefixos) podem compartilhar o mesmo caminho Sistemas BGP utilizam essa informação para construir um gráfico descrevendo as relações entre todos os ASs
  • 19. 19Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 19Tutorial BGP - GTER Mensagem Update Mensagens que possuem os mesmos atributos devem ser agrupadas num mesmo update Withdrawn Routes Length (2 octets) Header Path Attributes (Variable Length) Withdrawn Routes (Variable) Total Path Attributes (2 octets) ~ ~ Network Layer Reachability information (Variable Length)
  • 20. 20Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 20Tutorial BGP - GTER Mensagem Keepalive Sistemas BGP trocam mensagens keepalive para determinar se um link ou peer falhou ou não está mais disponível Mensagens são trocadas frequentemente para o tempo de “hold” não expirar Intervalos de 30s entre keepalives e hold timer de 90s são default (JUNOS) • Hold timer é negociado entre peers Contem apenas o BGP header (19 bytes)
  • 21. 21Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 21Tutorial BGP - GTER Mensagem Notification Sistemas BGP enviam mensagens “notification” quando uma condição de erro é detectada Após o envio da mensagem “notification” as sessões BGP e a conexão TCP são encerradas Mensagem “notification” consiste de • Cabeçalho BGP • Código de erro • Subcódigo • Dados que descrevem o erro
  • 22. 22Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 22Tutorial BGP - GTER Mensagens “notification” Códigos de erro 1 – Message header error 2 – Open message error 3 – Update message error 4 – Hold timer expired 5 – Finite state machine error 6 – Cease
  • 23. 23Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 23Tutorial BGP - GTER Estados de sessão BGP 3-Active 2-Connect 4-OpenSent 5-OpenConfirm 1-Idle 6-Established OPEN OPEN KEEPALIVE KEEPALIVE UPDATE NOTIFICATION Waiting for a Start Event Waiting for TCP Connection Trying to acquire a peer Waiting for an OPEN message from a peer Waiting for a KEEPALIVE or NOTIFICATION from a peer Neighbor negotiation is complete KEEPALIVE NOTIFICATION NOTIFICATION A Stop event
  • 24. 24Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 24Tutorial BGP - GTER Show BGP Neighbor user@host> show bgp neighbor Peer: 11.1.1.2+179 AS 29 Local: 11.1.1.1+1048 AS 29 Type: Internal State: Established Flags: <> Last State: OpenConfirm Last Event: RecvKeepAlive Last Error: None Options: <Preference HoldTime> Holdtime: 90 Preference: 170 Number of flaps: 1 Error: "Cease" Sent: 1 Recv: 0 Peer ID: 11.1.1.2 Local ID: 0.0.0.0 Active Holdtime: 90 NLRI advertised by peer: unicast NLRI for this session: unicast Group Bit: 0 Send state: in sync Table inet.0 Active Prefixes: 0 Received Prefixes: 0 Suppressed due to damping: 0 Table inet.2 Active Prefixes: 0 Received Prefixes: 0 Suppressed due to damping: 0 Last traffic (seconds): Received 25 Sent 21 Checked 21 Input messages: Total 4143 Updates 0 Octets 78717 Output messages: Total 4156 Updates 10 Octets 79303 Output Queue[0]: 0 Output Queue[1]: 0
  • 25. 25Tutorial BGP - GTER Atributos
  • 26. 26Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 26Tutorial BGP - GTER Atributos BGP AS-path BGP nexthop Local-preference MED Origin Diferenças entre iBGP e eBGP
  • 27. 27Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 27Tutorial BGP - GTER AS-Path Sequência de ASs que a rota atravessou Usado para detecção de loop Aplicação de políticas AS 9999 11.1.0.0/16 AS 8888 11.2.0.0/16 AS 7777 11.3.0.0/16 AS 6666 11.4.0.0/16 Prefixo AS-Path 11.1.0.0/16 7777 8888 9999 11.2.0.0/16 7777 8888 11.3.0.0/16 7777 11.4.0.0/16 I
  • 28. 28Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 28Tutorial BGP - GTER Next-hop eBGP – endereço do neighbor externo iBGP – Next-hop do eBGP BGP speaker deve conhecer caminho para o next-hop AS 9999 AS 8888 11.2.0.0/16 AS 7777 11.3.0.0/16 Prefixo Next-hop 11.2.0.0/16 11.2.1.1 11.3.0.0/16 11.2.1.1 11.2.1.1 11.2.1.2
  • 29. 29Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 29Tutorial BGP - GTER Resolvendo Next-hops BGP 2 métodos comuns Nexthop self • Ajusta endereço de BGP Nexthop quando anuncia para peers internos Passive interface • Adiciona subnet de enlace externo à base de dados do IGP • Permite roteador peer ser “pingado” a partir de uma rede interna
  • 30. 30Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 30Tutorial BGP - GTER Next-hop Self Roteador eBGP modifica o next-hop da rota aprendida para o endereço da loopback Roteadores iBGP devem conhecer loopbacks via IGP AS 9999 AS 8888 11.2.0.0/16 AS 7777 11.3.0.0/16 Prefixo Next-hop 11.2.0.0/16 11.2.1.1 11.3.0.0/16 11.2.1.1 11.2.1.1 11.2.1.2 loopback 11.3.1.1 Prefixo Next-hop 11.2.0.0/16 11.3.1.1 11.3.0.0/16 11.3.1.1 Política Next-Hop Self OSPF
  • 31. 31Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 31Tutorial BGP - GTER Passive interface Estende o roteamento IGP até as interfaces externas Funciona apenas quando peers utilizam IP das interfaces AS 8888 11.2.0.0/16 AS 7777 11.3.0.0/16 11.2.1.1 11.2.1.2 Prefixo Next-hop 11.2.0.0/16 11.2.1.1 11.3.0.0/16 11.2.1.1 Insere interface “passive”no roteamento IGP AS 9999 OSPF
  • 32. 32Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 32Tutorial BGP - GTER Next-hop em iBGP Geralmente next-hop é loopback do roteador iBGP Roteamento recursivo IGP deve informar sobre loopbacks Prefixo Next-hop 11.2.100.0/24 11.2.2.2 11.2.101.0/24 11.2.2.1 Loopback 11.2.2.2 Loopback 11.2.2.1 AS 8888 11.2.100.0/24 11.2.101.0/24
  • 33. 33Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 33Tutorial BGP - GTER Local Preference Determina melhor caminho para tráfego saínte Caminho com maior local-preference vence Local-preference default 100 (JUNOS) AS 9999 11.1.0.0/16 AS 8888 AS 7777 AS 6666 Prefixo Local Pref 11.1.0.0/16 100 *11.1.0.0/16 120 100 120
  • 34. 34Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 34Tutorial BGP - GTER Multi-Exit Descriminator (MED) Inter-AS não transitivo Determina melhor caminho para tráfego entrante Seu uso deve ser acordado entre ASs AS 9999 11.1.0.0/16 AS 8888 500 600 Prefixo MED *11.1.0.0/16 500 11.1.0.0/16 600
  • 35. 35Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 35Tutorial BGP - GTER Origin Informa a origem do prefixo Influencia seleção do melhor caminho Três tipos: IGP – configurada de forma explícita no BGP (agregado, policy) EGP – gerada pelo EGP Incomplete – redistribuida por outro protocolo de roteamento
  • 36. 36Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 36Tutorial BGP - GTER Exterior BGP (eBGP) Utilizado para passar rotas entre ASs Características BGP nexthop é modificado AS-Path é adicionado Peer geralmente entre endereços de interfaces físicas AS-Path é utilizado como mecanismo de prevenção de loop de roteamento
  • 37. 37Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 37Tutorial BGP - GTER Exterior BGP eBGP Peering AS 9999AS 8888 AS 7777
  • 38. 38Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 38Tutorial BGP - GTER Interior BGP (iBGP) iBGP é utilizado no interior de um AS Next-hop BGP não é modificado AS-Path não é adicionado É implementado tipicamente com peers totalmente interconectados (full mesh) Análise de AS-PATH não é aplicável para prevenir loops internos Roteador não pode repassar via iBGP rotas aprendidas através de outros peers iBGP
  • 39. 39Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 39Tutorial BGP - GTER Interior BGP iBGP Peering AS 9999 AS 7777AS 8888
  • 40. 40Tutorial BGP - GTER Política de Roteamento BGP “Routing Policy”
  • 41. 41Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 41Tutorial BGP - GTER JUNOS Route Preference Nexthop é alcançável? -1 = Not reachable Preferência menor 0 = directly connected 5 = static routes 7 = RSVP 9 = LDP 10 = OSPF internal 15 = ISIS L1 internal 18 = ISIS L2 internal 100 = RIP 130 = Aggregate or generated 150 = OSPF external 160 = ISIS L1 external 165 = ISIS L2 external 170 = BGP
  • 42. 42Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 42Tutorial BGP - GTER Seleção de rotas BGP - JUNOS Menor “route preference” Maior “local preference” AS-path mais curto Menor “Origin” (IGP < EGP < incomplete) Menor MED Externa sobre “confederation” sobre interna Menor métrica do IGP Menor “cluster list” Menor router-id
  • 43. 43Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 43Tutorial BGP - GTER Anúncio de rotas BGP - JUNOS Regras de anúncio BGP default Apenas rotas ativas • Todas as rotas aprendidas via BGP (exceto regra iBGP) • Anúncio de rotas inativas é possível via configuração É necessário configuração explícita para: • Anunciar rotas estáticas • Anunciar rotas agregadas • Anunciar rota default • Redistribuir rotas no BGP
  • 44. 44Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 44Tutorial BGP - GTER Routing Policy Controla as transferências de informações de roteamento entre a tabela de roteamento e cada protocolo de roteamento Informação de roteamento entrante pode ser ignorada ou modificada Informação de roteamento saínte pode ser suprimida ou modificada
  • 45. 45Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 45Tutorial BGP - GTER Quando aplicar uma política Não se quer importar para a tabela de roteamento todas as rotas aprendidas Não se quer anunciar todas as rotas da tabela de roteamento para os roteadores vizinhos Se deseja que um protocolo receba rotas a partir de outro protocolo Se deseja modificar informações associadas a uma rota
  • 46. 46Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 46Tutorial BGP - GTER Routing Policy Políticas de entrada afetam o que vai para a tabela de roteamento Políticas de saída manipulam o conteúdo da tabela de roteamento que é exportado
  • 47. 47Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 47Tutorial BGP - GTER Sintaxe de uma política no JUNOS Sintaxe básica policy-options { policy-statement nome-politica { term nome-termo { from { condicao-de-match; } to { condicao-de-match; } then { acao; } } acao-final; } } !!
  • 48. 48Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 48Tutorial BGP - GTER Visualização de rotas BGP Rotas recebidas de um peer antes de aplicar uma policy Rotas anunciadas para um peer específico user@host> show route advertising-protocol bgp 11.1.1.2 inet.0: 10 destinations, 10 routes (8 active, 0 holddown, 2 hidden) Prefix Nexthop MED Lclpref AS path 10.0.0.0/8 Self 100 I 172.16.0.0/12 Self 100 I user@host> show route receive-protocol bgp 11.1.1.1 inet.0: 6 destinations, 6 routes (5 active, 0 holddown, 1 hidden) Prefix Nexthop MED Lclpref AS path 10.0.0.0/8 11.1.1.1 100 I 172.16.0.0/12 11.1.1.1 100 I
  • 49. 49Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 49Tutorial BGP - GTER Políticas muito utilizadas Filtro de rotas “marcianas” Filtros de tamanho de prefíxo Anuncia agregado e suprime específicas Preferência por rotas de clientes sobre qualquer outra Preferência por rotas de peers sobre rotas de trânsito Marcação de rotas com communities
  • 50. 50Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 50Tutorial BGP - GTER Communities Marcação dada a um grupo de prefixos que partilham uma propriedade em comum Decisões de roteamento podem estar baseadas na community da rota Facilita e simplifica o controle das informações de rotas Deveria ser marcada pelo roteador de entrada RFC 1997 and 1998
  • 51. 51Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 51Tutorial BGP - GTER Well Known Communities NO_EXPORT (0xFFFFFF01) Não anuncia para outros peers eBGP NO_ADVERTISE (0xFFFFFF02) Não anuncia para nenhum peer NO_EXPORT_SUBCONFED (0xFFFFFF03) Não anuncia para outros ASs, incluindo membros de uma confederation
  • 52. 52Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 52Tutorial BGP - GTER Exemplos de Communities AS#:120 Rotas de clientes Marca “local preference” para 120 AS#:110 Rotas backup de clientes AS#:90 Rotas de “Private peer” AS#:80 Rotas de trânsito AS#:70 Rotas de “Public peer”
  • 53. 53Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 53Tutorial BGP - GTER Exemplo de configuração policy-statement TRANSITO-IN { term REJEITA-TAM-PREF { from policy TAM-PREF; then reject; } term REJEITA-MARCIANAS { from policy MARCIANAS; then reject; } term PERMITE-RESTO { then { community set TRANSIT-ROUTES; local-preference 80; accept; } } } community TRANSIT-ROUTES members 6666:70; Inspeção de rotas de entrada
  • 54. 54Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 54Tutorial BGP - GTER Agregação de rotas Sumarização de um grupo de rotas com prefixo em comum Reduz a tabela de rotas, anúncios de roteamento e instabilidade routing-options { aggregate { route 8.8.0.0/16; { passive; } }
  • 55. 55Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 55Tutorial BGP - GTER Agregação de rotas policy-options { policy-statement SUPPRESS-SPECIFICS { from route-filter 8.8/16 longer reject; } Supressão explícita das rotas contribuíntes Atributo “atomic-aggregate” Indica perda de informação devido à agregação Atributo “aggregator” Especifica o nº do AS e o router-id do roteador agregador RFC 2519
  • 56. 56Tutorial BGP - GTER Escalando o iBGP Full Mesh
  • 57. 57Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 57Tutorial BGP - GTER Escalando o iBGP Full Mesh Problema N2 1 roteador novo deve possuir peer com todos os outros. Os outros devem adicionar peer com o roteador novo Adiciona sobrecarga de processamento TCP Aumenta tamanho das tabelas de roteamento 2 métodos para escalar Route Reflection (RFC 2796) Confederations (RFC 1965)
  • 58. 58Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 58Tutorial BGP - GTER Route Reflection Permite um peer iBGP anunciar uma rota aprendida via iBGP para outro peer iBGP Reduz iBGP full mesh RR apenas reflete o melhor caminho RR não modifica os atributos BGP
  • 59. 59Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 59Tutorial BGP - GTER AS 9999AS 8888 AS 7777 Route Reflection iBGP Full Mesh Peering RR Peering
  • 60. 60Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 60Tutorial BGP - GTER Route Reflection Isso não cria a possibilidade de loops? Novos atributos Cluster-id • Identifica o “route reflection cluster” • Adicionado à rota pelo RR Cluster-list • Sequência de cluster-ids que um update atravessou • Similar ao AS-path list Originator-id • Identifica o roteador que originou a rota no AS • Adicionado à rota pelo RR
  • 61. 61Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 61Tutorial BGP - GTER Exemplo de Configuração routing-options { autonomous-system 6666; } protocols { bgp { damping; group ibgp-mesh { export [ nexthopself send-connected ]; local-address 8.8.254.253; peer-as 6666; neighbor 1.2.3.4; neighbor 2.3.4.5; neighbor 3.4.5.6; } group rr-cluster { cluster 1.1.1.1; export [ nexthopself send-connected ]; local-address 8.8.254.253; peer-as 6666; neighbor 4.5.6.7;
  • 62. 62Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 62Tutorial BGP - GTER RJO CTAPAE SDR Full iBGP Mesh Route Reflection SPO BSA RR Cluster 1.1.1.1 RR Cluster 2.2.2.2 eBGP Peering AS 7777 Route Reflection
  • 63. 63Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 63Tutorial BGP - GTER Route Reflection redundante É possível fazer full-mesh de clientes de um RR No-client-reflect • RR não reflete rotas intra-cluster
  • 64. 64Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 64Tutorial BGP - GTER Confederations Outro método de reduzir o iBGP full mesh Quebra o AS em múltiplos sub-ASs Sub-ASs Podem utilizar número de AS privados iBGP full mesh dentro do sub-AS ou RR AS é visto externamente como único AS Sub-ASs não contabilizados como AS-path hops
  • 65. 65Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 65Tutorial BGP - GTER RJO SDR Full iBGP Mesh Route Reflection eBGP Peering Confederations Confederation 6666 Central Sub-AS 65100 (ISIS) SPO POP Sub-AS 65102 (OSPF) PAE POP Sub-AS 65101 (ISIS) Peer ISP Peer ISP Peer ISP Peer ISP Clientes Clientes
  • 66. 66Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 66Tutorial BGP - GTER Confederation BGP cBGP (ou e-iBGP) É eBGP ou iBGP? BGP nexthop AS-path Local-preference
  • 67. 67Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 67Tutorial BGP - GTER Confederations/RRs Vantagens de confederations sobre RR? Anexação de outro ISP Pode facilitar a migração/integração de redes adquiridas Pode rodar múltiplos IGPs Desvantagens Migração abrupta de uma rede iBGP full mesh Aparenta ser um pouco mais complicado Roteamento sub-ótimo dentro da confederation
  • 68. 68Tutorial BGP - GTER Novas Funcionalidades no BGP v4
  • 69. 69Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 69Tutorial BGP - GTER Negociação de Capacidades Permite negociação de capacidades entre peers BGP RFC 1771 Se a mensagem de Open contém funcionalidade não suportada, envia Notification com subcode 4 “Unsupported Optional Parameter” e termina sessão Não facilita a introdução de novas funcionalidade no BGP RFC 2842
  • 70. 70Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 70Tutorial BGP - GTER Communities Estendidas Duas melhorias importantes Faixa estendida (4 para 8 octetos) Adiciona campo TYPE (2 octetos) Route target community Identifica o destino da rota Route origin community Identifica a origem da rota Utilizada para controlar a distribuição de MPLS VPNs draft-ramachandra-bgp-ext-communities-04.txt
  • 71. 71Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 71Tutorial BGP - GTER Communities Estendidas [edit] policy-options { community test-a members [target:9999:70]; community test-b members [target:1.1.1.1:90]; community test-c members [origin:6666:110]; }
  • 72. 72Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 72Tutorial BGP - GTER Capacidade de Route Refresh Forma dinâmica de requisitar o re-anúncio de rotas de um peer JUNOS guarda cópias inalteradas de todas as rotas na RIB-In draft-ietf-idr-bgp-route-refresh-01.txt user@host> clear bgp neighbor 11.1.1.1 soft-inbound user@host> show route receive-protocol bgp 11.1.1.1
  • 73. 73Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 73Tutorial BGP - GTER MBGP Extensão que permite o BGP carregar informação de múltiplas camadas de rede e famílias de endereços Utilizado para Multicast Utilizado pelo MPLS VPNs para carregar labels MP_REACH_NLRI • VPN-IPv4 + Label user@host# set nlri [ multicast | unicast | any ]
  • 74. 74Tutorial BGP - GTER Route Damping
  • 75. 75Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 75Tutorial BGP - GTER Route Damping Reduz a carga de “update” para rotas bem comportadas Geralmente aplicado para rotas eBGP Pode ser usado com confederation Configurado a partir de um conjunto de parâmetros que inspecionam a atividade das rotas mal comportadas Deve-se habilitar o BGP damping Quantos ISPs ainda utilizam damping? RFC 2439
  • 76. 76Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 76Tutorial BGP - GTER AS 8888 AS 7777 Route Flap Damping Rotas instáveis anunciadas e removidas pelo AS 7777 AS 8888 aguarda as rotas estabilizarem para aceitá-las
  • 77. 77Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 77Tutorial BGP - GTER Damping—Figura de Mérito Nova rota recebe figura de mérito 0 Figura de mérito incrementa a cada incidente Withdrawn route–1000 Mudança de atributo–500 Rota é suprimida quando a figura de mérito excede o limiar de supressão Limiar de supressão default é 3000 Rota é reutilizada quando a figura de mérito cai abaixo do limiar de reutilização Limiar de reutilização default é 750
  • 78. 78Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 78Tutorial BGP - GTER Damping—Figura de Mérito Decaimento exponencial Reduz a figura de mérito com o tempo Half-life default de 15 min Limite máximo de tempo de supressão Default é 60 min Figura de mérito máxima Limita incremento quando o teto é atingido Determinado por fórmula Não configurável de forma explícita
  • 79. 79Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 79Tutorial BGP - GTER Route Damping Figure of Merit Time Suppressed Reused 750 3000 1000 2000 Flap 1 Flap 2 Flap 3 Flap 4 Flap 5 Half-life Half-life
  • 80. 80Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 80Tutorial BGP - GTER Damping—Configuração Definição de parâmetros de damping é semelhante à definição de community policy-options { damping name { half-life minutes; max-suppress minutes; reuse number; suppress number; } }
  • 81. 81Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 81Tutorial BGP - GTER Damping—Example policy-options { policy-statement damp { from { route-filter 11/8 exact damping high; route-filter 15/8 exact damping medium; route-filter 0/0 upto /24 damping none; } then accept; } damping high { half-life 15; suppress 3000; reuse 2500; max-suppress 50; } damping medium { half-life 3; max-suppress 4; } damping none { disable; } }
  • 82. 82Copyright © 2003 Juniper Networks, Inc. Proprietary and Confidential www.juniper.net 82Tutorial BGP - GTER Show BGP Summary Informações básicas sobre neighbors BGP user@host> show bgp summary Groups: 12 Peers: 26 Unestablished peers: 2 Peer AS InPkt OutPkt OutQ Flaps Last Up/Dn State|#Act/Recv/Damp 131.103.0.2 45 1225 55263 50511 2 18:22:14 47769/50591/67 192.168.1.1 33 911 0 0 0 18:22:27 Active 192.168.1.97 23 10458 2201 41043 0 18:22:03 0/0/0 192.168.1.100 432 10458 163 17643 0 17:01:18 Active …
  • 83. 83Tutorial BGP - GTER Perguntas? caio@juniper.net
  • 84. 84Tutorial BGP - GTER Obrigado!