锐捷学习笔记-34(跨域MPLS VPN Option A)

锐捷MPLS VPN Option A配置


R1

hostname R1

interface GigabitEthernet 0/0
 no switchport
 ip address 13.1.1.1 255.255.255.0
 ip ospf 1 area 0

interface Loopback 0
 ip address 1.1.1.1 255.255.255.255
 ip ospf 1 area 0

router ospf 1
 router-id 1.1.1.1
 graceful-restart

R2

hostname R2

interface GigabitEthernet 0/0
 no switchport
 ip address 23.1.1.2 255.255.255.0

interface Loopback 0
 ip address 2.2.2.2 255.255.255.255
       
router rip
 version 2
 network 2.0.0.0
 network 23.1.1.0 0.0.0.255
 no auto-summary
 graceful-restart

R3

hostname R3

ip vrf 1
 rd 1:100
 route-target export 1:100
 route-target export 2:100
 route-target import 100:1
 route-target import 200:1
 route-target import 100:2

ip vrf 2
 rd 2:100
 route-target export 2:100
 route-target export 1:100
 route-target import 100:2
 route-target import 100:1

mpls ip

interface GigabitEthernet 0/0
 no switchport
 ip vrf forwarding 1
 ip address 13.1.1.3 255.255.255.0
 ip ospf 1 area 0

interface GigabitEthernet 0/1
 no switchport
 ip vrf forwarding 2
 ip address 23.1.1.3 255.255.255.0
         
interface GigabitEthernet 0/2
 no switchport
 ip address 34.1.1.3 255.255.255.0
 ip ospf 100 area 0
 mpls ip
 label-switching

interface Loopback 0
 ip address 3.3.3.3 255.255.255.255
 ip ospf 100 area 0

router bgp 100
 bgp log-neighbor-changes
 bgp graceful-restart restart-time 120
 bgp graceful-restart stalepath-time 360
 bgp graceful-restart
 neighbor 5.5.5.5 remote-as 100
 neighbor 5.5.5.5 update-source Loopback 0
 address-family ipv4
  no neighbor 5.5.5.5 activate
  exit-address-family
 address-family vpnv4 unicast
  neighbor 5.5.5.5 activate
  neighbor 5.5.5.5 send-community extended
  exit-address-family
  
 address-family ipv4 vrf 1
  redistribute ospf 1
  exit-address-family
  
 address-family ipv4 vrf 2
  redistribute rip
  exit-address-family

router ospf 1 vrf 1
 router-id 3.3.3.3
 graceful-restart
 redistribute bgp subnets

router ospf 100
 graceful-restart

router rip
 graceful-restart
 
 address-family ipv4 vrf 2
  version 2
  network 23.1.1.0 0.0.0.255
  no auto-summary
  redistribute bgp
  graceful-restart
  exit-address-family

mpls router ldp
 ldp router-id interface Loopback 0
 graceful-restart


R4

hostname R4

mpls ip

interface GigabitEthernet 0/0
 no switchport
 ip address 34.1.1.4 255.255.255.0
 ip ospf 100 area 0
 mpls ip
 label-switching

interface GigabitEthernet 0/1
 no switchport
 ip address 45.1.1.4 255.255.255.0
 ip ospf 100 area 0
 mpls ip
 label-switching

interface Loopback 0
 ip address 4.4.4.4 255.255.255.255
 ip ospf 100 area 0

router ospf 100
 graceful-restart

mpls router ldp
 ldp router-id interface Loopback 0
 graceful-restart


R5

ip vrf 1
 rd 1:100
 route-target export 100:1
 route-target import 1:100

ip vrf 2
 rd 2:100
 route-target export 100:2
 route-target import 2:100

mpls ip

interface GigabitEthernet 0/0
 no switchport
 ip address 45.1.1.5 255.255.255.0
 ip ospf 100 area 0
 mpls ip
 label-switching

interface GigabitEthernet 0/1
 no switchport

interface GigabitEthernet 0/1.10
 encapsulation dot1Q 10
 ip vrf forwarding 1
 ip address 56.1.1.1 255.255.255.252

interface GigabitEthernet 0/1.20
 encapsulation dot1Q 20
 ip vrf forwarding 2
 ip address 56.1.1.5 255.255.255.252

interface Loopback 0
 ip address 5.5.5.5 255.255.255.255
 ip ospf 100 area 0

router bgp 100
 bgp log-neighbor-changes
 bgp graceful-restart restart-time 120
 bgp graceful-restart stalepath-time 360
 bgp graceful-restart
 neighbor 3.3.3.3 remote-as 100
 neighbor 3.3.3.3 update-source Loopback 0
 address-family ipv4
  no neighbor 3.3.3.3 activate
  exit-address-family
 address-family vpnv4 unicast
  neighbor 3.3.3.3 activate
  neighbor 3.3.3.3 send-community extended
  exit-address-family
  
 address-family ipv4 vrf 1
  neighbor 56.1.1.2 remote-as 200
  neighbor 56.1.1.2 activate
  exit-address-family
  
 address-family ipv4 vrf 2
  neighbor 56.1.1.6 remote-as 200
  neighbor 56.1.1.6 activate
  exit-address-family

router ospf 100
 graceful-restart

