Top Banner
BGP Network Design RIPE 49 Pedro Roque Marques [email protected]
26

BGP Network Design RIPE 49 - Marseillemeetings.ripe.net/ripe-49/presentations/ripe49-routing-bgp-design.pdf · BGP Network Design RIPE 49 ... In practice, many use RR as a configuration

Apr 13, 2018

Download

Documents

danglien
Welcome message from author
This document is posted to help you gain knowledge. Please leave a comment to let me know what you think about it! Share it to your friends and learn new things together.
Transcript
Page 1: BGP Network Design RIPE 49 - Marseillemeetings.ripe.net/ripe-49/presentations/ripe49-routing-bgp-design.pdf · BGP Network Design RIPE 49 ... In practice, many use RR as a configuration

BGP Network DesignRIPE 49

Pedro Roque [email protected]

Page 2: BGP Network Design RIPE 49 - Marseillemeetings.ripe.net/ripe-49/presentations/ripe49-routing-bgp-design.pdf · BGP Network Design RIPE 49 ... In practice, many use RR as a configuration

Introduction

Personal view as a person on the equipment vendor side.BGP design decisions.Frequent discussion topics:

How much hierarchy ?Where to place route reflectors.Implications of MEDs and damping.Next-hop self.Advertising multiple paths in BGP.

Page 3: BGP Network Design RIPE 49 - Marseillemeetings.ripe.net/ripe-49/presentations/ripe49-routing-bgp-design.pdf · BGP Network Design RIPE 49 ... In practice, many use RR as a configuration

An example

10 locations; 2 core routers each.Route reflection from core to access.Goal: keep traffic away from E-W links.

Transit Transit ConfedConfed

East East ConfedConfed

West West ConfedConfed

InternetInternet

InternetInternet

Page 4: BGP Network Design RIPE 49 - Marseillemeetings.ripe.net/ripe-49/presentations/ripe49-routing-bgp-design.pdf · BGP Network Design RIPE 49 ... In practice, many use RR as a configuration

What is wrong with this picture ?

IGP metrics control which exit point gets selected.Top level of hierarchy unnecessary to meet requirement.Adds significant amount of complexity.

Transit Transit ConfedConfed

East East ConfedConfed

West West ConfedConfed

InternetInternet

InternetInternet

Page 5: BGP Network Design RIPE 49 - Marseillemeetings.ripe.net/ripe-49/presentations/ripe49-routing-bgp-design.pdf · BGP Network Design RIPE 49 ... In practice, many use RR as a configuration

What does BGP do well ?

Database transfer of external routing information (bulk).

Designed for networks with 100s of iBGP mesh peeers, millions of paths.With rudimentary policy selection.

It is not an IGP. Doesn’t care which internal links are up or down; doesn’t need to follow link topology.

Using BGP for internal traffic eng. is generally a bad idea.

Page 6: BGP Network Design RIPE 49 - Marseillemeetings.ripe.net/ripe-49/presentations/ripe49-routing-bgp-design.pdf · BGP Network Design RIPE 49 ... In practice, many use RR as a configuration

Confederations <-> Reflection

“You’re right! No need to use confederations. We will use 2 levels of route reflection instead”.Same beast by a different name.Confederations are equivalent to Reflection w/ no-client-to-client (as per spec).Difference: boundary on the link, or on the system.

Page 7: BGP Network Design RIPE 49 - Marseillemeetings.ripe.net/ripe-49/presentations/ripe49-routing-bgp-design.pdf · BGP Network Design RIPE 49 ... In practice, many use RR as a configuration

Route Reflection

AccessCore

x 2000x 2000x 200x 200

CoreAccess

Goal: Reduce routing information.Otherwise you can end up with 2k copies of the routing table.Non-goals: configuration management; scaling # TCP sessions.

Page 8: BGP Network Design RIPE 49 - Marseillemeetings.ripe.net/ripe-49/presentations/ripe49-routing-bgp-design.pdf · BGP Network Design RIPE 49 ... In practice, many use RR as a configuration

Information hiding1010

200200

200200

100100

5050

BBAA

CC

10.0.1/2410.0.1/24

10.0.1/2410.0.1/24

EEDD

Assume {a, b} reflectors for {c, d, e}Without client-reflection: only c is used as exit point from d.Beyond the cluster: lost path to e.

Page 9: BGP Network Design RIPE 49 - Marseillemeetings.ripe.net/ripe-49/presentations/ripe49-routing-bgp-design.pdf · BGP Network Design RIPE 49 ... In practice, many use RR as a configuration

