Tải bản đầy đủ (.pdf) (47 trang)

Tài liệu IP over MPLS pptx

Bạn đang xem bản rút gọn của tài liệu. Xem và tải ngay bản đầy đủ của tài liệu tại đây (1.82 MB, 47 trang )


IP over MPLS
Overview
This module focuses on the IP QoS mechanisms available in combination with
Multiprotocol Label Switching (MPLS).
Objectives
Upon completion of this module, you will be able to perform the following tasks:
n Describe and configure QoS Mechanisms in Frame-mode MPLS networks
n Describe and configure QoS Mechanisms in Cell-mode MPLS networks

23-2 World Wide Training Word Templates v1 Copyright  1999, Cisco Systems, Inc.
MPLS Introduction
Objectives
Upon completion of this lesson, you will be able to perform the following tasks:
n Describe basic features of MPLS
n Describe Frame-mode MPLS
n Describe Cell-mode MPLS

Copyright  1999, Cisco Systems, Inc. Release Date: 2/1/99 23-3
© 2001, Cisco Systems, Inc. IP QoS IP over MPLS
Basic MPLS Concepts
Basic MPLS Concepts
• Multi-protocol Label Switching (MPLS) is a
new forwarding mechanism in which packets
are forwarded based on labels
• Labels may correspond to IP destination
networks (equal to traditional IP forwarding)
• Labels can also correspond to other
parameters (QoS, source address, )
• MPLS was designed to support forwarding of
other protocols as well



Multi-protocol Label Switching (MPLS) is a switching mechanism that uses labels
(numbers) to forward packets.
Labels usually correspond to layer-3 destination addresses (equal to destination-
based routing). Labels can also correspond to other parameters (QoS, source
address, etc.).
MPLS was designed to support other protocols as well. Label switching is
performed regardless of the layer-3 protocol.



23-4 World Wide Training Word Templates v1 Copyright  1999, Cisco Systems, Inc.
© 2001, Cisco Systems, Inc. IP QoS IP over MPLS
MPLS Example
MPLS Example
• Only edge routers must perform a routing
lookup.
• Core routers switch packets based on simple
label lookups and swap labels.
L=5
L=3
10.1.1.1
10.1.1.1
Routing lookup
and
label assignment
10.0.0.0/8 à L=5
Label
swapping
L=5 à L=3

Label removal
and
routing lookup
L=3

The example in the figure illustrates a situation where the intermediary router does
not have to perform a time-consuming routing lookup. Instead this router simply
swaps a label with another label (5 is replaced by 3) and forwards the packet
based on the received label (5).
In larger networks, the result of MPLS labeling is that only the edge routers
perform a routing lookup. All the core routers forward packets based on the labels.

Copyright  1999, Cisco Systems, Inc. Release Date: 2/1/99 23-5
© 2001, Cisco Systems, Inc. IP QoS IP over MPLS
MPLS vs. IP-over-ATM
MPLS vs. IP-over-ATM
• Layer-2 devices are IP-aware and run a
routing protocol
• There is no need to manually establish
virtual circuits
• MPLS provides a virtual full-mesh topology
10.1.1.1L=5
L=3
L=1710.1.1.1
Layer-2 devices run a
layer-3 routing protocol
and establish virtual
circuits dynamically based
on layer-3 information


The example in the figure shows how MPLS is used in ATM networks to provide
optimal routing across layer-2 ATM switches. In order for MPLS to work with
ATM switches, the switches must be layer-3 aware (ATM switches must run a
layer-3 routing protocol).
Another benefit of this setup is that there is no longer a need to manually establish
virtual circuits. ATM switches automatically create a full mesh of virtual circuits
based on layer-3 routing information.

23-6 World Wide Training Word Templates v1 Copyright  1999, Cisco Systems, Inc.
© 2001, Cisco Systems, Inc. IP QoS IP over MPLS
Traffic Engineering with MPLS
Traffic Engineering with MPLS
• Traffic can be forwarded based on other
parameters (QoS, source, )
• Load sharing across unequal paths can be
achieved
Secondary
OC-48 link
Large site A
Large site B
Small site C
Primary
OC-192 link

