MPLS Cheat sheet

Notes taken from MPLS, writups by Peter J. Welcher, the Cisco MPLS FAQ for beginners, - 9/28/2005 and MPLS Configuration on IOS Software by Umesh Lakshman.

Table of Contents


MPLS allows for VPNs, Traffic Engineering (TE), QoS, ATM over MPLS (AToM). Additionally, in decreases forwarding overhead on the core routers.

Acronyms


Label Structure

 0                   1                   2                   3
 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 
|                  Label                | Exp |S|      TTL      |

Label Values

0 through 2^20 - 1.
0-15 reserved; 4-15 reserved for future use.
 0 IPv4 Explicit NULL Label. Label indicates that label stack must be popped, and packet forwarding must be based on IPv4 header. Useful in keeping Exp bits safe until egress router. Used in MPLS based QoS.
 1 Router Alert Label. When at top of label stack, packet delivered to local software module for processing. Actual packet forwarding determined by the label beneath it in the stack. If packet is forwarded further, Router Alert Label should be pushed back onto label stack before forwarding. Use of this label is analogous to use of "Router Alert Option" in IP packets (for example, ping with record route option
 2 IPv6 Explicit NULL Label. Indicates that stack must be popped, and packet forwarding must be based on IPv6 header.
 3 Implicit NULL Label. Indicates that LSR will pop top label from stack and forward rest of packet (labeled or unlabled) through outgoing interface (per LIB). Value never appears in encapsulation, but needs to be specified in LDP, so value is reserved.

LDP/CDP

QoS

Label determines LSRs outbound interface and label via LIB, but precedence or EXP field is used to determine queuing treatment. Cisco only has 4 queues by default(?).

Traffic Engineering

Use unidirectional tunnels to shift traffic off one path and onto another. Can be static or Automatic.

VPNs

network implemented using shared net infrastructure but so as to provide security and privacy of a private leased line network.

Ethertypes for MPLS

MPLS Control Packet (MPLSCP) for PPP0x8281
PPP Unicast0x0281
PPP Multicast0x0283
LAN Unicast0x8847
Lan Multicast0x8848

Cisco config and statements

Global MPLS Config
mpls ip                       (global or interface level)
mpls label protocol ldp|tdp   (ldp is standardized)
                              (global or interface level)
mpls ldp router-id loopback 0 (ties to loopback 0)

int <interface>            
 ip addr <ipaddr>
 mpls ip                      (possibly need this)
 tag-switching ip             (alternate form of mpls ip - don't need both)
 
Interface-Level MPLS Config
interface ethernet 0
 mpls ip
 mpls mtu <sizeInBytes>      (should be IP MTU +(4 * max num of labels))

Cell-Mode Interface Config
int atm 3/0
 no ip address
 no atm ilmi-keepalive
int atm 3/0.1 mpls
 ip address <ipaddr> <netmask>
 mpls ip
 mpls ldp address-message
mpls ldp atm contro|vcmerge

assign lp router id
mpls ldp router-id loopback 0

Configuring LDP Params
mpls ldp discovery hello holdtime <seconds>
mpls ldp discovery hello interval <seconds>

Configuring CEF
ip cef distributed           (only on dist platfrms - 12000 or 7500, not 7200)
sh ip interface <interface>  (to show that CEF is enable)
sh ip cef summary            (show stats, whether running in distributed mode)

Configuring OSPF
router ospf 100
 network 10.10.10.0 0.0.0.255 area 0

General Show Commands
sh mpls interfaces
sh mpls ldp discovery        Verify status of LDP discovery process
sh mpls ldp neighbor

sh mpls forwarding <ipaddr> detail
                             (label stack info)
sh ip cef <ipaddr> internal  (IP to IP, IP to MPLS)
                             (if entry indicates tags imposed - it's mpls)
                             (shows mpls or routing path frame/cell will take)
sh mpls forwarding-table     (MPLS to MPLS, MPLS to IP)
sh mpls ip bindings <addr>   (shows LIB (label info base - populated by LDP or TDP))
                             (only next hop rtrs make it from LIB to fwd table)
show mpls ldp bindings
sh mpls ldp discovery        (shows if hellos are being sent and received)
sh mpls ldp neighbor
sh mpls ldp parameters
sh mpls interfaces [detail]