mpls ***跨域,VRF-TO-VRF方式

VRF-VRF解決方案技術上最簡單的,沒有在“AS內部的MPLS-***”上作任何擴展,完全應用已有技術實現 。

ASBR對等體間,通過劃分子接口方式,每個子接口分別綁定一個VRF,保證域間傳播路由的私有性。

ASBR對等體間,只運行普通BGP,不運行LDP,交互IPV4路由。

每個PE-ASBR路由器都把對方PE-ASBR路由器當做CE路由器看待。

比較適合運用在AS域間交互***(VRF)數量較少的情況。但是擴展性較差。

實驗拓撲圖:

wKiom1PYmzOgz33KAABc6k0naVk676.png

1.路由器R1上lo0:1.1.1.1/32,路由器R2上lo0:2.2.2.2/32,路由器R3上lo0:3.3.3.3/32,路由器R4上lo0:4.4.4.4/32,路由器R5上lo0:5.5.5.5/32,路由器R6上lo0:6.6.6.6/32。

2.R5和R6是CE路由器,R1,R2,R3,R4是PE路由器,省去了P路由器,不影響實驗。R1和R2之間IGP:OSPF,bgp爲MBGP, R2和R3之間是EBGP,R3和R4之間,IGP是OSPF,bgp爲MBGP,

3.一下爲R1-R6的配置文件:

R1:


hostname R1

!

!

ip vrf r5

 rd 1:1

 route-target export 1:1

 route-target import 1:1


interface Loopback0

 ip address 1.1.1.1 255.255.255.255

!

interface FastEthernet0/0

 ip address 12.1.1.1 255.255.255.0

 speed auto

 duplex auto

 mpls ip

!

interface FastEthernet0/1

 ip vrf forwarding r5

 ip address 15.1.1.1 255.255.255.0

 speed auto

 duplex auto

!

router ospf 2 vrf r5

 redistribute bgp 12 subnets

 network 0.0.0.0 255.255.255.255 area 0

!

router ospf 1

 network 0.0.0.0 255.255.255.255 area 0

!

router bgp 12

 bgp log-neighbor-changes

 no bgp default ipv4-unicast

 neighbor 2.2.2.2 remote-as 12

 neighbor 2.2.2.2 update-source Loopback0

 !

 address-family ipv4

 exit-address-family

 !

 address-family ***v4

  neighbor 2.2.2.2 activate

  neighbor 2.2.2.2 send-community extended

 exit-address-family

 !

 address-family ipv4 vrf r5

  redistribute ospf 2 match internal external 1 external 2

 exit-address-family

!


路由器R2:


hostname R2

!

ip vrf r5

 rd 1:1

 route-target export 1:1

 route-target import 1:1

!

interface Loopback0

 ip address 2.2.2.2 255.255.255.255

!

interface FastEthernet0/0

 ip address 12.1.1.2 255.255.255.0

 speed auto

 duplex auto

 mpls ip

!

interface FastEthernet0/1

 ip vrf forwarding r5

 ip address 23.1.1.2 255.255.255.0

 speed auto

 duplex auto

!

router ospf 1

 network 2.2.2.2 0.0.0.0 area 0

 network 12.1.1.0 0.0.0.255 area 0

!

router bgp 12

 bgp log-neighbor-changes

 no bgp default ipv4-unicast

 neighbor 1.1.1.1 remote-as 12

 neighbor 1.1.1.1 update-source Loopback0

 neighbor 23.1.1.3 remote-as 34

 !

 address-family ipv4

 exit-address-family

 !

 address-family ***v4

  neighbor 1.1.1.1 activate

  neighbor 1.1.1.1 send-community extended

 exit-address-family

 !

 address-family ipv4 vrf r5

  neighbor 23.1.1.3 remote-as 34

  neighbor 23.1.1.3 activate

 exit-address-family

!


路由器R3:

!

hostname R3

!

ip vrf r6

 rd 2:2

 route-target export 2:2

 route-target import 2:2

!

interface Loopback0

 ip address 3.3.3.3 255.255.255.255

!

interface FastEthernet0/0

 ip address 34.1.1.3 255.255.255.0

 speed auto

 duplex auto

 mpls ip

!

interface FastEthernet0/1

 ip vrf forwarding r6

 ip address 23.1.1.3 255.255.255.0

 speed auto

 duplex auto

!

router ospf 1

 network 3.3.3.3 0.0.0.0 area 0

 network 34.1.1.0 0.0.0.255 area 0

!

router bgp 34

 bgp log-neighbor-changes

 no bgp default ipv4-unicast

 neighbor 4.4.4.4 remote-as 34

 neighbor 4.4.4.4 update-source Loopback0

 neighbor 23.1.1.2 remote-as 12

 !

 address-family ipv4

 exit-address-family

 !

 address-family ***v4

  neighbor 4.4.4.4 activate

  neighbor 4.4.4.4 send-community extended

 exit-address-family

 !

 address-family ipv4 vrf r6

  neighbor 23.1.1.2 remote-as 12

  neighbor 23.1.1.2 activate

 exit-address-family


路由器R4:

!

hostname R4

!

!

ip vrf r6

 rd 2:2

 route-target export 2:2

 route-target import 2:2

!

interface Loopback0

 ip address 4.4.4.4 255.255.255.255

!

interface FastEthernet0/0

 ip address 34.1.1.4 255.255.255.0

 speed auto

 duplex auto

 mpls ip

!

interface FastEthernet0/1

 ip vrf forwarding r6

 ip address 46.1.1.4 255.255.255.0

 speed auto

 duplex auto

!

router ospf 2 vrf r6

 redistribute bgp 34 subnets

 network 0.0.0.0 255.255.255.255 area 0

!

router ospf 1

 network 4.4.4.4 0.0.0.0 area 0

 network 0.0.0.0 255.255.255.255 area 0

!

router bgp 34

 bgp log-neighbor-changes

 no bgp default ipv4-unicast

 neighbor 3.3.3.3 remote-as 34

 neighbor 3.3.3.3 update-source Loopback0

 !

 address-family ipv4

 exit-address-family

 !

 address-family ***v4

  neighbor 3.3.3.3 activate

  neighbor 3.3.3.3 send-community extended

 exit-address-family

 !

 address-family ipv4 vrf r6

  redistribute ospf 2 match internal external 1 external 2

 exit-address-family

!


路由器R5:

!

hostname R5

!

interface Loopback0

 ip address 5.5.5.5 255.255.255.255

!

interface FastEthernet0/0

 no ip address

 shutdown

 speed auto

 duplex auto

!

interface FastEthernet0/1

 ip address 15.1.1.5 255.255.255.0

 speed auto

 duplex auto

!

router ospf 2

 network 0.0.0.0 255.255.255.255 area 0

!         


路由器R6:

!

hostname R6

!

interface Loopback0

 ip address 6.6.6.6 255.255.255.255

!

interface FastEthernet0/0

 no ip address

 shutdown

 speed auto

 duplex auto

!

interface FastEthernet0/1

 ip address 46.1.1.6 255.255.255.0

 speed auto

 duplex auto

!

router ospf 2

 network 0.0.0.0 255.255.255.255 area 0

!         



發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章