Thursday, December 4, 2014

Enable MPLS and configure LDP on Cisco Router.

Aim : Enable MPLS and configure LDP on Cisco Router.

In this tutorial:
  • Enable MPLS on Cisco 7200
  • Configure LDP
  • Verify the label generation and mapping using show cmd.

Network diagram:



Prerequisites / Considerations
 
  • Loopback 0 interfaces are configured with x.x.x.x/32 IP address on all routers.
  • FastEthernet interfaces are configured with correct IP address on all routers.
  • OSPF is up and running and able to reach all the subnets in network diagram.
  • IOS : 12.4

Configuration on router R1

 
! ######## R1 ########
config t

! Step 1 : Enable CEF (from IOS 12.2 onwards this will enabled by default)
ip cef

! Step 2 : Enable MPLS on global configuration level
mpls ip

! Step 3 : Enable LDP for MPLS protocol
mpls label pro ldp

! Step 4 : Limit label range form 100 to 199
mpls label range 100 199

! Step 5 : Set RID = loopback 0
mpls ldp router loop 0

! Step 5 : Enable MPLS on interface level
int fa 0/0
mpls ip

! Exit out configuration menu and save changes.
end
wr

! ######## END R1 ########

Configuration on router R2

! ######## R2 ########
config t

! Step 1 : Enable CEF (from IOS 12.2 onwards this will enabled by default)
ip cef

! Step 2 : Enable MPLS on global configuration level
mpls ip

! Step 3 : Enable LDP for MPLS protocol
mpls label pro ldp

! Step 4 : Limit label range form 200 to 299
mpls label range 200 299

! Step 5 : Set RID = loopback 0
mpls ldp router loop 0

! Step 5 : Enable MPLS on interface level
int fa 0/0
mpls ip

int fa 0/1
mpls ip

! Exit out configuration menu and save changes.
end
wr

! ######## END R2 ########

Configuration on router R3

! ######## R3 ########
config t

! Step 1 : Enable CEF (from IOS 12.2 onwards this will enabled by default)
ip cef

! Step 2 : Enable MPLS on global configuration level
mpls ip

! Step 3 : Enable LDP for MPLS protocol
mpls label pro ldp

! Step 4 : Limit label range form 300 to 399
mpls label range 300 399

! Step 5 : Set RID = loopback 0
mpls ldp router loop 0

! Step 5 : Enable MPLS on interface level
int fa 0/0
mpls ip

int fa 0/1
mpls ip

! Exit out configuration menu and save changes.
end
wr

! ######## END R3 ########

Configuration on router R4

! ######## R4 ########
config t

! Step 1 : Enable CEF (from IOS 12.2 onwards this will enabled by default)
ip cef

! Step 2 : Enable MPLS on global configuration level
mpls ip

! Step 3 : Enable LDP for MPLS protocol
mpls label pro ldp

! Step 4 : Limit label range form 400 to 499
mpls label range 400 499

! Step 5 : Set RID = loopback 0
mpls ldp router loop 0

! Step 5 : Enable MPLS on interface level
int fa 0/1
mpls ip

! Exit out configuration menu and save changes.
end
wr

! ######## END R4 ########

Show cmds to verify MPLS - LDP

Note : Various show cmds are demonstrated in this section contains cmd output for router R2 only.
R2#sh ip route
Codes: C - connected, S - static, R - RIP, M - mobile, B - BGP
       D - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter area
       N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2
       E1 - OSPF external type 1, E2 - OSPF external type 2
       i - IS-IS, su - IS-IS summary, L1 - IS-IS level-1, L2 - IS-IS level-2
       ia - IS-IS inter area, * - candidate default, U - per-user static route
       o - ODR, P - periodic downloaded static route

Gateway of last resort is not set

     1.0.0.0/32 is subnetted, 1 subnets
O       1.1.1.1 [110/2] via 10.1.2.1, 00:28:57, FastEthernet0/1
     2.0.0.0/32 is subnetted, 1 subnets
C       2.2.2.2 is directly connected, Loopback0
     3.0.0.0/32 is subnetted, 1 subnets
O       3.3.3.3 [110/2] via 10.2.3.3, 00:25:20, FastEthernet0/0
     4.0.0.0/32 is subnetted, 1 subnets
O       4.4.4.4 [110/3] via 10.2.3.3, 00:24:04, FastEthernet0/0
     10.0.0.0/24 is subnetted, 3 subnets