mpls router ldp
 ldp router-id interface Loopback 0
 graceful-restart


R6

ip vrf 1
 rd 200:9
 route-target export 9:200
 route-target import 200:9

ip vrf 2
 rd 200:10
 route-target export 10:200
 route-target import 200:10

mpls ip

interface GigabitEthernet 0/0
 no switchport

interface GigabitEthernet 0/0.10
 encapsulation dot1Q 10
 ip vrf forwarding 1
 ip address 56.1.1.2 255.255.255.252

interface GigabitEthernet 0/0.20
 encapsulation dot1Q 20
 ip vrf forwarding 2
 ip address 56.1.1.6 255.255.255.252

interface GigabitEthernet 0/1
 no switchport
 ip address 67.1.1.6 255.255.255.0
 ip router isis 100
 mpls ip
 label-switching

interface Loopback 0
 ip address 6.6.6.6 255.255.255.255
 ip router isis 100

router bgp 200
 bgp log-neighbor-changes
 bgp graceful-restart restart-time 120
 bgp graceful-restart stalepath-time 360
 bgp graceful-restart
 neighbor 8.8.8.8 remote-as 200
 neighbor 8.8.8.8 update-source Loopback 0
 address-family ipv4
  no neighbor 8.8.8.8 activate
  exit-address-family
 address-family vpnv4 unicast
  neighbor 8.8.8.8 activate
  neighbor 8.8.8.8 send-community extended
  exit-address-family
  
 address-family ipv4 vrf 1
  neighbor 56.1.1.1 remote-as 100
  neighbor 56.1.1.1 activate
  exit-address-family
  
 address-family ipv4 vrf 2
  neighbor 56.1.1.5 remote-as 100
  neighbor 56.1.1.5 activate
  exit-address-family

router isis 100
 net 49.0060.0600.6006.00
 graceful-restart

mpls router ldp
 ldp router-id interface Loopback 0
 graceful-restart

R7

mpls ip

interface GigabitEthernet 0/0
 no switchport
 ip address 67.1.1.7 255.255.255.0
 ip router isis 100
 mpls ip
 label-switching

interface GigabitEthernet 0/1
 no switchport
 ip address 78.1.1.7 255.255.255.0
 ip router isis 100
 mpls ip
 label-switching

interface Loopback 0
 ip address 7.7.7.7 255.255.255.255
 ip router isis 100

router isis 100
 net 49.0070.0700.7007.00
 graceful-restart

mpls router ldp
 ldp router-id interface Loopback 0
 graceful-restart

R8

ip vrf 1
 rd 200:9
 route-target export 200:9
 route-target import 9:200

ip vrf 2
 rd 200:10
 route-target export 200:10
 route-target import 10:200

mpls ip     

interface GigabitEthernet 0/0
 no switchport
 ip address 78.1.1.8 255.255.255.0
 ip router isis 100
 mpls ip
 label-switching

interface GigabitEthernet 0/1
 no switchport
 ip vrf forwarding 1
 ip address 89.1.1.8 255.255.255.0
 ip router isis 1

interface GigabitEthernet 0/2
 no switchport
 ip vrf forwarding 2
 ip address 108.1.1.8 255.255.255.0


interface Loopback 0
 ip address 8.8.8.8 255.255.255.255
 ip router isis 100

router bgp 200
 bgp log-neighbor-changes
 bgp graceful-restart restart-time 120
 bgp graceful-restart stalepath-time 360
 bgp graceful-restart
 neighbor 6.6.6.6 remote-as 200
 neighbor 6.6.6.6 update-source Loopback 0
 address-family ipv4
  no neighbor 6.6.6.6 activate
  exit-address-family
 address-family vpnv4 unicast
  neighbor 6.6.6.6 activate
  neighbor 6.6.6.6 send-community extended
  exit-address-family
  
 address-family ipv4 vrf 1
  redistribute isis 1 level-2
  exit-address-family
  
 address-family ipv4 vrf 2
  redistribute static
  exit-address-family

router isis 1
 is-type level-2-only
 vrf 1
 net 49.0000.0000.0008.00
 redistribute bgp
 graceful-restart

router isis 100
 net 49.0080.0800.8008.00
 graceful-restart

mpls router ldp
 ldp router-id interface Loopback 0
 graceful-restart

ip route vrf 2 10.10.10.10 255.255.255.255 108.1.1.10


R9

interface GigabitEthernet 0/0
 no switchport
 ip address 89.1.1.9 255.255.255.0
 ip router isis 1

interface Loopback 0
 ip address 9.9.9.9 255.255.255.255
 ip router isis 1

router isis 1
 is-type level-2-only
 net 49.0000.0000.0009.00
 graceful-restart


R10

interface GigabitEthernet 0/0
 no switchport
 ip address 108.1.1.10 255.255.255.0

interface Loopback 0
 ip address 10.10.10.10 255.255.255.255
      
ip route 0.0.0.0 0.0.0.0 108.1.1.8


 

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包

打赏作者

学网络不如种地

你的鼓励将是我创作的最大动力

¥1 ¥2 ¥4 ¥6 ¥10 ¥20
扫码支付:¥1
获取中
扫码支付

您的余额不足,请更换扫码支付或充值

打赏作者

实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值