Mpls vpn service shunting case
1. Configure the basic information of each vro
2. OSPF standard configuration. Change the network type to point-to-point and configure the passive interface.
3. The MPLS backbone network runs OSPF and the Label Distribution Protocol is LDP.
4. Run MP_IPGP in RT4 and RT5, and use mpls vpn to distribute production and office services.
5. RT4 vrf SC and RT6 run RIP, RT4 vrf bg and RT7 configure Static Routing, RT5 vrf SC and RT8 run OSPF, RT5 VRF BG and RT9 run EBGP
IP address planning is as follows:
I. basic configuration (omitted)
Ii. IGP commissioning of Backbone Networks
RT1:
Router ospf 1
Router-id 1.1.1.1
Passive-interface Ethernet3/0
Network 1.1.1.1 0.0.0.0 area 0
Network 10.0.12.0 0.0.0.3 area 0
Network 10.0.20.0.0.0.3 area 0
RT2:
Router ospf 1
Router-id 2.2.2.2
Passive-interface default
No passive-interface Serial0/0
No passive-interface Serial0/1
No passive-interface FastEthernet1/0
Network 2.2.2.2 0.0.0.0 area 0
Network 10.0.12.0 0.0.0.3 area 0
Network 10.0.23.0 0.0.0.3 area 0
Network 10.0.24.0 0.0.0.3 area 0
Int f1/0
Ip ospf network point-to-point
RT3:
Router ospf 1
Router-id 3.3.3.3
Passive-interface default
No passive-interface Serial0/0
No passive-interface Serial0/1
No passive-interface FastEthernet1/0
Network 3.3.3.3 0.0.0.0 area 0
Network 10.0.20.0.0.0.3 area 0
Network 10.0.23.0 0.0.0.3 area 0
Network 10.0.35.0 0.0.0.3 area 0
Int f1/0
Ip ospf network point-to-point
RT4:
Router ospf 1
Router-id 4.4.4
Passive-interface default
No passive-interface Serial0/0
Network 4.4.4.4 0.0.0.0 area 0
Network 10.0.24.0 0.0.0.3 area 0
RT5:
Router ospf 1
Router-id 5.5.5
Passive-interface default
No passive-interface Serial0/0
Network 5.5.5.5 0.0.0.0 area 0
Network 10.0.35.0 0.0.0.3 area 0
Iii. MPLS Commissioning for Backbone Networks
RT1:
Cef must be enabled for ip CEF // MPLS
Mpls ip // enable the MPLS Protocol
Mpls label protocol ldp // select the label Distribution protocol as LDP
Int s0/1
Mpls ip // enable MPLS on the Interface
Mpls mtu 1600 // set the maximum mpls mtu to 1600
Int s0/2
Mpls ip
Mpls mtu 1600
RT2:
Ip cef
Mpls ip
Mpls label protocol ldp
Int s0/0
Mpls ip
Mpls mtu 1600
Int s0/1
Mpls ip
Mpls mtu 1600
Int f1/0
Mpls ip
Mpls mtu 1600
RT3:
Ip cef
Mpls ip
Mpls label protocol ldp
Int s0/0
Mpls ip
Mpls mtu 1600
Int s0/1
Mpls ip
Mpls mtu 1600
Int f1/0
Mpls ip
Mpls mtu 1600
RT4:
Ip cef
Mpls ip
Mpls label protocol ldp
Int s0/0
Mpls ip
Mpls mtu 1600
RT5:
Ip cef
Mpls ip
Mpls label protocol ldp
Int s0/0
Mpls ip
Mpls mtu 1600
Iv. Backbone Network MP_BGP commissioning
RT4:
Router bgp 65000
No synchronization // disable synchronization
Neighbor 5.5.5.5 remote-as 65000 // establish BGP neighbors
Neighbor 5.5.5.5 update-source Loopback0 // specify the update source
Neighbor 5.5.5.5 next-hop-self // change the next hop to your own
No auto-summary // disable auto summary
Address-family vpnv4 // enable MP_BGP
Neighbor 5.5.5.5 activate // establish MP_BGP neighbor
Neighbor 5.5.5.5 send-community extended // supports group attributes
Exit-address-family // exit the MP_BGP Configuration
RT5:
Router bgp 65000
No synchronization
Bgp log-neighbor-changes
Neighbor 4.4.4 remote-as 65000
Neighbor 4.4.4 update-source Loopback0
Neighbor 4.4.4 next-hop-self
No auto-summary
Address-family vpnv4
Neighbor 4.4.4 activate
Neighbor 4.4.4.4 send-community extended
Exit-address-family
V. VRF commissioning
RT4:
Ip vrf BG // create VRF and name it BG
Rd // The RD of VRF is
Route-target export // export RT
Route-target import // The import RT is
Ip vrf SC
Rd 1:1
Route-target export :20
Route-target import :10
RT5:
Ip vrf BG
Rd 2:
Route-target export 2: 10
Route-target import 2: 20
Ip vrf SC
Rd 1:1
Route-target export :10
Route-target import :20
Vi. Commissioning of PE and CE routing protocols
RT4:
Router rip // configure the routing protocol between CE and PE VRF
Version 2
No auto-summary
Address-family ipv4 vrf SC // configure MP_BGP
Network 172.16.0.0
No auto-summary
Version 2
Exit-address-family
RT6:
Router rip
Version 2
Network 6.0.0.0
Network 172.16.0.0
No auto-summary
RT4:
Ip route vrf BG 7.7.7.7 route 255.255 Serial0/2 172.17.47.2 // Add a static route in VRF BG
Ip route vrf BG 172.17.7.0 255.255.255.0 Serial0/2 172.17.47.2
RT7:
Ip route 0.0.0.0 0.0.0.0 172.17.47.1 // configure the default route
RT5:
Router ospf 101 vrf SC // configure VRF SC OSPF
Router-id 172.16.5.1
Network 172.16.5.0 0.0.0.255 area 0
Network 172.16.58.0 0.0.3 area 0
RT8:
Router ospf 1
Router-id 8.8.8.8
Passive-interface Ethernet3/0
Network 8.8.8.8 0.0.0.0 area 0
Network 172.16.8.0 0.0.255 area 0
Network 172.16.58.0 0.0.3 area 0
Network 0.0.0.0 255.255.255.255 area 0
RT5:
Router bgp 65000 // configure EBGP
Address-family ipv4 vrf BG // configure MP_BGP
Neighbor 172.17.59.2 remote-as 65001 // create an EBGP neighbor
No auto-summary
No synchronization
Exit-address-family
RT9:
Router bgp 65001
No synchronization
Network 9.9.9 mask 255.255.255.255
Network 172.17.9.0 mask 255.255.255.0
Network 172.17.59.0 mask 255.255.255.252
Neighbor 172.17.59.1 remote-as 65000
No auto-summary
VII. mpls vpn commissioning
RT4:
Router bgp 65000
Address-family ipv4 vrf SC
Redistribute connected metric 1000 // redistributed directly to MP_BGP
Redistribute rip metric 1000 // re-RIP directly connected to MP_BGP
No auto-summary
No synchronization
Exit-address-family
Address-family ipv4 vrf BG
Redistribute connected metric 1000 // redistributed directly to MP_BGP
Redistribute static metric 1000 // redistribution static to MP_BGP
No auto-summary
No synchronization
Exit-address-family
Router rip
Redistribute bgp 65000 metric 5 // redistributes vrf SC to RIP
RT5:
Router bgp 65000
Address-family ipv4 vrf SC
Redistribute connected metric 1000 // redistributed directly to MP_BGP
Redistribute ospf 101 vrf SC metric 1000 match internal external 1 external 2 // re-distribution OSPF 101 vrf SC matches external routes of Class 5 type 1 and type 2 to MP_BGP
No auto-summary
No synchronization
Exit-address-family
Address-family ipv4 vrf BG
Redistribute connected metric 1000 // redistributed directly to MP_BGP
Exit-address-family
// When the PE_CE routing protocol is EBGP, The EBGP routing in VRF is automatically exported to the MP_BGP table.
Test command:
Show ip bgp vpnv4 all summary // displays the neighbor information of MP_BGP
Show mpls forwarding-tabel // display MPLS forwarding Table
Show mpls ldp bindings // display the label binding information of MPLS LDP
Show ip route vrf SC // display the route information of VRF SC
Show ip bgp vpnv4 all // display all routes of VPNV4 in BGP
Show ip bgp vpnv4 all labels // display all routes and labels of VPNV4 in BGP
If the configuration is correct and a route exists in the MP-BGP table, instead of importing the VRF yourself, use:
Clear ip route vrf VPN name
Analyze the propagation of the RT8 route 172.16.8.0/24:
1. First, there is a direct connection route on RT8.
C 172.16.8.0/24 is directly connected, Ethernet3/0
2. the vrf SC and RT8 of RT5 are configured with OSPF (CE and PE VRF routing protocols ), route 172.16.8.0/24 to the vrf SC of RT5 through OSPF (this route can only be seen in vrf SC and does not exist in the global routing table of RT5)
RT5 # show ip route vrf SC
O 172.16.8.0/24 [110/110] via 172.16.58.2, 00:08:58, Serial0/1
3. Publish the OSPF route to MP_BGP through redistribution, and add RT, RD, and private network labels to the route.
RT5 # show ip bgp vpnv4 all labels
Route Distinguisher: 1:1 (SC)
172.16.8.0/24 172.16.58.2 26/nolabel
RD is 1:1 VPN name SC next hop is 172.16.58.2 private network IN label is 26 OUT label is none
Meanwhile, a forwarding entry is formed in MPLS label forwarding.
RT5 # show mpls forwarding-table
26 Untagged 172.16.8.0/24 [V] 0 Se0/1 point2point
The LOCAL label is 26 (the private network label for distribution). The OUT label is Untagged. The next label is S0/1.
4. MP_BGP initiates a route, transmits the route through update, attaches a public network label, and transmits it to RT4 through LSP (the public network label is used for forwarding in MPLS networks, and the forwarding process on LSP is not described)
RT5 # show ip bgp vpnv4 all
Route Distinguisher: 1:1 (default for vrf SC)
*> 172.16.8.0/24 172.16.58.2 1000 32768?
MP_BGP originating from this route
The above is the update packet of MP_BGP, which is to replace the NIRL attribute and the inaccessible route attribute of the original BGP with the MP_REACH_NLRI and MP_UNREACH_NIRL attributes.
The rt value in the Extended_Communities attribute is.
In the MP_REACH_NLRI attribute, the private network label 26 RD is IPV4 route 172.16.8.0/24.
When the IPV4 route of VRF is marked with RD, it becomes a VPNV4 route.
Supplement:
The RD route Delimiter is used to identify different IP address spaces. Therefore, each VRF must (or can only) Configure one RD;
The RT route destination is the Extended Comununity attribute, which is used to control the mutual access between VRF and add the IPV4 route of VRF to RT and export it to MP_BGP, PE-PE neighbor propagation between MP-IBGP to the remote PE, remote pe rt matching, according to the RT matching relationship, these routes into different VRF. By using the RT Import and Export relationship to control the VRF access range, different VPNs are formed and service traffic is diverted.
5. after RT4 MP_BGP receives the update packet, it compares whether RT is consistent with its own VRF incoming RT. If yes, it is imported to the corresponding VRF, this is the same as the RT4 vrf SC, so the Import
Save both the private network label and RD
RT4 # show ip bgp vpnv4 all labels
Route Distinguisher: 1:1 (SC)
172.16.8.0/24 5.5.5 nolabel/26
RD is VPN name SC next hop is 5.5.5 private network IN label is no OUT label is 26
RT4 # show ip bgp vpnv4 all labels
Route Distinguisher: 1:1 (SC)
*> I172.16.8.0/24 5.5.5.5 1000 100 0?
BGP Route received by RT4
6. Publish the MP_BGP route to RIP through redistribution, pass the route to RT6 through the RIP routing protocol between RT4 vrf SC and RT6, and form a RIP route on RT6.
R 172.16.8.0/24 [120/5] via 172.16.46.1, 00:00:21, Serial0/0
The propagation of IGP route protocol routes between other CE and pe vrf is similar
Analysis of the communication process between RT6 and RT8's 172.161 (the route entries mentioned here can be viewed above ):
First, RT6 receives the data packet, searches for the route from the target IP address, finds the matching item output interface S0/0, data forwarding, and vrf SC of RT4 receives the data packet and looks for the route table, find the matched BGP Route. The private network OUT label is 26, and the next hop is 5.5.5.5, which is not directly connected. Search for the MPLS Forwarding Table with the target IP address 5.5.5.5 and find the matching item, the OUT tag is 21 (for distribution of 5.5.5 tags, refer to the previous blog)
The outbound interface is S0/0, which is forwarded by the direct connection interface and transmitted to RT5 through LSP (for intermediate MPLS Forwarding, see the previous blog post). RT5 searches for the MPLS Forwarding Table through the private network label 26, find the matching item. The OUT tag is Untagged. Delete the tag and forward it from the outbound interface S0/1. RT8 receives the packet, searches for the route table, and submits it to the corresponding interface.
Author: "Mortal World"