#configure terminal | Enter Configure mode. |
(config)#interface eth1 | Enter interface mode. |
(config-if)#ip add 30.30.30.55/24 | Assign an IP address. |
(config-if)#exit | Exit interface mode. |
(config)#router ospf 100 | Enter Router OSPF mode. |
(config-router)#network 4.5.6.7/32 a 0 | Configure OSPF network. |
(config-router)#network 30.30.30.0/24 a 0 | Configure OSPF network. |
(config-router)#exit | Exit Router OSPF mode and return to Configure mode. |
(config)#router ldp | Enter Router LDP mode. |
(config-router)#pw-status-tlv | Enable pw-status-tlv. |
(config-router)#targeted-peer ipv4 3.4.5.6 | Configure targeted-peer LDP session to S-PE2. |
(config-router)#exit | Exit Router LDP mode and return to Configure mode. |
(config)#interface eth1 | Enter interface mode. |
(config-if)#label-switching | Enable label-switching on the interface connected to S-PE. |
(config-if)#enable-ldp ipv4 | Enable LDP on the interface connected to S-PE. |
(config-if)#exit | Exit interface mode. |
(config)#mpls l2-circuit c3 300 3.4.5.6 passive | Configure dynamic-passive pseudowire. |
(config-pseduowire)#exit | Exit pseudowire mode. |
(config)#interface eth2 | Enter interface mode. |
(config-if)#switchport | Change eth2 to Layer 2 interface. |
(config-if)#mpls-l2-circuit c3 ethernet | Bind the PW to the Layer 2 interface connected to CE router. |
(config-if)#exit | Exit interface mode. |
#configure terminal | Enter Configure mode. |
(config)#interface eth1 | Enter interface mode. |
(config-if)#ip add 20.20.20.54/24 | Assign an IP address. |
(config-if)#exit | Exit interface mode. |
(config)#interface eth2 | Enter interface mode. |
(config-if)#ip add 30.30.30.54/24 | Assign an IP address. |
(config-if)#exit | Exit interface mode. |
(config)#router ospf 100 | Enter Router OSPF mode. |
(config-router)#network 3.4.5.6/32 a 0 | Configure OSPF network. |
(config-router)#network 20.20.20.0/24 a 0 | Configure OSPF network. |
(config-router)#network 30.30.30.0/24 a 0 | Configure OSPF network. |
(config-router)#exit | Exit Router OSPF mode and return to Configure mode. |
(config)#router ldp | Enter Router LDP mode. |
(config-router)#pw-status-tlv | Enable pw-status-tlv. |
(config-router)#targeted-peer ipv4 4.5.6.7 | Configure targeted-peer LPD session to T-PE2. |
(config-router)#targeted-peer ipv4 2.3.4.5 | Configure targeted-peer LDP session to S-PE1. |
(config-router)#exit | Exit Router LDP mode and return to Configure mode. |
(config)#mpls l2-circuit c3 300 4.5.6.7 | Configure dynamic PW for circuit c3. |
(config-pseduowire)#exit | Exit pseudowire mode. |
(config)#mpls l2-circuit c2 200 2.3.4.5 | Configure dynamic PW for circuit c2. |
(config-pseduowire)#exit | Exit pseudowire mode. |
(config)#mpls ms-pw-stitch sp2 c2 c3 | Stitch the two PWs. |
(config)#mpls ms-pw sp2 from-mpls-pc2-to-mpls-pc4 | Configure S-PE description. |
#configure terminal | Enter Configure mode. |
(config)#interface eth1 | Enter interface mode. |
(config-if)#ip add 10.10.10.53/24 | Assign an IP address. |
(config-if)#exit | Exit interface mode. |
(config)#interface eth2 | Enter interface mode. |
(config-if)#ip add 20.20.20.52/24 | Assign an IP address. |
(config-if)#exit | Exit interface mode. |
(config)#router ospf 100 | Enter Router OSPF mode. |
(config-router)#network 2.3.4.5/32 a 0 | Configure OSPF network. |
(config-router)#network 10.10.10.0/24 a 0 | Configure OSPF network. |
(config-router)#network 20.20.20.0/24 a 0 | Configure OSPF network. |
(config-router)#exit | Exit Router OSPF mode and return to Configure mode. |
(config)#router ldp | Enter Router LDP mode. |
(config-router)#pw-status-tlv | Enable pw-status-tlv. |
(config-router)#targeted-peer ipv4 3.4.5.6 | Configure targeted-peer LDP session to S-PE2. |
(config-router)#targeted-peer ipv4 1.2.3.4 | Configure targeted-peer LDP session to T-PE1. |
(config-router)#exit | Exit Router LDP mode and return to Configure mode. |
(config)#mpls l2-circuit c2 200 3.4.5.6 | Configure dynamic PW for circuit c2. |
(config-pseduowire)#exit | Exit pseudowire mode. |
(config)#mpls l2-circuit c1 100 1.2.3.4 | Configure dynamic PW for circuit c1. |
(config-pseduowire)#exit | Exit pseudowire mode. |
(config)#mpls ms-pw-stitch sp2 c1 c2 | Stitch the two pseudowires. |
(config)#mpls ms-pw sp1 from-mpls-pc1-to-mpls-pc3 | Configure S-PE description. |
(config)#mpls l2-circuit c1 100 1.2.3.4 manual | Configure static pseudowire. |
(config)#mpls ms-pw-stitch sp1 c1 c2 mtu 1500 ethernet | Stitch the two pseudowires, one of which is signaled and the other is manual. |
(config)#mpls l2-circuit-fib-entry 100 101 201 1.2.3.4 eth3 c2 | Add FIB entry for the static PW. c2 is the PW to which it has to be stitched at S-PE1. |
#configure terminal | Enter Configure mode. |
(config)#interface eth1 | Enter interface mode. |
(config-if)#ip add 10.10.10.51/24 | Assign IP address. |
(config-if)#exit | Exit interface mode. |
(config)#router ospf 100 | Enter Router OSPF mode. |
(config-router)#network 1.2.3.4/32 a 0 | Configure OSPF network. |
(config-router)#network 10.10.10.0/24 a 0 | Configure OSPF network. |
(config-router)#exit | Exit Router OSPF mode and return to Configure mode. |
(config)#router ldp | Enter Router LDP mode |
(config-router)#pw-status-tlv | Enable pw-status-tlv. |
(config-router)#targeted-peer ipv4 2.3.4.5 | Configure targeted-peer LDP session to S-PE1. |
(config-router)#exit | Exit Router LDP mode and return to Configure mode. |
(config)#interface eth1 | Enter interface mode. |
(config-if)#label-switching | Enable label-switching on the interface. |
(config-if)#enable-ldp ipv4 | Enable LDP on the interface. |
(config-if)#exit | Exit interface mode. |
(config)#mpls l2-circuit c1 100 2.3.4.5 | Configure dynamic PW. |
(config-pseduowire)#exit | Exit pseudowire mode. |
(config)#interface eth2 | Enter interface mode. |
(config-if)#switchport | Configure eth2 as a Layer 2 interface. |
(config-if)#mpls-l2-circuit c1 ethernet | Bind the PW to the Layer 2 interface connected to CE router. |
(config-if)#exit | Exit interface mode. |
(config)#mpls l2-circuit c1 100 2.3.4.5 manual | Configure static pseudowire. |
(config)#mpls l2-circuit-fib-entry 100 201 101 2.3.4.5 eth1 eth2 | Adding FIB entry for the static PW created, after binding it to the access interface (eth2). |