Académique Documents
Professionnel Documents
Culture Documents
Abdelaziz ESSOUFY
18-26 October2010
MPLS Concepts
Benefits of MPLS
MPLS supports multiple applications including:
Unicast and multicast IP routing
VPN
TE
QoS
AToM
MPLS decreases forwarding overhead on core
routers.
MPLS can support forwarding of non-IP protocols.
LSRs:
Architecture of Edge LSRs
MPLS core routers swap labels and forward packets based on simple
label lookups.
MPLS edge routers also perform a routing table lookup, and add or
remove labels.
MPLS Concepts
The outer label is used for switching the packet in the MPLS
network (points to the TE destination).
Inner labels are used to separate packets at egress points (points
to egress router and identifies VPN).
Configuring IP CEF
Router(config)#
ip cef [distributed]
This command starts CEF switching and creates the FIB
table.
The distributed keyword configures distributed CEF
(running on VIP or line cards).
All CEF-capable interfaces run CEF switching.
Router(config-if)#
no ip route-cache cef
Disables CEF switching on an interface
Usually not needed
Monitoring IP CEF
Optional:
Configure the MPLS ID
Configure MTU size for labeled packets
Configure IP TTL propagation
Configure conditional label advertising
mpls ip
Router#
Introducing VPNs
VPN Terminology
Note:
PE Router = Edge LSR
P Router = LSR
PE Router Architecture
Question:
Option #1: Run a dedicated IGP for each customer across the P-network.
This is the wrong answer for these reasons:
The solution does not scale.
P routers carry all customer routes.
Question:
Option #2: Run a single routing protocol that will carry all customer routes
inside the provider backbone.
Better answer, but still not good enough:
P routers carry all customer routes.
Question:
Option #3: Run a single routing protocol that will carry all customer
routes between PE routers. Use MPLS labels to exchange
packets between PE routers.
The best answer:
P routers do not carry customer routes; the solution is scalable.
The number of customer routes can be very large. BGP is the only
routing protocol that can scale to a very large number of routes.
Conclusion:
BGP is used to exchange customer routes directly between PE routers.
Route Distinguishers
The 64-bit route distinguisher is prepended to an IPv4
address to make it globally unique.
The resulting address is a VPNv4 address.
VPNv4 addresses are exchanged between PE routers
via BGP.
BGP that supports address families other than IPv4
addresses is called MP-BGP.
A similar process is used in IPv6:
64-bit route distinguisher is prepended to a 16-byte IPv6
address.
The resulting 24-byte address is a unique VPNv6 address.
PE routers:
Exchange VPN routes with CE routers via per-VPN routing protocols
Exchange core routes with P routers and PE routers via core IGP
Exchange VPNv4 routes with other PE routers via MP-IBGP sessions
PE routers can run standard IPv4 BGP in the global routing table:
PE routers exchange Internet routes with other PE routers.
CE routers do not participate in Internet routing.
P routers do not need to participate in Internet routing.
PE routers export VPN routes from VRF tables into MP-BGP and
propagate them as VPNv4 routes to other PE routers.
VRF Table
A VRF is the routing and forwarding instance for a set
of sites with identical connectivity requirements.
Data structures associated with a VRF are as follows:
IP routing table
CEF table
Set of rules and routing protocol parameters
(routing protocol contexts)
List of interfaces that use the VRF
VRF Table
Contains routes that should be available to a
particular set of sites
Analogous to standard Cisco IOS software routing
table; supports same set of mechanisms
VPN interfaces (physical interface, subinterfaces,
logical interfaces) assigned to VRFs:
Many interfaces per VRF
Each interface assignable to only one VRF
The route distinguishers are prepended during the route export to the
BGP routes from the VRF instance of the BGP process to convert them
into VPNv4 prefixes. Route targets are attached to these prefixes.
VPNv4 prefixes are propagated to other PE routers.
Routes are received from backbone MP-BGP and imported into a VRF.
IPv4 routes are forwarded to EBGP CE neighbors attached to
that VRF.
The RIP routes entered in the VRF routing table are redistributed into BGP
for further propagation into the MPLS VPN backbone.
Redistribution between RIP and BGP has to be configured for proper
MPLS VPN operation.
MP-IBGP routes imported into a VRF are redistributed into the instance
of RIP configured for that VRF.
Redistribution between BGP and RIP has to be configured for
end-to-end RIP routing between CE routers.
Routes redistributed from BGP into a VRF instance of RIP are sent to
RIP-speaking CE routers.
ip vrf name
rd route-distinguisher
route-target export RT
Specifies an RT to be attached to every route exported from
this VRF to Multiprotocol Border Gateway Protocol
Allows specification of many export RTsall to be attached
to every exported route
Router(config-vrf)#
route-target import RT
Specifies an RT to be used as an import filter (Only routes
matching the RT are imported into the VRF.)
Allows specification of many import RTs (any route where at
least one RT attached to the route matches any import RT is
imported into the VRF.)
Because of implementation issues, at least one export route target must also be
an import route target of the same VRF in Cisco IOS Release 12.4(T) and earlier.
route-target both RT
address-family vpnv4
BGP Neighbors
MP-BGP neighbors are configured under the BGP
routing process:
These neighbors need to be activated for each global
address family that they support.
Per-address-family parameters can be configured for
these neighbors.
Configuring MP-BGP
MPLS VPN MP-BGP configuration steps:
Configure MP-BGP neighbor under BGP routing
process.
Configure BGP address family VPNv4.
Activate configured BGP neighbor for VPNv4 route
exchange.
Specify additional parameters for VPNv4 route
exchange (filters, next hops, and so on).
Configuring MP-IBGP
Router(config)#
address-family vpnv4
This command starts configuration of MP-BGP routing for VPNv4
route exchange.
The parameters that apply only to MP-BGP exchange of VPNv4
routes between already configured IBGP neighbors are configured
under this address family.
Router(config-router-af)#
router rip
version 2
address-family ipv4 vrf vrf-name
redistribute bgp as-number metric transparent
When you are using RIP with other protocols, the metric must be
manually set.
Monitoring VRFs
Router#
show ip vrf
Monitoring VRFs:
show ip vrf
Router#show ip vrf
Name
SiteA2
SiteB
SiteX
Router#
Default RD
103:30
103:11
103:20
Interfaces
Serial1/0.20
Serial1/0.100
Ethernet0/0
Monitoring VRFs:
show ip vrf detail
Router#show ip vrf detail
VRF SiteA2; default RD 103:30
Interfaces:
Serial1/0.20
Connected addresses are not in global routing table
No Export VPN route-target communities
Import VPN route-target communities
RT:103:10
No import route-map
Export route-map: A2
VRF SiteB; default RD 103:11
Interfaces:
Serial1/0.100
Connected addresses are not in global routing table
Export VPN route-target communities
RT:103:11
Import VPN route-target communities
RT:103:11
RT:103:20
No import route-map
No export route-map
Monitoring VRFs:
show ip vrf interfaces
VRF
SiteA2
SiteB
SiteX
Protocol
up
up
up
Router#
The show ip cef command can also display the label stack associated
with the MP-IBGP route.
Outgoing
interface
Next Hop
Se1/0.20
Se1/0.20
Next Hop
In label/Out label
34/nolabel
35/nolabel
26/nolabel
26/nolabel
nolabel/26