MPLS also supports traffic engineering. Traffic engineered tunnels can be created
based on a traffic analysis to provide load balancing across unequal paths.
Multiple traffic engineering tunnels can lead to the same destination but can use
different paths. Traditional IP forwarding would force all traffic to use the same
path based on the destination-based forwarding decision. Traffic engineering
determines the path at the source based on additional parameters (available

resources and constraints in the network).

Copyright  1999, Cisco Systems, Inc. Release Date: 2/1/99 23-7
© 2001, Cisco Systems, Inc. IP QoS IP over MPLS
MPLS Architecture
MPLS Architecture
• MPLS has two major components:
• Control plane – exchanges layer-3 routing information and
labels
• Data plane – forwards packets based on labels
• Control plane contains complex mechanisms to
exchange routing information (OSPF, EIGRP, IS-IS,
BGP, ) and labels (TDP, LDP, BGP, RSVP, )
• Control plane maintains the contents of the label
switching table (label forwarding information base or
LFIB)
• Data plane has a simple forwarding engine

To better understand the inner workings of MPLS, its two major components
should be clarified:
n Control plane, which takes care of the routing information exchange and the
label exchange between adjacent devices
n Data plane, which takes care of forwarding either based on destination
addresses or labels.
There is a large number of different routing protocols such as OSPF, IGRP,
EIGRP, IS-IS, RIP, BGP, etc. that can be used in the control plane.
The control plane also requires protocols such as TDP (MPLS), LDP (MPLS),
BGP (MPLS/VPNs), RSVP (Traffic Engineering), CR-LDP (Traffic
Engineering), etc. to exchange labels.
The data plane however, is a simple label-based forwarding engine that is

independent of the type of routing protocol or label exchange protocol. A Label
Forwarding Information Base (LFIB) is used to forward packets based on labels.
The LFIB table is populated by the control plane.

23-8 World Wide Training Word Templates v1 Copyright  1999, Cisco Systems, Inc.
© 2001, Cisco Systems, Inc. IP QoS IP over MPLS
MPLS Architecture
MPLS Architecture
• Router’s functionality is divided into two
major parts: control plane and data plane
Data plane
Control plane
OSPF: 10.0.0.0/8
LDP: 10.0.0.0/8
Label 17
OSPF
LDP
LFIB
LDP: 10.0.0.0/8
Label 4
OSPF: 10.0.0.0/8
4à17
Labeled packet
Label 4
Labeled packet
Label 17

A simple MPLS-enabled network implements destination-based forwarding that
uses labels to make forwarding decisions.
A layer-3 routing protocol is still needed to propagate layer-3 routing information.

A label exchange mechanism is simply an add-on to propagate labels that are used
for layer-3 destinations.
The example in the figure illustrates the two components of the control plane:
n OSPF that receives and forwards IP network 10.0.0.0/8, and places that prefix
into the routing table.
n LDP that receives label 17 to be used for packets with a destination address
10.x.x.x. A local label 4 is generated and sent to upstream neighbors so these
neighbors can label packets with the appropriate label. LDP inserts an entry
into the Data Plane’s LFIB table where label 4 is mapped to label 17.
The data plane then forwards all packets with label 4 through the appropriate
interfaces and replaces the label with label 17.

Copyright  1999, Cisco Systems, Inc. Release Date: 2/1/99 23-9
© 2001, Cisco Systems, Inc. IP QoS IP over MPLS
MPLS Modes of Operation
MPLS Modes of Operation
• MPLS technology is designed to be Layer-1
and Layer-2 independent
• MPLS uses a 32-bit label field which is
inserted between Layer-2 and Layer-3
headers (frame mode)
• MPLS over ATM uses the ATM header as the
label (cell mode)

MPLS is designed for use on virtually any media and layer-2 encapsulation. Most
layer-2 encapsulations are frame-based and MPLS simply inserts a 32-bit label
between the layer-2 and layer-3 headers (“frame-mode” MPLS).
ATM is a special case where fixed-length cells are used and a label cannot be
inserted on every cell. MPLS uses the VPI/VCI fields in the ATM header as a
label (“cell-mode” MPLS).


