MSR系列路由器MPLS HoVPN配置
关键词:MSR;MPLS;BGP;HoVPN
一、组网需求:
UPE、SPE和PEB是VPN站点接入路由器。UPE、PEB和SPE建立MP-IBGP连接。
设备清单:MSR系列路由器3台
二、组网图:
三、配置步骤:
设备和版本:MSR系列、Version 5.20, Release 1509
UPE配置
#
router id
#
ip vpn-instance
vpna
route-distinguisher 3:1
vpn-target 1:1 export-extcommunity
vpn-target 1:1 import-extcommunity
#
mpls lsr-id
#
mpls
#
mpls ldp
#
interface
Ethernet0/0
port link-mode
route
ip address
mpls
mpls ldp
#
interface
Ethernet0/1
port link-mode route
ip binding vpn-instance vpna
ip address 192.168.1.1 255.255.255.0
#
interface LoopBack0
ip address
#
bgp 1
undo synchronization
peer
peer
#
ipv4-family vpnv4
peer
#
ipv4-family vpn-instance
vpna
import-route direct
#
ospf 1
are
network
network
#
SPE配置:
#
router id
#
ip vpn-instance
vpna
route-distinguisher
1:1
vpn-target 1:1
export-extcommunity
vpn-target 1:1
import-extcommunity
#
mpls lsr-id
#
mpls
#
mpls ldp
#
interface
Ethernet0/0
port link-mode
route
ip address
mpls
mpls ldp
#
interface
Ethernet0/1
port link-mode
route
ip address
mpls
mpls ldp
#
interface
Ethernet1/0
port link-mode
route
ip binding vpn-instance vpna
ip address 192.168.2.1 255.255.255.0
#
interface LoopBack0
ip address
#
bgp 1
undo synchronization
group 1 internal
peer 1 connect-interface LoopBack0
peer
peer
#
ipv4-family vpnv4
peer 1 enable
peer
peer
peer
peer
peer
peer
#
ipv4-family vpn-instance
vpna
network 192.168.2.0 255.255.255.0
#
ospf 1
are
network
network
network
#
PEB配置
#
router id
#
ip vpn-instance
vpna
route-distinguisher 2:1
vpn-target 1:1 export-extcommunity
vpn-target 1:1 import-extcommunity
#
mpls lsr-id
#
mpls
#
mpls ldp
#
interface
Ethernet0/0
port link-mode
route
ip address
mpls
mpls ldp
#
interface
Ethernet0/1
port link-mode
route
ip binding vpn-instance
vpna
ip address 192.168.3.1 255.255.255.0
#
interface LoopBack0
ip address
#
bgp 1
undo synchronization
peer
peer
#
ipv4-family vpnv4
peer
#
ipv4-family vpn-instance
vpna
network
#
ospf 1
are
network
network
#
四、配置关键点:
在MPLS L3VPN基本配置正确的基础上,配置主要在SPE上指定upe和发布默认路由。
五、实验分析
在UPE和PEB上检查vpn路由及其标签。
UPE上查看vpn路由,注意默认路由:
<UPE>dis bg v
a r
BGP
Local router ID is
Total
number of routes from all PE: 1
Route
Distinguisher: 1:1
Network
NextHop
In/Out Label
MED LocPrf
*>i
Total
routes of vpn-instance vpna:
2
Network
NextHop
In/Out Label
MED LocPrf
*>i
*>
PEB上查看vpn路由情况:
<PEB>dis bgp vpnv4 vpn-instance
vpna routing-table
Total
Number of Routes: 3
BGP
Local router ID is
Status
codes: * - valid, > - best, d - damped,
h -
history, i - internal, s - suppressed, S - Stale
Origin
: i - IGP, e - EGP, ? - incomplete
Network
NextHop
MED LocPrf PrefVal
Path/Ogn
*>i
*>
*>i
SPE上查看vpn路由情况:
<SPE>dis bgp v a
r
BGP
Local router ID is
Total
number of routes from all PE: 2
Route
Distinguisher: 3:1
Network
NextHop
In/Out Label
MED LocPrf
*>i
Route
Distinguisher: 2:1
Network
NextHop
In/Out Label
MED LocPrf
*>i
Total
routes of vpn-instance vpna:
3
Network
NextHop
In/Out Label
MED LocPrf
*>
*>i