31-MSR係列路由器MPLS C2C配置舉例
本章節下載: 31-MSR係列路由器MPLS C2C配置舉例 (181.91 KB)
MSR路由器MPLS C2C的典型配置舉例
|
Copyright © 2014 杭州華三通信技術有限公司 版權所有,保留一切權利。 非經本公司書麵許可,任何單位和個人不得擅自摘抄、複製本文檔內容的部分或全部, 並不得以任何形式傳播。本文檔中的信息可能變動,恕不另行通知。 |
|
目 錄
本文檔介紹使用MPLS C2C的典型配置舉例。
本文檔不嚴格與具體軟、硬件版本對應,如果使用過程中與產品實際情況有差異,請參考相關產品手冊,或以設備實際情況為準。
本文檔中的配置均是在實驗室環境下進行的配置和驗證,配置前設備的所有參數均采用出廠時的缺省配置。如果您已經對設備進行了配置,為了保證配置效果,請確認現有配置和以下舉例中的配置不衝突。
如圖1所示,在MPLS VPN的運營商的運營商網絡中,一級運營商PE 1和PE 2通過MP-IBGP為下聯的二級運營商提供標簽轉發,二級運營商為BGP MPLS VPN供應商,PE向下聯的CE提供VPN服務。現要求:一級運營商PE與下聯的CE使用LDP分發標簽方式,使用戶CE 3和CE 4能夠互相轉發報文。