23-10 World Wide Training Word Templates v1 Copyright  1999, Cisco Systems, Inc.
© 2001, Cisco Systems, Inc. IP QoS IP over MPLS
Label Format
Label Format
MPLS uses a 32-bit label field that
contains the following information:
• 20-bit label
• 3-bit experimental field
• 1-bit bottom-of-stack indicator
• 8-bit time-to-live field (TTL)
LABEL EXP S TTL
0
19
22 23 31
20 24

A 32-bit label contains the following fields:
n 20-bit label: the actual label
n 3-bit experimental field: used to define a class of service (i.e. IP precedence)
n Bottom-of-stack bit: MPLS allows multiple labels to be inserted; this bit is used
to determine if this is the last label in the packet
n 8-bit time-to-live (TTL) field: has the same purpose as the TTL field in the IP
header

Copyright  1999, Cisco Systems, Inc. Release Date: 2/1/99 23-11
© 2001, Cisco Systems, Inc. IP QoS IP over MPLS
Frame Mode MPLS
Frame Mode MPLS
Frame

header
IP header Payload
Layer 2 Layer 3
Frame
header
Label IP header Payload
Layer 2 Layer 2½ Layer 3
Routing
lookup and
label
assignment

The example in the figure shows an edge router that receives a normal IP packet.
The router then performs the following actions:
n A routing lookup to determine the outgoing interface
n A label is assigned and inserted between layer-2 frame header and layer-3
packet header if the outgoing interface is enabled for MPLS and a next-hop
label for the destination exists
n The labeled packet is sent
Other routers in the core simply forward the packet based on the label.

23-12 World Wide Training Word Templates v1 Copyright  1999, Cisco Systems, Inc.
© 2001, Cisco Systems, Inc. IP QoS IP over MPLS
Cell mode MPLS
Cell mode MPLS
Frame
header
IP header Payload
Layer 2 Layer 3
Frame

header
Label IP header Payload
Layer 2 Layer 2½ Layer 3
AAL5
header
Label IP header Payload
Layer 2 Layer 2½ Layer 3
ATM
header
Cell 1
Payload
ATM
header
Cell 2
VPI/VCI fields are
used for label
switching

Cell-mode MPLS uses the ATM header’s VPI/VCI fields to make forwarding
decisions while the 32-bit label is still preserved in the frame but not used in the
ATM network. The original label is only present in the first cell of a packet.

Copyright  1999, Cisco Systems, Inc. Release Date: 2/1/99 23-13
© 2001, Cisco Systems, Inc. IP QoS IP over MPLS
Label Switch Router
Label Switch Router
• Label Switch Router (LSR) primarily forwards labeled
packets (label swapping)
• Edge LSR primarily labels IP packets and forwards
them into the MPLS domain, or removes labels and

forwards IP packets out of the MPLS domain
MPLS Domain
Edge
LSR
LSR
10.1.1.1 L=3 L=5
L=43L=3120.1.1.1
10.1.1.1
20.1.1.1

Before proceeding with a detailed description of MPLS, some of the terminology
that is used in this course is presented:
n Label Switch Router (LSR): a device that primarily forwards packets based on
labels.
n Edge LSR: a device that primarily labels packets or removes labels.
LSRs and Edge LSRs are usually devices that are capable of doing both label
switching and IP routing. Their names are based on their position in an MPLS
domain. Routers that have all interfaces enabled for MPLS are called LSRs
because they mostly forward labeled packets. Routers that have some interfaces
that are not enabled for MPLS are usually at the edge of an MPLS domain
(autonomous system). These routers also forward packets based on IP destination
addresses and label them if the outgoing interface is enabled for MPLS.

23-14 World Wide Training Word Templates v1 Copyright  1999, Cisco Systems, Inc.
© 2001, Cisco Systems, Inc. IP QoS IP over MPLS
ATM Label Switch Router
ATM Label Switch Router
• ATM LSR can only forward cells
• ATM Edge LSR segments packets into cells and
forwards them into an MPLS ATM domain, or

reassembles cells into packets and forwards them
out of an MPLS ATM domain
MPLS Domain
ATM
Edge
LSR
ATM
LSR
10.1.1.1 L=1/3
L=1/620.1.1.1
10.1.1.1
20.1.1.1
L=1/3 L=1/3 L=1/5 L=1/5 L=1/5
L=1/6 L=1/6
L=1/9 L=1/9 L=1/9