C       10.1.2.0 is directly connected, FastEthernet0/1
C       10.2.3.0 is directly connected, FastEthernet0/0
O       10.3.4.0 [110/2] via 10.2.3.3, 00:25:20, FastEthernet0/0
R2#
R2#show mpls ldp bindings
  tib entry: 1.1.1.1/32, rev 8
        local binding:  tag: 200
        remote binding: tsr: 1.1.1.1:0, tag: imp-null
        remote binding: tsr: 3.3.3.3:0, tag: 301
  tib entry: 2.2.2.2/32, rev 2
        local binding:  tag: imp-null
        remote binding: tsr: 1.1.1.1:0, tag: 100
        remote binding: tsr: 3.3.3.3:0, tag: 300
  tib entry: 3.3.3.3/32, rev 10
        local binding:  tag: 201
        remote binding: tsr: 3.3.3.3:0, tag: imp-null
        remote binding: tsr: 1.1.1.1:0, tag: 102
  tib entry: 4.4.4.4/32, rev 14
        local binding:  tag: 203
        remote binding: tsr: 1.1.1.1:0, tag: 104
        remote binding: tsr: 3.3.3.3:0, tag: 303
  tib entry: 10.1.2.0/24, rev 4
        local binding:  tag: imp-null
        remote binding: tsr: 1.1.1.1:0, tag: imp-null
        remote binding: tsr: 3.3.3.3:0, tag: 302
  tib entry: 10.2.3.0/24, rev 6
        local binding:  tag: imp-null
        remote binding: tsr: 1.1.1.1:0, tag: 101
        remote binding: tsr: 3.3.3.3:0, tag: imp-null
  tib entry: 10.3.4.0/24, rev 12
        local binding:  tag: 202
        remote binding: tsr: 3.3.3.3:0, tag: imp-null
        remote binding: tsr: 1.1.1.1:0, tag: 103
R2#
R2#sh mpls ip binding
  1.1.1.1/32
        in label:     200
        out label:    imp-null  lsr: 1.1.1.1:0        inuse
        out label:    301       lsr: 3.3.3.3:0
  2.2.2.2/32
        in label:     imp-null
        out label:    100       lsr: 1.1.1.1:0
        out label:    300       lsr: 3.3.3.3:0
  3.3.3.3/32
        in label:     201
        out label:    imp-null  lsr: 3.3.3.3:0        inuse
        out label:    102       lsr: 1.1.1.1:0
  4.4.4.4/32
        in label:     203
        out label:    104       lsr: 1.1.1.1:0
        out label:    303       lsr: 3.3.3.3:0        inuse
  10.1.2.0/24
        in label:     imp-null
        out label:    imp-null  lsr: 1.1.1.1:0
        out label:    302       lsr: 3.3.3.3:0
  10.2.3.0/24
        in label:     imp-null
        out label:    101       lsr: 1.1.1.1:0
        out label:    imp-null  lsr: 3.3.3.3:0
  10.3.4.0/24
        in label:     202
        out label:    imp-null  lsr: 3.3.3.3:0        inuse
        out label:    103       lsr: 1.1.1.1:0
R2#
R2#sh mpls forwarding-table
Local  Outgoing    Prefix            Bytes tag  Outgoing   Next Hop
tag    tag or VC   or Tunnel Id      switched   interface
200    Pop tag     1.1.1.1/32        0          Fa0/1      10.1.2.1
201    Pop tag     3.3.3.3/32        0          Fa0/0      10.2.3.3
202    Pop tag     10.3.4.0/24       0          Fa0/0      10.2.3.3
203    303         4.4.4.4/32        0          Fa0/0      10.2.3.3
R2#

R2#
R2#sh mpls forwarding-table detail
Local  Outgoing    Prefix            Bytes tag  Outgoing   Next Hop
tag    tag or VC   or Tunnel Id      switched   interface
200    Pop tag     1.1.1.1/32        0          Fa0/1      10.1.2.1
        MAC/Encaps=14/14, MRU=1504, Tag Stack{}
        CA0002C40008CA0102C400068847
        No output feature configured
    Per-packet load-sharing
201    Pop tag     3.3.3.3/32        0          Fa0/0      10.2.3.3
        MAC/Encaps=14/14, MRU=1504, Tag Stack{}
        CA020AE80006CA0102C400088847
        No output feature configured
    Per-packet load-sharing
202    Pop tag     10.3.4.0/24       0          Fa0/0      10.2.3.3
        MAC/Encaps=14/14, MRU=1504, Tag Stack{}
        CA020AE80006CA0102C400088847
        No output feature configured
    Per-packet load-sharing
203    303         4.4.4.4/32        0          Fa0/0      10.2.3.3
        MAC/Encaps=14/18, MRU=1500, Tag Stack{303}
        CA020AE80006CA0102C400088847 0012F000
        No output feature configured
    Per-packet load-sharing
R2#

Full configuration for above network diagram:

 
Disclaimer
Information above is either from RFCs or it's Googled. This blog is result of my enthusiasm, desire and hard work to lean networking and share my leanings. Most of the times I’ll be using GNS3 network simulator. All I've here is collection of my findings, thanks to Google. Please do not ask for any of the software from CISCO/Juniper, it's better to Google it and try your luck.

Online packet capture library : Label Distribution Protocol a.k.a LDP

Title : Label Distribution Protocol a.k.a LDP

