用hcl模拟器做MPLS VPN,bgp邻居和mpls ldp邻居建立正常,但是vpn实例的ospf和bgp双向引入的时候无法引入路由,很奇怪,不知道哪里配置错了,请大佬解答一下,同配置下ensp正常。
P路由
[P_R1]dis cu
#
version 7.1.075, Alpha 7571
#
sysname P_R1
#
router id 1.1.1.1
#
ospf 1
area 0.0.0.0
network 1.1.1.1 0.0.0.0
network 12.12.12.0 0.0.0.3
network 13.13.13.0 0.0.0.3
#
mpls lsr-id 1.1.1.1
#
mpls ldp
#
interface LoopBack0
ip address 1.1.1.1 255.255.255.255
#
interface GigabitEthernet0/0
port link-mode route
combo enable copper
ip address 12.12.12.1 255.255.255.252
ospf network-type p2p
mpls enable
mpls ldp enable
#
interface GigabitEthernet0/1
port link-mode route
combo enable copper
ip address 13.13.13.1 255.255.255.252
ospf network-type p2p
mpls enable
mpls ldp enable
# return
PE-1路由
[PE_R1]dis cu
#
version 7.1.075, Alpha 7571
#
sysname PE_R1
#
ip vpn-instance 1t2
route-distinguisher 100:200
vpn-target 100:200 200:100 import-extcommunity
vpn-target 200:100 100:200 export-extcommunity
#
router id 2.2.2.2
#
ospf 1
area 0.0.0.0
network 2.2.2.2 0.0.0.0
network 12.12.12.0 0.0.0.3
#
ospf 2
vpn-instance 1t2
import-route bgp 333
vpn-instance-capability simple
area 0.0.0.0 network 24.24.24.0 0.0.0.3
#
mpls lsr-id 2.2.2.2
#
vlan 1
#
mpls ldp
#
interface LoopBack0
ip address 2.2.2.2 255.255.255.255
#
interface GigabitEthernet0/0
port link-mode route
combo enable copper
ip address 12.12.12.2 255.255.255.252
ospf network-type p2p
mpls enable
mpls ldp enable
#
interface GigabitEthernet0/1
port link-mode route
combo enable copper
#
interface GigabitEthernet0/1.2
ip binding vpn-instance 1t2
ip address 24.24.24.1 255.255.255.252
ospf network-type p2p
vlan-type dot1q vid 2
#
bgp 333
peer 3.3.3.3 as-number 333
peer 3.3.3.3 connect-interface LoopBack0
#
address-family vpnv4 peer 3.3.3.3 enable
#
ip vpn-instance 1t2
#
address-family ipv4 unicast
import-route ospf 2
#
return
PE-2路由
[PE_R2]dis cu
#
version 7.1.075, Alpha 7571
#
sysname PE_R2
#
ip vpn-instance 2t1
route-distinguisher 100:200
vpn-target 200:100 100:200 import-extcommunity
vpn-target 100:200 200:100 export-extcommunity
#
router id 3.3.3.3
# ospf 1
area 0.0.0.0
network 3.3.3.3 0.0.0.0
network 13.13.13.0 0.0.0.3
#
ospf 2 vpn-instance 2t1
import-route bgp 333
vpn-instance-capability simple
area 0.0.0.0
network 35.35.35.0 0.0.0.3
#
mpls lsr-id 3.3.3.3
#
vlan 1
#
mpls ldp
#
interface LoopBack0
ip address 3.3.3.3 255.255.255.255
#
interface GigabitEthernet0/0
port link-mode route
combo enable copper
ip address 13.13.13.2 255.255.255.252
ospf network-type p2p
mpls enable
mpls ldp enable
#
interface GigabitEthernet0/1
port link-mode route
combo enable copper
# interface GigabitEthernet0/1.2
ip binding vpn-instance 2t1
ip address 35.35.35.1 255.255.255.252
ospf network-type p2p
vlan-type dot1q vid 2
#
bgp 333
peer 2.2.2.2 as-number 333
peer 2.2.2.2 connect-interface LoopBack0
#
address-family vpnv4
peer 2.2.2.2 enable
#
ip vpn-instance 2t1
#
address-family ipv4 unicast
import-route ospf 2
#
return
CE-1交换
[CE_S1]dis cu
#
version 7.1.075, Alpha 7571
#
sysname CE_S1
#
ip vpn-instance 1t2
route-distinguisher 100:200
vpn-target 100:200 200:100 import-extcommunity
vpn-target 200:100 100:200 export-extcommunity
#
router id 4.4.4.4
#
ospf 2 vpn-instance 1t2
vpn-instance-capability simple
area 0.0.0.0 network 24.24.24.0 0.0.0.3
network 192.168.1.0 0.0.0.255
#
vlan 1
#
vlan 2 to 3
#
stp global enable
#
interface NULL0
#
interface LoopBack0
ip address 4.4.4.4 255.255.255.255
#
interface Vlan-interface2
ip binding vpn-instance 1t2
ip address 24.24.24.2 255.255.255.252
ospf network-type p2p
#
interface Vlan-interface3
ip binding vpn-instance 1t2
ip address 192.168.1.1 255.255.255.0
#
interface GigabitEthernet1/0/1
port link-mode bridge
port link-type trunk
port trunk permit vlan all
combo enable fiber
#
interface GigabitEthernet1/0/2
port link-mode bridge port
access vlan 3
combo enable fiber
#
return
CE-2交换
[CE_S2]dis cu
#
version 7.1.075, Alpha 7571
#
sysname CE_S2
#
ip vpn-instance 2t1
route-distinguisher 100:200
vpn-target 200:100 100:200 import-extcommunity
vpn-target 100:200 200:100 export-extcommunity
#
router id 5.5.5.5
#
ospf 2 vpn-instance 2t1
vpn-instance-capability simple
area 0.0.0.0
network 35.35.35.0 0.0.0.3
network 192.168.2.0 0.0.0.255
#
mpls lsr-id 5.5.5.5
#
lldp global enable
#
vlan 1
#
vlan 2 to 3
#
stp global enable
#
mpls ldp
#
interface NULL0
#
interface Vlan-interface2
ip binding vpn-instance 2t1
ip address 35.35.35.2 255.255.255.252
ospf network-type p2p
#
interface Vlan-interface3
ip binding vpn-instance 2t1
ip address 192.168.2.1 255.255.255.0
#
interface GigabitEthernet1/0/1
port link-mode bridge
port link-type trunk
port trunk permit vlan all
combo enable fiber
#
interface GigabitEthernet1/0/2
port link-mode bridge
port access vlan 3
combo enable fiber
#
return
附件为工程文件,HCL版本为2.1.1,路由器和交换机版本为b75
(0)
最佳答案
您的问题出在这:
您执行OSPF注入BGP的时候,实际上注入的不是vpn实例绑定的OSPF进程,而是全局下的OSPF 进程2,正确配置参考如下:
(0)
能在详细点吗?您的配置和我的配置是一样的呀
就是说您得在bgp视图中进入vpn实例视图下执行引入,看您的配置是进入实例后,又退出来执行的引入动作
亲~登录后才可以操作哦!
确定你的邮箱还未认证,请认证邮箱或绑定手机后进行当前操作
举报
×
侵犯我的权益
×
侵犯了我企业的权益
×
抄袭了我的内容
×
原文链接或出处
诽谤我
×
对根叔社区有害的内容
×
不规范转载
×
举报说明
就是说您得在bgp视图中进入vpn实例视图下执行引入,看您的配置是进入实例后,又退出来执行的引入动作