Configuration management

In practice, many use RR as a configuration management tool.It is the wrong tool for the job: “side effects” of path selection are not usually understood.Solutions ?

Automated scripts / provisioning system;draft-raszuk-idr-ibgp-auto-mesh-00.txt;

Page 10: BGP Network Design RIPE 49 - Marseillemeetings.ripe.net/ripe-49/presentations/ripe49-routing-bgp-design.pdf · BGP Network Design RIPE 49 ... In practice, many use RR as a configuration

Information hiding

vava

nyny

amsams

lonlon

chichi

caca

txtx

frkfrk

parpar

lislis

Confed per continent or top level RRs on both sides of the pond.Vs all major locations on top level mesh.

Page 11: BGP Network Design RIPE 49 - Marseillemeetings.ripe.net/ripe-49/presentations/ripe49-routing-bgp-design.pdf · BGP Network Design RIPE 49 ... In practice, many use RR as a configuration

Trade-offs

Confed per continent Large top level mesh

1 path per inter-continent link.

1 off-continent path per city (worse case).

Less info for choosing exit point.

More ability to do intra-domain TE.

Convergence depends on 2 RR hops.

Choice of remote exit point via IGP metric.

Ability to do policy. No policy.

Page 12: BGP Network Design RIPE 49 - Marseillemeetings.ripe.net/ripe-49/presentations/ripe49-routing-bgp-design.pdf · BGP Network Design RIPE 49 ... In practice, many use RR as a configuration

How RRs achieve efficiency

Statement: BGP can do 100s of iBGP mesh peers or rr-clients.Under what conditions is this true ?BGP efficiency depends on peer-groups.

Select which routes should be advertised once per group;Format updates once per group;Copy the update to N sockets;

Means BGP is as efficient w/ 1 peer or 100 per group (minus TCP processing).

Page 13: BGP Network Design RIPE 49 - Marseillemeetings.ripe.net/ripe-49/presentations/ripe49-routing-bgp-design.pdf · BGP Network Design RIPE 49 ... In practice, many use RR as a configuration

Caveat

We left flow-control out of the previous equation (which is per peer).Revise: work is done per set of peers in the group which have approx. same flow-control state.

Implementation dependent: select updates to send once per group (or sub-group). JunOS only formats messages per sub-group.

Particularly for an RR (sending full routes) the Round Trip Time distribution to clients does matter.

Page 14: BGP Network Design RIPE 49 - Marseillemeetings.ripe.net/ripe-49/presentations/ripe49-routing-bgp-design.pdf · BGP Network Design RIPE 49 ... In practice, many use RR as a configuration

Recommendations

Keep It Simple.Engineering: find the lowest cost solution that satisfies the problem.

Avoid loosing information in the core.Keep your multiple city to city choices available.

Avoid centralization.Distribution improves resiliency and performance.

Page 15: BGP Network Design RIPE 49 - Marseillemeetings.ripe.net/ripe-49/presentations/ripe49-routing-bgp-design.pdf · BGP Network Design RIPE 49 ... In practice, many use RR as a configuration

Cold-potato

amsamslonlon

frkfrk

milmil

parpar

10.0.1/2410.0.1/24

10.0.1/2410.0.1/24

MED 5MED 5

MED 10MED 10

Customer pays ISP to transport incoming traffic to selected location.From London POV: w/o MED 2 available paths; w/ MED only one.

Page 16: BGP Network Design RIPE 49 - Marseillemeetings.ripe.net/ripe-49/presentations/ripe49-routing-bgp-design.pdf · BGP Network Design RIPE 49 ... In practice, many use RR as a configuration

Implications of cold-potato

AMS router prefers MIL; and refrains from advertising its own path.Less information; only best overall path is known.Convergence: withdrawal of MIL path will cause AMS to advertise its alternate; LON will probably see MIL -> unreach -> AMS.JunOS has hidden knob to force advertisement of “best-external” route.

Page 17: BGP Network Design RIPE 49 - Marseillemeetings.ripe.net/ripe-49/presentations/ripe49-routing-bgp-design.pdf · BGP Network Design RIPE 49 ... In practice, many use RR as a configuration

Cold-potato (continued).

Likely-hood of MED oscillation problems: proportional to the number of hierarchies in the network.Simplest case:

In A: p1 < p2; p2 < p3 < p1In B: p2 < p3; p3 < p1

p1p1 p2p2 p3p3ASAS 11 22 11MEDMED 1010 1010 55

5050 6060 100100