RFC : RFC 5036

Network diagram:



Dropbox Link:

https://www.dropbox.com/s/l2cwf9hndkuuu0y/MPLS_LDP_captures.pcapng?dl=0

Online packet capture:

https://www.cloudshark.org/captures/f2bc3794873d

Disclaimer
Information above is either from RFCs or it's Googled. This blog is result of my enthusiasm, desire and hard work to lean networking and share my leanings. Most of the times I’ll be using GNS3 network simulator. All I've here is collection of my findings, thanks to Google. Please do not ask for any of the software from CISCO/Juniper, it's better to Google it and try your luck.

Tuesday, October 7, 2014

Online packet capture library: IP in IP encapsulation (Tunnelling IPv4 to IPv4)

Title : IP in IP encapsulation (Tunnelling IPv4 to IPv4)

Protocol : IP in IP encapsulation

Network Diagram for capture :





Dropbox link:

https://www.dropbox.com/s/mfxry8p4r7kezd2/IP_in_IP_tunnel.pcap?dl=0

Online packet capture:

https://www.cloudshark.org/captures/fa58de541596

Disclaimer
Information above is either from RFCs or it's Googled. This blog is result of my enthusiasm, desire and hard work to lean networking and share my leanings. Most of the times I’ll be using GNS3 network simulator. All I've here is collection of my findings, thanks to Google. Please do not ask for any of the software from CISCO/Juniper, it's better to Google it and try your luck.

Online packet capture library: OSPF_v2 - Open shortest path first version 2 (for IPv4)

Title : OSPF_v2 - Open shortest path first version 2 (for IPv4) 

Protocol : OSPFv2

Network Diagram for capture :



Dropbox link:

https://www.dropbox.com/s/ws79jbl5zc3ewo6/OSPF_v2.pcapng?dl=0


Online packet capture:

https://www.cloudshark.org/captures/6d46846350b2


Disclaimer
Information above is either from RFCs or it's Googled. This blog is result of my enthusiasm, desire and hard work to lean networking and share my leanings. Most of the times I’ll be using GNS3 network simulator. All I've here is collection of my findings, thanks to Google. Please do not ask for any of the software from CISCO/Juniper, it's better to Google it and try your luck.

Saturday, September 13, 2014

Online packet capture library: GRE tunnel - Generic Routing Encapsulation tunnel

Online packet capture library: GRE tunnel - Generic Routing Encapsulation tunnel

Title : GRE tunnel - Generic Routing Encapsulation tunnel without encryption.

Protocol : GRE

RFC : RFC 2784 and RFC 2784

Network Diagram for capture:




Dropbox link:

https://www.dropbox.com/s/2c1vlgiu6r3ruc3/IPv4_GRE_tunnel.pcap?dl=0

Online packet capture:

https://www.cloudshark.org/captures/1376c07f4c80

Disclaimer
Information above is either from RFCs or it's Googled. This blog is result of my enthusiasm, desire and hard work to lean networking and share my leanings. Most of the times I’ll be using GNS3 network simulator. All I've here is collection of my findings, thanks to Google. Please do not ask for any of the software from CISCO/Juniper, it's better to Google it and try your luck.

Online packet capture library: IP MTU and Packet fragmentation

Title : IP MTU and Packet fragmentation

Protocol : ICMP and DF bit = 0

Network Diagram for capture:




Dropbox link:

Between_Router1_and_Router2_IP_MTU_1500
 

Between_Router2_and_Router3_IP_MTU_1000 

Online packet capture:

Between_Router1_and_Router2_IP_MTU_1500 : https://www.cloudshark.org/captures/ced2396abaf1

Between_Router2_and_Router3_IP_MTU_1000 : https://www.cloudshark.org/captures/e4e0e6a21e86

Disclaimer
Information above is either from RFCs or it's Googled. This blog is result of my enthusiasm, desire and hard work to lean networking and share my leanings. Most of the times I’ll be using GNS3 network simulator. All I've here is collection of my findings, thanks to Google. Please do not ask for any of the software from CISCO/Juniper, it's better to Google it and try your luck.

Monday, September 8, 2014

Online packet capture library: ICMPv4 (ping) echo reply successful with VLAN tag

Title : ICMPv4 echo reply successful with VLAN tag

Protocol : ICMP + 802.1Q

Network Diagram for capture:



Dropbox link:

https://www.dropbox.com/s/nxw7eb8kz3ek8ua/ICMP_with_VLAN_100_P-BIT_0.pcap?dl=0

Online packet capture:

https://www.cloudshark.org/captures/9fc3671d5633

Disclaimer
Information above is either from RFCs or it's Googled. This blog is result of my enthusiasm, desire and hard work to lean networking and share my leanings. Most of the times I’ll be using GNS3 network simulator. All I've here is collection of my findings, thanks to Google. Please do not ask for any of the software from CISCO/Juniper, it's better to Google it and try your luck.