dipartimento di informatica e sistemisticabecchett/reti2/slide/17_mpls.pdf · perform forwarding of...
TRANSCRIPT
Dipartimento di Informatica e Sistemistica
Luca Becchetti
A.A. 2008/2009
RETI DI CALCOLATORI IIMulti Protocol Label Switching
(MPLS)
Luca BecchettiLuca Becchetti –– Computer NetworksComputer Networks II, A.A. 2008/2009 II, A.A. 2008/2009
Label Switching 1/4
Software-based forwarding
IP Router
Connectionless environment
Use of explicit addresses
Search in routing tables
Limited performance
Hardware-based forwarding
Label switching
Connection oriented environment
Flow identification --> use of labels
Direct access to routing tables
High performance
Luca BecchettiLuca Becchetti –– Computer NetworksComputer Networks II, A.A. 2008/2009 II, A.A. 2008/2009
Label Switching 2/4
Forwarding Equivalent Class (FEC)
An aggregate of packets directed towards the same destination andwhich have to receive the same service in the network
FECs identify packet flows
different priorities
different services
different QoS level requirements
Label
identifies FEC to which a packet belongs
Constant and short length [hardware switching]
Local validity (limited to a subpart of packet path towards destination)
Luca BecchettiLuca Becchetti –– Computer NetworksComputer Networks II, A.A. 2008/2009 II, A.A. 2008/2009
Label Switching 3/4
Switching (forwarding in IP jargon) occurs based only on label
A Label Switching Router
Inspects label associated to incoming packet
Finds output port
Changes old label to new value valid on outlink (label swapping)
Forwards packet to output port
Reduces routing table size
Number of entries in the order of number of different FECs onincoming links
Luca BecchettiLuca Becchetti –– Computer NetworksComputer Networks II, A.A. 2008/2009 II, A.A. 2008/2009
Label Switching 4/4
Direct access to routing table
(port, label) pair determines function to apply to label
Pushing (assignment)
Swapping (label change)
Popping (label disposal)
(port, label) pair determines output port (port, label)
Luca BecchettiLuca Becchetti –– Computer NetworksComputer Networks II, A.A. 2008/2009 II, A.A. 2008/2009
Label allocation 1/2
Binding
Assign label to a FEC
Necessary to notify assignment to all routers on the path followed bypackets belonging to FEC (Label Distribution Protocol)
Assignment normally based on destination prefix and required QoSlevel
Local binding
Assignment of a label to a FEC, autonomously done by a router
Remote binding
Assignment of a label to a FEC done by a remote router andcommunicated to this router using signalling
Luca BecchettiLuca Becchetti –– Computer NetworksComputer Networks II, A.A. 2008/2009 II, A.A. 2008/2009
Label allocation 2/2
Control binding
FEC definition and label assignment done before packet sending ofpackets
Call set up phase necessary
Label distribution done by
signalling protocol (Label Distribution Protocol)
router configuration (static provisioning)
Data driven binding
FEC determined by data flow analysis
Label assignment starts at router that determines FEC
Label distribution signalling protocol (Label Distribution Protocol)
Dynamic environment
Luca BecchettiLuca Becchetti –– Computer NetworksComputer Networks II, A.A. 2008/2009 II, A.A. 2008/2009
Label allocation:example
Luca BecchettiLuca Becchetti –– Computer NetworksComputer Networks II, A.A. 2008/2009 II, A.A. 2008/2009
Label switching example
Luca BecchettiLuca Becchetti –– Computer NetworksComputer Networks II, A.A. 2008/2009 II, A.A. 2008/2009
Multi Protocol Label Switching 1/2
Goals
Improve performance and scalability of IP routing
Separate control (routing) and transport (forwarding) functionalities soas to make them independent
One single transpost mechanism suitable to a multiplicity of differentprotocols
Make explicit routing and traffic engineering possible
Defined by IETF since 1997 (RFCs 3031,3032)
Luca BecchettiLuca Becchetti –– Computer NetworksComputer Networks II, A.A. 2008/2009 II, A.A. 2008/2009
Multi Protocol Label Switching 2/2
Traffic Engineering – TE is the set of funcionalities aimed at optimizingnetwork performance (RFC 2702)
Tools used in traffic engineering
traffic measurement
traffic modelling
traffic characteristics
traffic control
Defined by IETF since 1997 (RFCs 3031,3032)
Luca BecchettiLuca Becchetti –– Computer NetworksComputer Networks II, A.A. 2008/2009 II, A.A. 2008/2009
MPLS terminology 1/5
Label Switched Path (LSP)
Path followed by a given FEC when traversing an MPLS domain
Concatenation of a number of subpaths based on label switching
May be viewed as a tunnel used by IP datagrams
Luca BecchettiLuca Becchetti –– Computer NetworksComputer Networks II, A.A. 2008/2009 II, A.A. 2008/2009
MPLS Terminology 2/5
Label Switching Router (LSR)
Perform forwarding of MPLS packets and implement full IPfunctionalities
Implement MPLS protocols (e.g., label allocation)
Luca BecchettiLuca Becchetti –– Computer NetworksComputer Networks II, A.A. 2008/2009 II, A.A. 2008/2009
MPLS Terminology 3/5
Ingress LSR
Router where an LSP starts
Processes traffic entering MPLS domain
Classifies incoming IP packets into suitable FEC
Generates labels and builds MPLS packets
Luca BecchettiLuca Becchetti –– Computer NetworksComputer Networks II, A.A. 2008/2009 II, A.A. 2008/2009
MPLS Terminology 4/5
Transit LSR
Intermediate router within an LSP
Process internal traffic within an MPLS domain
Performs MPLS packet forwarding and in particular label processing
Luca BecchettiLuca Becchetti –– Computer NetworksComputer Networks II, A.A. 2008/2009 II, A.A. 2008/2009
Terminologia MPLS 5/5
Egress LSR
Last router along an LSP
Processes traffic leaving MPLS domain
Removes MPLS labels and extracts IP datagrams
Luca BecchettiLuca Becchetti –– Computer NetworksComputer Networks II, A.A. 2008/2009 II, A.A. 2008/2009
Label Distribution Protocol (LDP)
Set of procedures through which an LSR communicates to another LSRthe binding between labels and FECs
Two LSR communicating by the Label Distribution Protocol are said LabelDistribution Peers
MPLS does not impose use of a specific Label Distribution Protocol
Protocol proposals:
BGP (extension)
RSVP (extension)
MPLS-LDP
CR-LDP
Luca BecchettiLuca Becchetti –– Computer NetworksComputer Networks II, A.A. 2008/2009 II, A.A. 2008/2009
Label allocation 1/2
MPLS two label allocation policies
Independent Control
Ordered Control
Independent Control
Every LSR assigns and distributes labels independently of other LSRsin request to advertising of prefixes by IGP protocol
Assumes agreement between LSRs about FECs used in the network
Ordered Control
Label allocation and distribution occurs according to predefined orderamong LSRs along every LSP
Slower than independent control, but it allows higher control of theoperator over the network
Luca BecchettiLuca Becchetti –– Computer NetworksComputer Networks II, A.A. 2008/2009 II, A.A. 2008/2009
Allocazione delle label 2/2
Downstream binding
Assignment of label to a FEC is done by downstream LSR accordingto traffic direction
Downstream On Demand
An LSR receives a request for the allocation of a label fromdownstream LSR
Unsolicited Downstream
Label distribution even without explicit request
Traffic direction
Luca BecchettiLuca Becchetti –– Computer NetworksComputer Networks II, A.A. 2008/2009 II, A.A. 2008/2009
Label stack
An MPLS packet may carrydifferent labels
An LSR processesalways and only mostexternal label
Applications
Routing hierarchy
Aggregation ofindividual LSPs into“trunk” LSP
Virtual Private Networks(VPNs)
Luca BecchettiLuca Becchetti –– Computer NetworksComputer Networks II, A.A. 2008/2009 II, A.A. 2008/2009
Label stack example
Luca BecchettiLuca Becchetti –– Computer NetworksComputer Networks II, A.A. 2008/2009 II, A.A. 2008/2009
Forwarding table
One record in a forwarding table (Next Hop label Forwarding Entry -NHLFE) at an LSR contains
Output port to which packet should be forwarded (next hop)
Operation to perform on incoming label
Label swapping
o Conversion of valid external label on incoming link into validlable on outbound link
Label popping
o Removal of external label
Label pushing
o Insertion of a new label on top of label stack
Label swapping and label pushing operations may be performed onthe same packet by the same LSR
Luca BecchettiLuca Becchetti –– Computer NetworksComputer Networks II, A.A. 2008/2009 II, A.A. 2008/2009
FEC - prefix association
It is possible to create
Distinct FECs for every destination prefix
Aggregate FECs for a set of destination prefixes (Aggregation)
Prefix aggregation in the same FEC reduces number of labels and amountof signalling traffic
Luca BecchettiLuca Becchetti –– Computer NetworksComputer Networks II, A.A. 2008/2009 II, A.A. 2008/2009
Label merging
Packets with different entry labels to an LSR may be associated to thesame exit label
Luca BecchettiLuca Becchetti –– Computer NetworksComputer Networks II, A.A. 2008/2009 II, A.A. 2008/2009
MPLS routing
Hop-by-hop routing
An LSR chooses next hop of LSP independently of other LSPs
Classical IP approach
Explicit routing
Strictly explicit routing
all LSRs traversed by LSP specified
Loosely explicit routing
only part of LSRs traversed by LSP specified
On-line: Constraint Based Routing (CBR)
Off-line: planning algorithms
Used to support traffic engineering
Luca BecchettiLuca Becchetti –– Computer NetworksComputer Networks II, A.A. 2008/2009 II, A.A. 2008/2009
Label encoding
Label encoded as 32 bit word
Label value (20 bits)
Contains label value for a specific LSP
Experimental Use (EXP - 3 bits)
Reserved
Bottom of stack (S - 1 bit)
Indicates whether label is the most external one
Time To Live (TTL - 8 bits)
Same meaning as analogous field in IP datagram
Luca BecchettiLuca Becchetti –– Computer NetworksComputer Networks II, A.A. 2008/2009 II, A.A. 2008/2009
Example A 1/2
LSP used to carry IP datagrams directed to a specific destination address
FEC identified by prefix “X” of destination network
LSR sequence in LSP computed by IGP protocol
An LSR belongs to LSP if its table contains a single record such that“X” is the longest prefix that determines routing towards destination
Every LSR
Associates a label to “X” prefix
Uses label distribution protocol to coomunicate association to its“peer” LSR
The role of egress LSR is played by the LSR for which prefix “X” is nolonger the “longest prefix” for the destination
Luca BecchettiLuca Becchetti –– Computer NetworksComputer Networks II, A.A. 2008/2009 II, A.A. 2008/2009
Example A 2/2
Luca BecchettiLuca Becchetti –– Computer NetworksComputer Networks II, A.A. 2008/2009 II, A.A. 2008/2009
Example B 1/2
Explicit Routed LSP
Route independent from the one determined by routing protocol
Route determined by
Configuration algorithms (Off-line)
Constraint-Based routing (On-line)
Used to support traffic engineering
Luca BecchettiLuca Becchetti –– Computer NetworksComputer Networks II, A.A. 2008/2009 II, A.A. 2008/2009
Example B 2/2
Luca BecchettiLuca Becchetti –– Computer NetworksComputer Networks II, A.A. 2008/2009 II, A.A. 2008/2009
Example C 1/4
Luca BecchettiLuca Becchetti –– Computer NetworksComputer Networks II, A.A. 2008/2009 II, A.A. 2008/2009
Example C 2/4
Luca BecchettiLuca Becchetti –– Computer NetworksComputer Networks II, A.A. 2008/2009 II, A.A. 2008/2009
Example C 3/4
Luca BecchettiLuca Becchetti –– Computer NetworksComputer Networks II, A.A. 2008/2009 II, A.A. 2008/2009
Example C 4/4