Label Switch Routers that perform cell-mode MPLS are called:
n ATM LSR if they are ATM switches. All interfaces are enabled for MPLS
and forwarding is done based only on labels.
n ATM Edge LSR if they are routers connected to an MPLS-enabled ATM
network.

Copyright  1999, Cisco Systems, Inc. Release Date: 2/1/99 23-15
© 2001, Cisco Systems, Inc. IP QoS IP over MPLS
Architecture of LSRs
Architecture of LSRs
LSRs, regardless of the type, perform the
following three functions:
• Exchange routing information
• Exchange labels

• Forward packets (LSRs and edge LSRs) or
cells (ATM LSRs and ATM edge LSRs)
The first two functions are part of the
control plane
The last function is part of the data plane

LSRs of all types must perform the following functions:
n Exchange layer-3 routing information (ATM LSRs must also exchange layer-3
routing information)
n Exchange labels
n Forward packets or cells
Frame-mode and cell-mode MPLS use a different data plane:
n Frame-mode MPLS forwards packets based on the 32-bit label
n Cell-mode MPLS forwards packets based on labels encoded into the VPI/VCI
fields in the ATM header
The control plane performs the following functions:
n Exchange routing information regardless of the type of LSR;
n Exchange labels according to the type of MPLS (frame-mode or cell-mode);

23-16 World Wide Training Word Templates v1 Copyright  1999, Cisco Systems, Inc.
© 2001, Cisco Systems, Inc. IP QoS IP over MPLS
Architecture of LSRs
Architecture of LSRs
LSRs primarily forward labeled packets
or cells (ATM LSRs)
LSR
Control plane
Data plane
Routing protocol
Label distribution protocol

Label forwarding table
IP routing table
Exchange of
routing information
Exchange of
labels
Incoming
labeled packets
Outgoing
labeled packets

The primary function of an LSR is to forward labeled packets. Therefore, every
LSR needs a layer-3 routing protocol (OSPF, EIGRP, IS-IS, etc.) and a label
exchange protocol (LDP, TDP, etc.).
The label exchange protocol populates the LFIB table in the data plane that is used
to forward labeled packets.
Note LSRs may not be able to forward unlabeled packets either because they are ATM
LSRs, or they do not have all the routing information.

Copyright  1999, Cisco Systems, Inc. Release Date: 2/1/99 23-17
© 2001, Cisco Systems, Inc. IP QoS IP over MPLS
Architecture of Edge LSRs
Architecture of Edge LSRs
Note: ATM edge LSRs can only forward cells
Edge LSR
Control plane
Data plane
Routing protocol
Label distribution protocol
Label forwarding table

IP routing table
Exchange of
routing information
Exchange of
labels
Incoming
labeled packets
Outgoing
labeled packets
IP forwarding table
Incoming
IP packets
Outgoing
IP packets

Edge LSRs also forward IP packets based on their IP destination addresses and
optionally label them if a label exists.
The following combinations are possible:
n A received IP packet is forwarded based on the IP destination address and
sent as an IP packet.
n A received IP packet is forwarded based on the IP destination address and
sent as a labeled packet.
n A received labeled packet is forwarded based on the label; the label is changed
and the packet is sent.
The following scenarios are possible if the network is misconfigured:
n A received labeled packet is dropped if the label is not found in the LFIB table
even if the IP destination exists in the FIB table.
n A received IP packet is dropped if the destination is not found in the FIB table
even if there is a label-switched path available for the destination.
23-18 World Wide Training Word Templates v1 Copyright  1999, Cisco Systems, Inc.


Summary
MPLS architecture is divided into two parts:
n Control plane that takes care of routing information and label propagation.
n Data plane that takes care of the forwarding of packets.
MPLS has two modes:
n Frame-mode MPLS that is used on all frame-based media.
n Cell-mode MPLS that is used in MPLS-enabled ATM networks.
MPLS networks use the following devices:
n Label Switch Router (LSR) to forward packets based on a 32-bit label
n Edge LSR to forward labeled packets or label IP packets or remove labels.
n ATM LSRs to forward cells based on labels encoded into the VPI/VCI fields
in the ATM header.
n ATM Edge LSRs that segment labeled or unlabeled packets into ATM cells
where a label is encoded into VPI/VCI fields in the ATM header.
Review Questions
1. What are the main benefits of MPLS?
2. How is an MPLS label encoded into IP packets?
3. How are labels propagated?