1010AA BB

p1p1

p3p3

p2p2

Page 18: BGP Network Design RIPE 49 - Marseillemeetings.ripe.net/ripe-49/presentations/ripe49-routing-bgp-design.pdf · BGP Network Design RIPE 49 ... In practice, many use RR as a configuration

To “next-hop self”

… Or not to “next-hop self”.

Advantages of external next-hop addresses:Metric of external link can be used to influence decision.Convergence in terms of IGP propagation.

Assumes efficient detection of resolution changes by remote peer.

Disadvantages:Need to configure external link as passive in IGP.

Page 19: BGP Network Design RIPE 49 - Marseillemeetings.ripe.net/ripe-49/presentations/ripe49-routing-bgp-design.pdf · BGP Network Design RIPE 49 ... In practice, many use RR as a configuration

Damping

Goal: eliminate noise generated by flapping tail circuit.Problem: it cannot distinguish between that case and changes caused by transit ASes(example: MED change).Current implementations create more problems than it solves.If you must: crank up suppress; low half-life so that only continuous flapping prefixes are suppressed.

Page 20: BGP Network Design RIPE 49 - Marseillemeetings.ripe.net/ripe-49/presentations/ripe49-routing-bgp-design.pdf · BGP Network Design RIPE 49 ... In practice, many use RR as a configuration

Routing Views

“Can BGP advertise more than one path ?”RFC 2547

Route Distinguisher qualifies IP prefix.Route Target community used to control which routes are imported into which forwarding tables.

JunOSInput firewall filter can specify which routing-instance to use for forwarding lookup.

Use of tunneling (mpls, ip) in the core.

Page 21: BGP Network Design RIPE 49 - Marseillemeetings.ripe.net/ripe-49/presentations/ripe49-routing-bgp-design.pdf · BGP Network Design RIPE 49 ... In practice, many use RR as a configuration

Upstream selection

inetinet

isp1isp1

inetinet

isp2isp2

aa

10.0.1/24 1 10458 1045810.0.1/24 1 10458 10458 10.0.1/24 2 1045810.0.1/24 2 10458

gw1gw1 gw2gw2

pe1pe1 pe2pe2

bb

Policy: customer Ca uses upstream 1; other customers use best of all internet routes.

Page 22: BGP Network Design RIPE 49 - Marseillemeetings.ripe.net/ripe-49/presentations/ripe49-routing-bgp-design.pdf · BGP Network Design RIPE 49 ... In practice, many use RR as a configuration

Configuration – gw1

[edit routing-options]rib-groups rg-isp1 {

import-rib [inet.0 isp1.inet.0];/* optional import-policy */

}[edit protocols bgp group isp1] family inet unicast rib-group rg-isp1;[edit routing-instances isp1]instance-type vrf;vrf-target target:10458:1; /* identify table */

Page 23: BGP Network Design RIPE 49 - Marseillemeetings.ripe.net/ripe-49/presentations/ripe49-routing-bgp-design.pdf · BGP Network Design RIPE 49 ... In practice, many use RR as a configuration

Configuration – pe1

[edit routing-instances isp1]instance-type vrf;vrf-target target:10458:1; /* identify table */[edit interfaces so-0/0/1.0 family inet]filter input fbf;[edit firewall filter fbf]term a {

from /* some criteria */then routing-instance isp1;

}

Page 24: BGP Network Design RIPE 49 - Marseillemeetings.ripe.net/ripe-49/presentations/ripe49-routing-bgp-design.pdf · BGP Network Design RIPE 49 ... In practice, many use RR as a configuration

Limitations

# entries in forwarding tables.Can selectively discard forwarding table state.No forwarding entries needed for diagnostic applications.Scaling of BGP: depends mostly on the number of events processed rather than number of total entries.

Page 25: BGP Network Design RIPE 49 - Marseillemeetings.ripe.net/ripe-49/presentations/ripe49-routing-bgp-design.pdf · BGP Network Design RIPE 49 ... In practice, many use RR as a configuration

Recent JunOS BGP behavior changes

6.3Incoming interface check on EBGP sessions.Policy from aggregate-contributor.

7.0No EBGP poison reverse to neighbor-as.policy next-hop [discard | reject].TCP path mtu discovery (knob).

Page 26: BGP Network Design RIPE 49 - Marseillemeetings.ripe.net/ripe-49/presentations/ripe49-routing-bgp-design.pdf · BGP Network Design RIPE 49 ... In practice, many use RR as a configuration

Thank You

http://www.juniper.net