|
設備 |
接口 |
IP地址 |
設備 |
接口 |
IP地址 |
|
PE1 |
GE0/0 |
82.1.1.2/24 |
PE2 |
GE0/0 |
80.1.1.2/24 |
|
|
GE0/1 |
80.1.1.1/24 |
|
GE0/1 |
81.1.1.2/24 |
|
|
Loopback0 |
10.1.1.5/32 |
|
Loopback0 |
10.1.1.6/32 |
|
CE1 |
GE0/0 |
82.1.1.1/24 |
CE2 |
GE0/0 |
81.1.1.1/24 |
|
|
GE0/1 |
90.1.1.1/24 |
|
GE0/1 |
91.1.1.1/24 |
|
|
Loopback0 |
10.1.1.3/24 |
|
Loopback0 |
10.1.1.4/24 |
|
PE3 |
GE0/0 |
90.1.1.2/24 |
PE4 |
GE0/0 |
91.1.1.2/24 |
|
|
GE0/1 |
192.16.1.1/24 |
|
GE0/1 |
192.168.2.1/24 |
|
|
Loopback0 |
10.1.1.1/24 |
|
Loopback0 |
10.1.1.2/24 |
|
CE3 |
GE0/1 |
192.168.1.2/24 |
CE4 |
GE0/1 |
192.168.2.2/24 |
為了使PE和CE間使能LDP將一級運營商和二級運營商正常銜接,需要在PE節點部署LDP多實例,使多實例路由分發進BGP中,連接兩個不同的耳機運營商。
本舉例是在Release 2316版本上進行配置和驗證的。
路由重分布時一定要考慮雙向的路由傳遞,即IGP分布到BGP,同時要把BGP重分布到IGP中,才能保證路由的雙向傳遞。
# 配置接口IP地址。
<PE1> system-view
[PE1] interface loopback 0
[PE1-LoopBack0] ip address 10.1.1.5 255.255.255.255
[PE1-LoopBack0] quit
[PE1] interface gigabitethernet 0/0
[PE1-GigabitEthernet0/0] ip address 82.1.1.2 255.255.255.0
[PE1-GigabitEthernet0/0] quit
[PE1] interface gigabitethernet 0/1
[PE1-GigabitEthernet0/0] ip address 80.1.1.1 255.255.255.0
[PE1-GigabitEthernet0/0] quit
# 配置Router ID及MPLS LSR-ID,使能MPLS和MPLS LDP功能。
[PE1] router id 10.1.1.5
[PE1] mpls lsr-id 10.1.1.5
[PE1] mpls
[PE1] mpls ldp
[PE1-mpls-ldp] quit
# 在接口GigabitEthernet0/0和GigabitEthernet0/1配置MPLS和MPLS LDP功能。
[PE1] interface gigabitethernet 0/0
[PE1-GigabitEthernet0/0] mpls
[PE1-GigabitEthernet0/0] mpls ldp
[PE1-GigabitEthernet0/0] quit
[PE1] interface gigabitethernet 0/1
[PE1-GigabitEthernet0/1] mpls
[PE1-GigabitEthernet0/1] mpls ldp
[PE1-GigabitEthernet0/1] quit
# 創建VPN實例vpn1,並配置RD和VPN Target屬性。
[PE1] ip vpn-instance vpn1
[PE1-vpn-instance-vpn1] route-distinguisher 10.1.1.5:1
[PE1-vpn-instance-vpn1] vpn-target 100:1 both
[PE1-vpn-instance-vpn1] quit
# 將接口GigabitEthernet0/0綁定到vpn1上。
[PE1] interface gigabitethernet 0/0
[PE1-GigabitEthernet0/1] ip binding vpn-instance vpn1
[PE1-GigabitEthernet0/1] ip address 82.1.1.2 255.255.255.0
[PE1-GigabitEthernet0/1] quit
# 配置公網OSPF路由協議進程1。
[PE1] ospf 1
[PE1-ospf-1] area 0
[PE1-ospf-1-area-0.0.0.0] network 10.1.1.5 0.0.0.0
[PE1-ospf-1-area-0.0.0.0] network 80.1.1.0 0.0.0.255
[PE1-ospf-1-area-0.0.0.0] quit
[PE1-ospf-1] quit
# 配置LDP多實例。
[PE1] mpls ldp vpn-instance vpn1
[PE1-mpls-ldp-vpn-instance-vpn1] quit
# 配置私網OSPF路由協議進程2,同時將BGP路由重分布到OSPF進程中。
[PE1] ospf 2 vpn-instance vpn1
[PE1-ospf-2] import-route bgp
[PE1-ospf-2] area 0.0.0.0
[PE1-ospf-2-area-0.0.0.0] network 82.1.1.0 0.0.0.255
[PE1-ospf-2-area-0.0.0.0] quit
[PE1-ospf-2] quit
# 配置BGP路由協議,在一級運營商PE之間建立MP-IBGP。將私網OSPF 2路由重分布到BGP-VPN路由中,通過MP-IBGP傳遞到遠端一級運營商PE。
[PE1] bgp 1000
[PE1-bgp] peer 10.1.1.6 as-number 1000
[PE1-bgp] peer 10.1.1.6 connect-interface LoopBack0
[PE1-bgp] ipv4-family vpnv4
[PE1-bgp-af-vpnv4] peer 10.1.1.6 enable
[PE1-bgp-af-vpnv4] quit
# 將私網OSPF 2路由重分布到BGP-VPN路由中,通過MP-IBGP傳遞到遠端一級運營商PE。
[PE1-bgp] ipv4-family vpn-instance vpn1
[PE1-bgp-vpn1] import-route ospf 2
[PE1-bgp-vpn1] quit
[PE1-bgp] quit
# 配置接口IP地址。
<CE1> system-view
[CE1] interface loopback 0
[CE1-LoopBack0] ip address 10.1.1.3 255.255.255.255
[CE1-LoopBack0] quit
[CE1] interface gigabitethernet 0/1
[CE1-GigabitEthernet0/1] ip address 90.1.1.1 255.255.255.0
[CE1-GigabitEthernet0/1] quit
[CE1] interface gigabitethernet 0/0
[CE1-GigabitEthernet0/0] ip address 82.1.1.1 255.255.255.0
[CE1-GigabitEthernet0/0] quit
# 配置Router ID和MPLS LSR-ID,,使能MPLS和MPLS LDP功能。
[CE1] router id 10.1.1.3
[CE1] mpls lsr-id 10.1.1.3
[CE1] mpls
[CE1] mpls ldp
[CE1-mpls-ldp] quit
# 在接口GigabitEthernet0/0和GigabitEthernet0/1配置MPLS和MPLS LDP功能。
[CE1] interface gigabitethernet 0/0
[CE1-GigabitEthernet0/0] mpls
[CE1-GigabitEthernet0/0] mpls ldp
[CE1-GigabitEthernet0/0] quit
[CE1] interface gigabitethernet 0/1
[CE1-GigabitEthernet0/1] mpls
[CE1-GigabitEthernet0/1] mpls ldp
[CE1-GigabitEthernet0/1] quit
# 配置OSPF路由協議,使網絡互通。
[CE1] ospf 2
[CE1-ospf-2] area 0
[CE1-ospf-2-area-0.0.0.0] network 10.1.1.3 0.0.0.0
[CE1-ospf-2-area-0.0.0.0] network 90.1.1.0 0.0.0.255
[CE1-ospf-2-area-0.0.0.0] network 82.1.1.0 0.0.0.255
[CE1-ospf-2-area-0.0.0.0] quit
[CE1-ospf-2] quit
# 配置接口IP地址。
<PE3> system-view
[PE3] interface loopback 0
[PE3-LoopBack0] ip address 10.1.1.1 255.255.255.255
[PE3-LoopBack0] quit
[PE3] interface gigabitethernet 0/0
[PE3-GigabitEthernet0/0] ip address 90.1.1.2 255.255.255.0
[PE3-GigabitEthernet0/0] quit
[PE3] interface gigabitethernet 0/1
[PE3-GigabitEthernet0/1] ip address 192.168.1.1 255.255.255.0
[PE3-GigabitEthernet0/1] quit
# 配置Router ID和MPLS LSR-ID,使能MPLS和MPLS LDP功能。
[PE3] router id 10.1.1.1
[PE3] mpls lsr-id 10.1.1.1
[PE3] mpls
[PE3] mpls ldp
[PE3] quit
# 在接口GigabitEthernet0/1配置MPLS和MPLS LDP功能。
[PE3] interface gigabitethernet 0/1
[PE3-GigabitEthernet0/1] mpls
[PE3-GigabitEthernet0/1] mpls ldp
[PE3-GigabitEthernet0/1] quit
# 配置OSPF路由協議,使網絡互通。
[PE3] ospf 2
[PE3-ospf-2] area 0
[PE3-ospf-2-area-0.0.0.0] network 10.1.1.1 0.0.0.0
[PE3-ospf-2-area-0.0.0.0] network 90.1.1.0 0.0.0.255
[PE3-ospf-2-area-0.0.0.0] quit
[PE3-ospf-2] quit
# 創建VPN實例vpn1,並配置RD和VPN Target屬性。
[PE3] ip vpn-instance vpn1
[PE3-vpn-instance-vpn1] route-distinguisher 10.1.1.1:1
[PE3-vpn-instance-vpn1] vpn-target 100:1 both
[PE3-vpn-instance-vpn1] quit
# 將接口GigabitEthernet0/1綁定到vpn1上。
[PE3] interface gigabitethernet 0/1
[PE3-GigabitEthernet0/1] ip binding vpn-instance vpn1
[PE3-GigabitEthernet0/1] ip address 192.16.1.1 255.255.255.0
[PE3-GigabitEthernet0/1] quit
# 配置BGP路由協議,在二級運營商PE之間建立MP-IBGP。
[PE3] bgp 200
[PE3-bgp] peer 10.1.1.2 as-number 200
[PE3-bgp] peer 10.1.1.2 next-hop-local
[PE3-bgp] peer 10.1.1.2 connect-interface LoopBack0
[PE3-bgp] ipv4-family vpnv4
[PE3-bgp-af-vpnv4] peer 10.1.1.2 enable
[PE3-bgp-af-vpnv4] quit
# 進入BGP-VPN實例視圖,配置PE 3的CE用戶,將私網直連路由重分布到VPN路由中。
[PE3-bgp] ipv4-family vpn-instance vpn1
[PE3-bgp-vpn1] import direct
[PE3-bgp-vpn1] quit
[PE3-bgp] quit
# 配置接口IP地址。
<PE2> system-view
[PE2] interface loopback 0
[PE2-LoopBack0] ip address 10.1.1.6 255.255.255.255
[PE2-LoopBack0] quit
[PE2] interface gigabitethernet 0/0
[PE2-GigabitEthernet0/0] ip address 80.1.1.2 255.255.255.0
[PE2-GigabitEthernet0/0] quit
[PE2] interface gigabitethernet 0/1
[PE2-GigabitEthernet0/1] ip address 81.1.1.2 255.255.255.0
[PE2-GigabitEthernet0/1] quit
# 配置Router ID和MPLS LSR-ID,使能MPLS和MPLS LDP功能。
[PE2] router id 10.1.1.6
[PE2] mpls lsr-id 10.1.1.6
[PE2] mpls
[PE2] mpls ldp
[PE2-mpls-ldp] quit
# 在接口配置MPLS和MPLS LDP功能。
[PE2] interface gigabitethernet 0/0
[PE2-GigabitEthernet0/0] mpls
[PE2-GigabitEthernet0/0] mpls ldp
[PE2-GigabitEthernet0/0] quit
[PE2] interface gigabitethernet 0/1
[PE2-GigabitEthernet0/1] mpls
[PE2-GigabitEthernet0/1] mpls ldp
[PE2-GigabitEthernet0/1] quit
# 創建VPN實例vpn1,並配置RD和VPN Target屬性。
[PE2] ip vpn-instance vpn1
[PE2-vpn-instance-vpn1] route-distinguisher 10.1.1.6:1
[PE2-vpn-instance-vpn1] vpn-target 100:1 both
[PE2-vpn-instance-vpn1] quit
# 將接口GigabitEthernet0/1綁定到vpn1上。
[PE2] interface gigabitethernet 0/1
[PE2-GigabitEthernet0/1] ip binding vpn-instance vpn1
[PE2-GigabitEthernet0/1] ip address 81.1.1.2 255.255.255.0
[PE2-GigabitEthernet0/1] quit
# 配置公網OSPF路由協議進程1。
[PE2] ospf 1
[PE2-ospf-1] area 0
[PE2-ospf-1-area-0.0.0.0] network 10.1.1.6 0.0.0.0
[PE2-ospf-1-area-0.0.0.0] network 80.1.1.0 0.0.0.255
[PE2-ospf-1-area-0.0.0.0] quit
[PE2-ospf-1] quit
# 配置LDP多實例。
[PE2] mpls ldp vpn-instance vpn1
[PE2-mpls-ldp-vpn-instance-vpn1] quit
# 配置私網OSPF路由協議進程2,同時將BGP路由重分布到OSPF進程中。
[PE2] ospf 2 vpn-instance vpn1
[PE2-ospf-2] import-route bgp
[PE2-ospf-2] area 0.0.0.0
[PE2-ospf-2-area-0.0.0.0] network 81.1.1.0 0.0.0.255
[PE2-ospf-2-area-0.0.0.0] quit
[PE2-ospf-2] quit
# 配置BGP路由協議,在一級運營商PE之間建立MP-IBGP。
[PE2] bgp 1000
[PE2-bgp] peer 10.1.1.5 as-number 1000
[PE2-bgp] peer 10.1.1.5 connect-interface LoopBack0
[PE2-bgp] ipv4-family vpnv4
[PE2-bgp-af-vpnv4] peer 10.1.1.5 enable
[PE2-bgp-af-vpnv4] quit
# 將私網OSPF 2路由重分布到BGP-VPN路由中,通過MP-IBGP傳遞到遠端一級運營商PE。
[PE2-bgp] ipv4-family vpn-instance vpn1
[PE2-bgp-vpn1] import-route ospf 2
[PE2-bgp-vpn1] quit
[PE2-bgp] quit
# 配置接口IP地址。
[CE2] interface loopback 0
[CE2-LoopBack0] ip address 10.1.1.4 255.255.255.255
[CE2-LoopBack0] quit
[CE2] interface gigabitethernet 0/0
[CE2-GigabitEthernet0/0] ip address 81.1.1.1 255.255.255.0
[CE2-GigabitEthernet0/0] quit
[CE2] interface gigabitethernet 0/1
[CE2-GigabitEthernet0/0] ip address 91.1.1.1 255.255.255.0
[CE2-GigabitEthernet0/0] quit
# 配置Router ID和MPLS LSR-ID,使能MPLS和MPLS LDP功能。
[CE2] router id 10.1.1.4
[CE2] mpls lsr-id 10.1.1.4
[CE2] mpls
[CE2] mpls ldp
[CE2-mpls-ldp] quit
# 在接口GigabitEthernet0/0和GigabitEthernet0/1配置MPLS和MPLS LDP功能。
[CE2] interface gigabitethernet 0/0
[CE2-GigabitEthernet0/0] mpls
[CE2-GigabitEthernet0/0] mpls ldp
[CE2-GigabitEthernet0/0] quit
[CE2] interface gigabitethernet 0/1
[CE2-GigabitEthernet0/1] mpls
[CE2-GigabitEthernet0/1] mpls ldp
[CE2-GigabitEthernet0/1] quit
# 配置OSPF路由協議,使網絡互通。
[CE2] ospf 2
[CE2-ospf-2] area 0
[CE2-ospf-2-area-0.0.0.0] network 10.1.1.4 0.0.0.0
[CE2-ospf-2-area-0.0.0.0] network 81.1.1.0 0.0.0.255
[CE2-ospf-2-area-0.0.0.0] network 91.1.1.0 0.0.0.255
[CE2-ospf-2-area-0.0.0.0] quit
[CE2-ospf-2] quit
# 配置接口IP地址。
[PE4] interface loopback 0
[PE4-LoopBack0] ip address 10.1.1.2 255.255.255.255
[PE4-LoopBack0] quit
[PE4] interface gigabitethernet 0/0
[PE4-GigabitEthernet0/0] ip address 91.1.1.2 255.255.255.0
[PE4-GigabitEthernet0/0] quit
[PE4] interface gigabitethernet 0/1
[PE4-GigabitEthernet0/1] ip address 192.168.2.1 255.255.255.0
[PE4-GigabitEthernet0/1] quit
# 配置Router ID和MPLS LSR-ID,使能MPLS和MPLS LDP功能。
[PE4] router id 10.1.1.2
[PE4] mpls lsr-id 10.1.1.2
[PE4] mpls
[PE4] mpls ldp
[PE4-mpls-ldp] quit
# 在接口配置MPLS和MPLS LDP功能。
[PE4] interface gigabitethernet 0/0
[PE4-GigabitEthernet0/0] mpls
[PE4-GigabitEthernet0/0] mpls ldp
[PE4-GigabitEthernet0/0] quit
# 配置OSPF路由協議
[PE4] ospf 2
[PE4-ospf-2] area 0
[PE4-ospf-2-area-0.0.0.0] network 10.1.1.2 0.0.0.0
[PE4-ospf-2-area-0.0.0.0] network 91.1.1.0 0.0.0.255
[PE4-ospf-2-area-0.0.0.0] quit
[PE4-ospf-2] quit
# 創建VPN實例vpn1,並配置RD和VPN Target屬性。
[PE4] ip vpn-instance vpn1
[PE4-vpn-instance-vpn1] route-distinguisher 10.1.1.2:1
[PE4-vpn-instance-vpn1] vpn-target 100:1 both
[PE4-vpn-instance-vpn1] quit
# 將接口GigabitEthernet0/1綁定到vpn1上。
[PE4] interface gigabitethernet 0/1
[PE4-GigabitEthernet0/1] ip binding vpn-instance vpn1
[PE4-GigabitEthernet0/1] ip address 192.168.2.1 255.255.255.0
[PE4-GigabitEthernet0/1] quit
# 配置BGP路由協議,在二級運營商PE之間建立MP-IBGP。
[PE4] bgp 200
[PE4-bgp] peer 10.1.1.1 as-number 200
[PE4-bgp] peer 10.1.1.1 next-hop-local
[PE4-bgp] peer 10.1.1.1 connect-interface LoopBack0
[PE4-bgp] ipv4-family vpnv4
[PE4-bgp-af-vpnv4] peer 10.1.1.1 enable
# 進入BGP-VPN實例視圖,配置PE 4的CE用戶,將私網直連路由重分布到VPN路由中。
[PE4-bgp] ipv4 vpn-instance vpn1
[PE4-bgp-vpn1] import direct
[PE4-bgp-vpn1] quit
[PE4-bgp] quit
# 查看二級運營商PE 3的VPN路由表中,是否有對方二級運營商PE的自身的VPN路由。
<PE3> display ip routing-table vpn-instance vpn1
Routing Tables: vpn1
Destinations : 5 Routes : 5
Destination/Mask Proto Pre Cost NextHop Interface
192.168.1.0/24 Direct 0 0 192.168.1.1 Eth0/8
192.168.1.1/32 Direct 0 0 127.0.0.1 InLoop0
192.168.2.0/24 BGP 255 0 10.1.1.2 NULL0
# 在PE 3 ping對方二級運營商PE的私網地址,查看能否ping通。
<PE3> ping -vpn-instance vpn1 192.168.2.1
PING 192.168.2.1: 56 data bytes, press CTRL_C to break
Reply from 192.168.2.1: bytes=56 Sequence=0 ttl=255 time=2 ms
Reply from 192.168.2.1: bytes=56 Sequence=1 ttl=255 time=1 ms
Reply from 192.168.2.1: bytes=56 Sequence=2 ttl=255 time=1 ms
Reply from 192.168.2.1: bytes=56 Sequence=3 ttl=255 time=2 ms
Reply from 192.168.2.1: bytes=56 Sequence=4 ttl=255 time=1 ms
--- 192.168.2.1 ping statistics ---
5 packet(s) transmitted
5 packet(s) received
0.00% packet loss
round-trip min/avg/max = 1/1/2 ms
# 在CE 3 ping對方二級運營商PE用戶CE 4的接口地址,查看能否ping通。
<CE3> ping 192.168.2.2
PING 192.168.2.2: 56 data bytes, press CTRL_C to break
Reply from 192.168.2.2: bytes=56 Sequence=0 ttl=253 time=2 ms
Reply from 192.168.2.2: bytes=56 Sequence=1 ttl=253 time=1 ms
Reply from 192.168.2.2: bytes=56 Sequence=2 ttl=253 time=1 ms
Reply from 192.168.2.2: bytes=56 Sequence=3 ttl=253 time=2 ms
Reply from 192.168.2.2: bytes=56 Sequence=4 ttl=253 time=2 ms
--- 192.168.2.2 ping statistics ---
5 packet(s) transmitted
5 packet(s) received
0.00% packet loss
round-trip min/avg/max = 1/1/2 ms
· PE 1:
#
sysname PE1
#
router id 10.1.1.5
#
ip vpn-instance vpn1
route-distinguisher 10.1.1.5:1
vpn-target 100:1 export-extcommunity
vpn-target 100:1 import-extcommunity
#
mpls lsr-id 10.1.1.5
#
mpls
#
mpls ldp
#
mpls ldp vpn-instance vpn1
#
interface LoopBack0
ip address 10.1.1.5 255.255.255.255
#
interface GigabitEthernet0/0
port link-mode route
ip binding vpn-instance vpn1
ip address 82.1.1.2 255.255.255.0
mpls
mpls ldp
#
interface GigabitEthernet0/1
port link-mode route
ip address 80.1.1.1 255.255.255.0
mpls
mpls ldp
#
bgp 1000
undo synchronization
peer 10.1.1.6 as-number 1000
peer 10.1.1.6 connect-interface LoopBack0
#
ipv4-family vpnv4
peer 10.1.1.6 enable
#
ipv4-family vpn-instance vpn1
import-route ospf 2
#
ospf 1
area 0.0.0.0
network 80.1.1.0 0.0.0.255
network 10.1.1.5 0.0.0.0
#
ospf 2 vpn-instance vpn1
import-route bgp
area 0.0.0.0
network 82.1.1.0 0.0.0.255
#
· CE 1:
#
sysname CE1
#
router id 10.1.1.3
#
mpls lsr-id 10.1.1.3
#
mpls
#
mpls ldp
#
interface GigabitEthernet0/0
port link-mode route
ip address 82.1.1.1 255.255.255.0
mpls
mpls ldp
#
interface GigabitEthernet0/1
ip address 90.1.1.1 255.255.255.0
mpls
mpls ldp
#
interface LoopBack0
ip address 10.1.1.3 255.255.255.255
#
ospf 2
area 0.0.0.0
network 10.1.1.3 0.0.0.0
network 82.1.1.0 0.0.0.255
network 90.1.1.0 0.0.0.255
#
· PE 3:
#
sysname PE3
#
router id 10.1.1.1
#
ip vpn-instance vpn1
route-distinguisher 10.1.1.1:1
vpn-target 100:1 export-extcommunity
vpn-target 100:1 import-extcommunity
#
mpls lsr-id 10.1.1.1
#
mpls
#
mpls ldp
#
interface GigabitEthernet0/0
ip address 90.1.1.2 255.255.255.0
mpls
mpls ldp
#
interface GigabitEthernet0/1
port link-mode route
ip binding vpn-instance vpn1
ip address 192.16.1.1 255.255.255.0
#
interface LoopBack0
ip address 10.1.1.1 255.255.255.255
#
bgp 200
undo synchronization
peer 10.1.1.2 as-number 200
peer 10.1.1.2 next-hop-local
peer 10.1.1.2 connect-interface LoopBack0
#
ipv4-family vpnv4
peer 10.1.1.2 enable
#
ipv4-family vpn-instance vpn1
import direct
#
ospf 2
area 0.0.0.0
network 10.1.1.1 0.0.0.0
network 90.1.1.0 0.0.0.255
#
· PE 2:
#
sysname PE2
#
router id 10.1.1.6
#
ip vpn-instance vpn1
route-distinguisher 10.1.1.6:1
vpn-target 100:1 export-extcommunity
vpn-target 100:1 import-extcommunity
#
mpls lsr-id 10.1.1.6
#
mpls
#
mpls ldp
#
interface LoopBack0
ip address 10.1.1.6 255.255.255.255
#
interface GigabitEthernet0/0
port link-mode route
ip address 80.1.1.2 255.255.255.0
mpls
mpls ldp
#
interface GigabitEthernet0/1
port link-mode route
ip binding vpn-instance vpn1
ip address 81.1.1.2 255.255.255.0
mpls
#
bgp 1000
undo synchronization
peer 10.1.1.5 as-number 1000
peer 10.1.1.5 connect-interface LoopBack0
#
ipv4-family vpnv4
peer 10.1.1.5 enable
#
ipv4-family vpn-instance vpn1
import-route ospf 2
#
ospf 1
area 0.0.0.0
network 10.1.1.6 0.0.0.0
network 80.1.1.0 0.0.0.255
#
ospf 2 vpn-instance vpn1
import-route bgp
area 0.0.0.0
network 81.1.1.0 0.0.0.255
#
· CE 2:
#
sysname CE2
#
router id 10.1.1.4
#
ip vpn-instance vpn1
route-distinguisher 10.1.1.4:1
vpn-target 100:1 export-extcommunity
vpn-target 100:1 import-extcommunity
#
mpls lsr-id 10.1.1.4
#
mpls
#
mpls ldp
#
interface LoopBack0
ip address 10.1.1.4 255.255.255.255
#
interface GigabitEthernet0/0
port link-mode route
ip address 81.1.1.1 255.255.255.0
mpls
#
interface GigabitEthernet0/1
port link-mode route
ip address 91.1.1.1 255.255.255.0
mpls
mpls ldp
#
ospf 2
area 0.0.0.0
network 10.1.1.4 0.0.0.0
network 91.1.1.0 0.0.0.255
network 81.1.1.0 0.0.0.255
#
· PE 4:
#
sysname PE4
#
router id 10.1.1.2
#
ip vpn-instance vpn1
route-distinguisher 10.1.1.2:1
vpn-target 100:1 export-extcommunity
vpn-target 100:1 import-extcommunity
#
mpls lsr-id 10.1.1.2
#
mpls
#
mpls ldp
#
interface LoopBack0
ip address 10.1.1.2 255.255.255.255
#
interface GigabitEthernet0/0
port link-mode route
ip address 91.1.1.2 255.255.255.0
mpls
mpls ldp
#
interface GigabitEthernet0/1
port link-mode route
ip binding vpn-instance vpn1
ip address 192.168.2.1 255.255.255.0
#
bgp 200
network 91.1.1.0 255.255.255.0
undo synchronization
peer 10.1.1.1 as-number 200
peer 10.1.1.1 next-hop-local
peer 10.1.1.1 connect-interface LoopBack0
#
ipv4-family vpnv4
peer 10.1.1.1 enable
#
ipv4-family vpn-instance vpn1
import direct
#
ospf 2
area 0.0.0.0
network 91.1.1.0 0.0.0.255
network 10.1.1.2 0.0.0.0
#
· H3C MSR 係列路由器 命令參考(V5)-R2311
· H3C MSR 係列路由器 配置指導(V5)-R2311
不同款型規格的資料略有差異, 詳細信息請向具體銷售和400谘詢。H3C保留在沒有任何通知或提示的情況下對資料內容進行修改的權利!