Copyright  1999, Cisco Systems, Inc. Release Date: 2/1/99 23-19
Frame-mode MPLS
Objectives
Upon completion of this lesson, you will be able to perform the following tasks:
n Describe the QoS possibilities in networks using Frame-mode MPLS
n Use MQC to implement QoS with Frame-mode MPLS
23-20 World Wide Training Word Templates v1 Copyright  1999, Cisco Systems, Inc.
© 2001, Cisco Systems, Inc. IP QoS IP over MPLS

MPLS QoS
MPLS QoS
• MPLS uses labels to make a forwarding
decision
• The MPLS label is inserted between Layer-2
(frame) and Layer-3 (IP packet) headers
• All Layer-3 information becomes invisible to
routers in an MPLS domain
• Classification in MPLS-enabled networks can
be performed on:
• MPLS experimental bits
• MPLS labels (future enhancement)

Frame-mode MPLS uses 32-bit labels primarily to make a forwarding decision.
Three bits in the label are used for experimental purposes.
When an IP packet enters an MPLS domain a label is inserted between the frame
and the IP header.
The MPLS experimental bits can be used for classification and marking purposes
when implementing QoS in an MPLS domain.
Future enhancements will allow multiple labels to be used to describe the quality of
service.


Copyright  1999, Cisco Systems, Inc. Release Date: 2/1/99 23-21
© 2001, Cisco Systems, Inc. IP QoS IP over MPLS
MPLS Label Assignment
MPLS Label Assignment
• An MPLS label has a three-bit experimental field
• Cisco routers automatically copy IP precedence bits
into the MPLS experimental bits

• The Modular QoS CLI can be used to classify labeled
packets based on their MPLS experimental bits
LABEL IP
Frame
Header
Frame
Header
Payload
PayloadIP
IP precedece
MPLS exp

The figure illustrates the default behavior of Cisco routers. IP precedence is
automatically copied from the IP header into MPLS label’s experimental bits.
The modular QoS CLI can be used to classify labeled packets based on MPLS
experimental bits as well as mark labeled packets with MPLS experimental-bit
values.


23-22 World Wide Training Word Templates v1 Copyright  1999, Cisco Systems, Inc.
© 2001, Cisco Systems, Inc. IP QoS IP over MPLS
MPLS-aware QoS Mechanisms
MPLS-aware QoS Mechanisms
• The following QoS mechanisms are MPLS aware:
- Weighted Random Early Detection (WRED): MPLS
experimental bits are used as weight in the same manner as
IP precedence
- Committed Access Rate (CAR): marking of MPLS
experimental bits
- Class-Based Policing: marking of MPLS experimental bits

- Class-based Marking: marking of MPLS experimental bits
• If classification is performed based on MPLS
experimental bits, other MQC QoS mechanisms can
also be used

The figure lists the QoS mechanisms that can interact with MPLS-specific
information:
n WRED performs random drops based on MPLS experimental values.
n CAR can mark labeled packets with MPLS experimental values. Conforming
and exceeding packets can be marked with different MPLS experimental
values.
n Class-based Policing can mark labeled packets with MPLS experimental
values. Conforming, exceeding and violating packets can be marked with
different MPLS experimental values.
n Class-based Marking can statically mark labeled packets with an MPLS
experimental value.
Other QoS mechanisms (for example: CB-WFQ, CB-LLQ) can be used in
combination with classification that is based on the value of the MPLS
experimental bits.

Copyright  1999, Cisco Systems, Inc. Release Date: 2/1/99 23-23
© 2001, Cisco Systems, Inc. IP QoS IP over MPLS
Configuring CB-WFQ for MPLS
Configuring CB-WFQ for MPLS
match mpls experimental exp
match mpls experimental exp
Router(config-cmap)#
• Classifies packets based on MPLS experimental bits
class-map match-any Gold
match ip precedence 3 4

