Rick Gallagher's MPLS Training Guide: Building Multi-Protocol LabelSwitching Networks by Rick Gallaher ISBN:1932266003 Syngress Publishing © 2003301 pages This book introduces readers t
Trang 1Rick Gallagher's MPLS Training Guide: Building Multi-Protocol Label
Switching Networks
by Rick Gallaher
ISBN:1932266003
Syngress Publishing © 2003(301 pages)
This book introduces readers
to MPLS concepts, installation, migration, operation, inspection, and troubleshooting, discusses specific router and switch platforms, cell mode MPLS, traffic engineering, and more.
Table of Contents
Rick Gallaher's MPLS Training Guide— Building Multi Protocol Label Switching Networks
Acknowledgments
Foreword
Chapter 1
-The Fundamentals of MPLS Networks and Data Flow
Chapter 2 - MPLS Label Distribution
Trang 3Many large to mid-size enterprise and private networks are examining the benefits of MPLS The biggest
benefit of migrating to MPLS is the savings that it
promises through convergence and additional services MPLS offers the ability to construct a scalable network that can handle data, voice, and video conferencing The cry from CTOs around the world has been for
converged networks: one infrastructure, one bill Rick Gallaher’s MPLS Training Guide will provide you with a
broadly based, multi-vendor view of MPLS.
Learn the Fundamentals of MPLS Networks:
Understand MPLS and MPLS network construction and learn about data flow in MPLS networks.
See How Circuit Switching By Label is Changing: Explore the methods of MPLS Label Distribution: static routing and dynamic signaling and label
Protect Your Network and Ensure Rapid Recovery: Get an introduction to MPLS Network Reliance and Recovery, including coverage of Cisco’s Tunnel
Builder Vendor Solution.
Calculate How Much Bandwidth You Need:
Understand the four aspects of traffic engineering and see how to use bandwidth provisioning and
Trang 4Review the Framework of Generalized Multiprotocol Label Switching (GMPLS): Prepare for the future of your network using GMPLS for centralized control, automatic provisioning, load balancing, bandwidth
on demand, and more.
Prepare an MPLS VPN Solution: Use MPLS VPNs to provide a flexible VPN solution to service providers and ISPs.
Monitor and Police QoS Problems: Measure, mark, and police packets in a data network and measure QoS by monitoring latency, jitter, and dropped
packets.
About the Author
Rick Gallaher began his career in telecommunications
as an international satellite communications engineer His extensive career experience spans the
telecommunications gamut from field technician to
consulting engineer Using his background in both voice and data communication, he has delivered training
around the world for government agencies and Fortune
500 companies Rick has published several articles for
a variety of technical journals and periodicals on MPLS, VoIP, WiFi, and QoS; these articles networking have been widely read and referenced by international
scholars, industry white papers, and government
publications As the Founder and CEO of
Telecommunications Technical Services, Inc., he is a highly respected business strategist, technical
consultant, and entrepreneur.
Trang 6Rick Gallaher's MPLS Training Guide—Building Multi Protocol Label Switching Networks
Rick Gallaher
Syngress Publishing, Inc., the author(s), and any person or firm involved
in the writing, editing, or production (collectively “Makers”) of this book(“the Work”) do not guarantee or warrant the results to be obtained fromthe Work
There is no guarantee of any kind, expressed or implied, regarding theWork or its contents The Work is sold AS IS and WITHOUT
WARRANTY You may have other legal rights, which vary from state tostate
In no event will Makers be liable to you for damages, including any loss
of profits, lost savings, or other incidental or consequential damagesarising out from the Work or its contents Because some states do notallow the exclusion or limitation of liability for consequential or incidentaldamages, the above limitation may not apply to you
You should always use reasonable care, including backup and otherappropriate precautions, when working with computers, networks, data,and files
Syngress Media®, Syngress®, “Career Advancement Through Skill
Enhancement®,” “Ask the Author UPDATE®,” and “Hack Proofing®,” areregistered trademarks of Syngress Publishing, Inc “Syngress: The
Definition of a Serious Security Library”™, “Mission Critical™,” and “TheOnly Way to Stop a Hacker is to Think Like One™” are trademarks ofSyngress Publishing, Inc Brands and product names mentioned in thisbook are trademarks or service marks of their respective companies
Trang 7Printed in the United States of America Except as permitted under theCopyright Act of 1976, no part of this publication may be reproduced ordistributed in any form or by any means, or stored in a database or
retrieval system, without the prior written permission of the publisher, withthe exception that the program listings may be entered, stored, and
Trang 8Distributed by Publishers Group West in the United States and JaguarBook Group in Canada
About the Author
Rick Gallaher began his career in telecommunications as an
international satellite communications engineer His extensive careerexperience spans the telecommunications gamut from field technician toconsulting engineer Using his background in both voice and data
communication, he has delivered training around the world for
government agencies and Fortune 500 companies Rick has publishedseveral articles for a variety of technical journals and periodicals on
MPLS, VoIP, WiFi, and QoS; these articles networking have been widelyread and referenced by international scholars, industry white papers, andgovernment publications As the Founder and CEO of
Telecommunications Technical Services, Inc., he is a highly respectedbusiness strategist, technical consultant, and entrepreneur Rick proudlyhales from the University of Alabama
Author Acknowledgments
I would like to thank my family and friends that made the production ofthe book possible I dedicate this book to my family – Susan, David,
Drew, Benjamin, and Daniel - who contributed much to this book and to
my other publications
There have been many books written on the subject of MPLS This book
is not intended as a substitute for the scholarly works written by manytalented engineers It is offered as a supplement for those who need amore basic understanding of MPLS that allows them to see fundamentalMPLS operations and configurations while offering practical applications
of the technology
vendor book including:
I would like to thank all the vendors that assisted me in compiling a multi-The MPLS working groups and MPLS list server
Trang 9Elizabeth Swanson, Vertical Systems
Trang 10We would like to acknowledge the following people for their kindness andsupport in making this book possible
Ralph Troupe, Rhonda St John, Emlyn Rhodes, and the team at
Callisma for their invaluable insight into the challenges of designing,deploying and supporting world-class enterprise networks
Karen Cross, Lance Tilford, Meaghan Cunningham, Kim Wylie, HarryKirchner, Kevin Votel, Kent Anderson, Frida Yara, Jon Mayes, John
Mesjak, Peg O’Donnell, Sandra Patterson, Betty Redmond, Roy Remer,Ron Shapiro, Patricia Kelly, Andrea Tetrick, Jennifer Pascal, Doug Reil,David Dahl, Janis Carpenter, and Susan Fryer of Publishers Group Westfor sharing their incredible marketing experience and expertise
Duncan Enright, AnnHelen Lindeholm, David Burton, Febea Marinetti,and Rosie Moss of Elsevier Science for making certain that our visionremains worldwide in scope
David Buckland, Wendi Wong, Daniel Loh, Marie Chieng, Lucy Chong,Leslie Lim, Audrey Gan, and Joseph Chan of Transquest Publishers forthe enthusiasm with which they receive our books
Kwon Sung June at Acorn Publishing for his support
Jackie Gross, Gayle Voycey, Alexia Penny, Anik Robitaille, Craig Siddall,Darlene Morrow, Iolanda Miller, Jane Mackay, and Marie Skelly at JackieGross & Associates for all their help and enthusiasm representing ourproduct in Canada
Lois Fraser, Connie McMenemy, Shannon Russell, and the rest of thegreat folks at Jaguar Book Group for their help with distribution of
Syngress books in Canada
David Scott, Annette Scott, Delta Sams, Geoff Ebbs, Hedley Partis, andTricia Herbert of Woodslane for distributing our books throughout
Australia, New Zealand, Papua New Guinea, Fiji Tonga, Solomon
Trang 11Islands, and the Cook Islands.
Trang 12The state of Multiple Protocol Label Switching (MPLS) is healthy andrevenue-ready—such are the indications from the largest MPLS test lab
to date MPLS is healthy, but as of this writing, the economy is not Theslowing of the economy, however, only serves to allow MPLS to develop
Large to mid-size Enterprise and private networks are examining thebenefits and exploring the options of MPLS The biggest benefit of
migrating to MPLS is the savings that it promises through convergenceand additional services MPLS offers the ability to construct a scalablenetwork that can handle data, voice, and video conferencing
The cry from CTOs around the world has been for converged networks:one infrastructure, one bill
Training is a significant challenge facing MPLS Everyone that has
deployed MPLS says the same thing: “Do not underestimate the need fortraining.” As we examined this area, we found that there is a place
between IP networks and vendor manuals in which there exists a needfor sound theory This book attempts to bridge that gap
In the community of computer science, there are many subcultures thatare separated by their own language sets; the same is true with the rise
of MPLS Much of the misunderstanding that takes place in networking is
a problem with language We hope that this book will help to removesome of the barriers to understanding that surround MPLS, and also givethe reader a sound foundation for further MPLS studies This book can
be read or studied as either a self-paced course or a classroom resource
We worked with pre-eminent MPLS vendors in order to give the reader a
Trang 13documents to support a multi-vendor study guide
Trang 14This book is arranged to build both a foundational knowledge of MPLSand an understanding of related specialty subjects Chapters 1-3 (MPLSFundamentals and Data Flow, Label Distribution, and Signaling,
respectively) are foundational chapters These are supplemented withchapters devoted to specialty subjects, including Rapid Recovery, TrafficEngineering, GMPLS, VPN, QoS, and MPLS Marketing After completing
Chapters 1-3, the specialty chapters can be completed in any order.Most of the chapters are arranged to encompass theory, practical
applications, and learning exercises A vocabulary block precedes eachchapter for quick referencing Periodic checkpoints and reviews are
provided to reinforce the learning experience
For a quick overview, one can choose to study only the theory-basedportion of a chapter For more details, one can review the vendor
examples and practical examples given in that chapter For maximumdetail, one can complete the practical exercises and answer review
Trang 15Chapter 1: The Fundamentals of MPLS Networks and Data Flow
Trang 16In this chapter, we examine the basic components of MPLS networks
We undertake an exploration of data transport, equipment functions, andprocedures that help make this emerging protocol an exciting and pivotalforce in the world of telecommunications The lessons in this chapter arefortified with examples, applications, hands-on exercises, and links tovaluable MPLS resources
Trang 17mailroom has been under orders to send all intercampus correspondencevia standard first-class mail The cost of this postage is calculated intothe company’s operational budget
However, some departments have been complaining for several monthsthat they require overnight delivery and package-tracking services As amanager, you establish a system to send three levels of mail betweencampuses: first-class (normal) mail, priority (important) mail, and expressmail (urgent) In order to offset the increased expense of the new
services, you bill the departments that use these premium services at theregular rate of postage, plus 10 percent
In this analogy, units of priority mail and express mail are processed byway of placement into specific envelopes with distinctive labels Thesespecial labels and packets assure both prioritized handling and trackingcapability within the postal network In order to avoid slowdowns andbottlenecks, the postal facilities in the network create a system that usessorting tables or sorting databases to identify and expedite these
packets
Trang 18In an IP network, you can think of routers as post offices or postal sortingstations Without a means to mark, classify, and monitor mail, there
would be no way to process different classes of mail In IP networks, youfind a similar situation Figure 1.1 shows a typical IP network with traffichaving no specified route
Figure 1.1: IP Network
In order to designate different classes of service or service priorities,traffic must be marked with special labels as it enters the network Aspecial router called a label edge router (LER) provides this labelingfunction (see Figure 1.2) The LER converts both IP packets into MPLSpackets and MPLS packets into IP packets On the ingress side, the LERexamines the incoming packet to determine whether the packet should
be labeled A special database in the LER matches the destination
address to the label An MPLS shim header, as shown in Figure 1.2, isattached, and the packet is sent on its way
Trang 19
Figure 1.3: MPLS Shim Header and Format
The shim header (c) consists 32 bits in four parts; 20 bits are used for the
Trang 202 protocol) and IP (a Layer 3 protocol)
In order to route traffic across the network once labels have been
attached, the non-edge routers serve as label switch routers (LSRs).
Note that these devices are still routers Packet analysis determineswhether they serve as MPLS switches or routers
The function of the LSR is to examine incoming packets Provided that alabel is present, the LSR will look up and follow the label instructions andthen forward the packet according to the instructions In general, the LSRperforms a label-swapping function Figure 1.4 shows LSRs within anetwork
characteristics can include peak-traffic load, interpacket variation, anddropped-packet percentage calculation
Figure 1.5 shows the LSP established between MPLS-aware devices.Because MPLS works as an overlay protocol to IP, the two protocols can
Trang 21
Figure 1.5: Label Switch Paths
Trang 22Port Out
192.168.10.0-
Trang 23Protocol
255
192.168.10.0-
3 Describe a circumstance in which HTTPS should be handled differently from
Trang 244 What FEC classification is given to routing?
5 How could giving the above classification to routing become a problem? Answers
4 Routing is classified as FEC Z (which is the lowest FEC rating).
5 Routing and label distribution should be given the highest
priority in the network; otherwise, packets could be misrouted.
Trang 25In this exercise, we saw the manner in which granularity of services
affects the length of a switching table The more decision points, or themore granular the decision points, the longer the switching tables and themore complex that switching becomes
There are several key components to the construction of an MPLS
network The LER adds and/or removes (“pops” or “pushes”) labels TheLSR examines packets, swaps labels, and forwards packets Finally, theLSPs are the preassigned, preengineered paths that MPLS packets
could take
At this point, you might be asking whether the advantages of MPLS areworth the extra effort needed to understanding its workings Consider thefollowing for yourself:
Your company uses a database application that is intolerant of packetloss or jitter In order to ensure that your prime traffic will get through, youhave secured a high-cost circuit, and you have overprovisioned that
circuit by 60 percent In other words, you are sending all of your mail as
“express mail”—for $13.50 per packet!
With MPLS, you can have the LER sort your packets and place only yourhighest-priority traffic on the most expensive circuits while allowing yourroutine traffic to take other paths You have the ability to classify traffic inMPLS terms, and your LER sorts traffic into FECs Figure 1.6 shows thenetwork now broken down into FECs
Trang 26Figure 1.6: MPLS Network with Two FECs
Trang 27The simplest form of data “flow” occurs when IP packets are presented tothe ingress router, which is acting as the LER (see Figure 1.7)
Figure 1.7: Ingress LER Attaches a Shim Header
Much like the sorting room at your postal service’s branch location thatclassifies mail into service grades of first-class, priority, or express, theLER classifies incoming IP traffic, relating it to the appropriate label As
we’ve seen, in MPLS this classification process is called forward
equivalence class (FEC).
LERs use several different modes to label traffic In the simplest
example, the IP packets are “nailed up” to both a label and an FEC usingpreprogrammed tables, such as the example shown in Table 1.2
Trang 28199.50.5.1 25 IP 100.5.1.100 (Donothing;
native IP)
When the MPLS packets leave the LER, they are destined for the LSR,where they are examined for the presence of labels The LSR looks to its
forwarding table—called a label information base (LIB) or connectivity table—for instructions The LSR will swap labels according to LIB
instructions Table 1.3 shows an example of a LIB
Trang 29The LER performs many packet-analysis functions: mapping Layer 2 toMPLS, mapping MPLS to Layer 3, and classifying traffic with great
granularity In addition, the LER decides which packets of the traffic
become MPLS packets
One decision-making method is called triggered mode Using this
method, a router will determine that there is a “traffic stream” when apredetermined number of packets are addressed to a single location andare scheduled to arrive within a specified timeframe Once the router hasmade this determination, it will then reroute the stream of traffic for MPLSprocessing
Even further enhancements and flexibility are available to MPLS usingthe label-stacking method, as shown in Figure 1.9
Figure 1.9: Stacked Labels with Tunneled Network
Consider the following scenario You own Network 1; however, your trafficmust proceed across Network 2, a network that is not owned by yourcompany You must ensure that Network 2 handles your traffic according
to your service-level agreement (SLA), but Network 2’s owners are notusing the same label criteria as your company
In this case, you would stack labels and build a tunnel across Network 2
Trang 30This configuration would preserve the integrity of your network’s labelswhile allowing the other network to operate independently.
Trang 31Now that you have seen how data “flows” in an MPLS network, it is time
to look at some practical implementations of MPLS and some of the
commands that could be useful to you Of course, different vendors mayuse different commands, but this section provides some examples
Label Numbers
The first part of these applications relates to label numbers and how theyare used or reserved The MPLS standard reserves labels 0–15 for
defined uses This leaves labels 16–1,048,575 open for use
Manufacturers differ on how these labels are assigned For example, onevendor (Juniper) uses labels 16–1023 for manual LDP connections andconfiguration, while labels 1024–99,999 are stored for future use Thatleaves labels 100,000–1,048,575, which can be assigned by the systemautomatically
All manufacturers reserve labels 0–15, but they divide their labels
differently This does not affect interoperability, because labels are
negotiated when an LDP is established If a label is requested, then itcannot be used until another label is assigned
MPLS Commands
With other routers (such as Cisco), you can assign a label range with asimple command figure, as shown in Figure 1.10
Trang 32
The next useful practical command involves seeing the forwarding tables.Cisco’s example is shown in Figure 1.11
Figure 1.11: MPLS Forwarding Table Commands
Trang 33We find in an MPLS network that data moves from switch to switch usinglink-specific labels Switches perform functions based on their switching
or cross-connect tables
These tables contain information such as port in, label in, port out, labelout, next router, and instructions The instructions are simple: 'push'(insert a label), 'swap' (change labels), and 'pop' (remove label)
In this exercise, sample tracing of a packet through an MPLS network,five routers R1-R5 connect networks X and Z Tables 1.4-1.8 are used todiscover the LSPs Table 1.4 is used for Router 1, Table 1.5 is used forRouter 2, Table 1.6 is used for Router 3, Table 1.7 is used for Router 4,and Table 1.8 is used for Router 5 Each table is different and representsthe MPLS routers internal switching table
In Figure 1.12, we have an example of how data would move in thissituation
In Table 1.4, the packet (being HTTP port 80) enters as native IP/80where a label (20) is pushed and the packet is sent out of port D Noticethat as the packet traverses the network, it exits Router 1 at port D andenters Router 3 at port B
In Table 1.6, the label (20) is swapped for label 600, and the packet exitsthe router at port D, where it is hardwired to port B of R5
In Table 1.8 (R5), the packet label 600 is popped to deliver a native
Trang 341 Always start with Table 1.4 and follow applications that enterthrough Interface A.
Table 1.4: Switching Table for Router 1
P_In Label In Label
Out Port Out Instruction
Next Router
2 The decision made by Table 1.4 will lead you to another
switching table, depending on the application, port out, and therouter out
3 In Figure 1.12, note that the packet label numbers appear onthe drawings Use Figures 1.13 and 1.14 to indicate the correctlabel number
Trang 35Figure 1.13: Network Trace for Port 25 E-Mail
Table 1.5: Switching Table for Router 2
P_In Label In Label
Out Port Out Instruction
Next Router
Table 1.6: Switching Table for Router 3
P_In Label In Label
Out Port Out Instruction
Next Router
Trang 36Figure 1.14: Network Trace for Port 20
FTP
Table 1.7: Switching Table for Router 4
P_In Label In Label
Out Port Out Instruction
Next Router
Table 1.8: Switching Table for Router 5
P_In Label In Label
Out Port Out Instruction
Next Router
Trang 37There are several ways to complete this lab The exercise itself is written
in standalone form so that you do not need any products to complete theexercises Just skip the hands-on block that follows
Trang 38Hands-On: Compare and Contrast IP/Ethernet and IP/MPLS/Ethernet
If this is the only protocol analyzer present on your computer, you can
open the file called MPLS_basic by clicking it If you have another
protocol analyzer, you have to open the Ethereal program and open thefile from the menu
1 click Ethereal.
1 Look at Frame 1 in Figure 1.15 What is the value at offset 12
and 13?
Trang 404 00 1 1 f
Translate the hex number into binary using the chart below