match mpls experimental 3 4
!
class-map match-any Silver
match ip precedence 1 2
match mpls experimental 1 2
!
policy-map IP+MPLS
class Gold
bandwidth 3000
class Silver
bandwidth 1000
!
Interface Ethernet0/0
ip address 10.1.1.1 255.255.255.0
mpls ip
service-policy output IP+MPLS
!
class-map match-any Gold
match ip precedence 3 4
match mpls experimental 3 4
!
class-map match-any Silver
match ip precedence 1 2
match mpls experimental 1 2
!
policy-map IP+MPLS
class Gold
bandwidth 3000
class Silver
bandwidth 1000

!
Interface Ethernet0/0
ip address 10.1.1.1 255.255.255.0
mpls ip
service-policy output IP+MPLS
!

Classification based on MPLS experimental bits is performed by using the match
mpls experimental command in the class-map configuration mode. Up to eight
values can be used within one class map.
The sample configuration shows a generic class map using the match-any
classification strategy to classify IP packets and labeled packets with the same IP
precedence or MPLS experimental value.


23-24 World Wide Training Word Templates v1 Copyright  1999, Cisco Systems, Inc.
© 2001, Cisco Systems, Inc. IP QoS IP over MPLS
CAR Diagram
CAR Diagram
Meter
Meter
Conforms?
Conforms?
Set IP prec?
Set IP prec?
Set DSCP?
Set DSCP?
Set MPLS exp?
Set MPLS exp?
Set QoS grp?

Set QoS grp?
Mark?
Mark?
Transmit?
Transmit?
Conform or exceed
marking value
Set IP Precedence
Set IP Precedence
Set DSCP
Set DSCP
Set MPLS Experimental
Set MPLS Experimental
Set QoS Group
Set QoS Group
Continue?
Continue?
Yes
Yes
No
No
Forward
or
Enqueue
Go to
Next
CAR command
• Marking depends on whether the packet conforms to
or exceeds the policy
Yes

Yes
Yes
Yes
Drop
Drop

Committed Access Rate (CAR) can be used to differentially mark packets based
on the arrival rate of packets within the selected class. If a packet conforms (is
within contract) it is marked with one value, if it exceeds it is marked with a
different value.
CAR also supports recursive processing of packets. One packet can be processed
by multiple rate-limit commands.

Copyright  1999, Cisco Systems, Inc. Release Date: 2/1/99 23-25
© 2001, Cisco Systems, Inc. IP QoS IP over MPLS
Configuring CAR for MPLS
Configuring CAR for MPLS
rate-limit {input | output} {access-group rate-limit acl} rate B
C
B
E
conform-act {set-mpls-exp-transmit exp | set-mpls-exp-continue exp}
exceed-act {set-mpls-exp-transmit exp | set-mpls-exp-continue exp}
rate-limit {input | output} {access-group rate-limit acl} rate B
C
B
E
conform-act {set-mpls-exp-transmit exp | set-mpls-exp-continue exp}
exceed-act {set-mpls-exp-transmit exp | set-mpls-exp-continue exp}
Router(config-if)#

• CAR can mark MPLS packets based on their arrival rate
• CAR supports recursive processing of rate-limit commands
• CAR supports classification based on MPLS experimental bit values by
using rate-limit access list
• Both conform and exceed actions support other actions: transmit,
continue, drop, set-prec-transmit, set-prec-continue, …
interface Serial0/0
ip address 10.1.1.1 255.255.255.252
rate-limit input 64000 2000 2000 conform set-mpls-exp-tr 5 exceed set-
mpls-exp-tr 0
rate-limit output 64000 2000 2000 conform set-mpls-exp-tr 5 exceed set-
mpls-exp-tr 0
!
interface Serial0/0
ip address 10.1.1.1 255.255.255.252
rate-limit input 64000 2000 2000 conform set-mpls-exp-tr 5 exceed set-
mpls-exp-tr 0
rate-limit output 64000 2000 2000 conform set-mpls-exp-tr 5 exceed set-
mpls-exp-tr 0
!

CAR also supports a special rate-limit access list that can match labeled packets
based on their MPLS experimental values.
The action options include the two that can set MPLS experimental values:
n set-mpls-exp-continue: sets the MPLS experimental bits (0 to 7) and
evaluates the next rate-limit command.
n set-mpls-exp-transmit: set the MPLS experimental bits (0 to 7) and
transmits the packet.


Tài liệu bạn tìm kiếm đã sẵn sàng tải về

Tải bản đầy đủ ngay
×