[Review]RIP PE-CE Routing

RIP 是个基本上快要过时的协议 , 在工程上应用的已经很少了, 由于自身设计的不完善。 但是在广大的认证,考试 面试中还屡屡被提及。

比如juniper的 LAB 总是会时不时搞个 rip 和 ISIS 或OSPF之间的双向分发,C公司更是有趣没事老是搞些 RIP 和 EGRIP的双向分发问题,可见 RIP这个东西还是要摸透的,向往C公司的同学 还必须把EGRIP 搞透, 我不喜欢这份强势, 很多东西用 ospf或ISIS就能搞定, 没必要非要扯上EGRIP吧, 没必要每个网络工作者都要搞明白一个公司的私有协议吧,大部分时间看看RFC上的就足够了。

发了半天牢骚,言归正传,还是温习一下RIP多实例(multi-instance)的配置和 验证吧。

1. PE路由器上的配置模板

2. PE 和 CE 端的 配置

#####R1####

version 12.4
service timestamps debug datetime msec
service timestamps log datetime msec
no service password-encryption
!
hostname Router
!
boot-start-marker
boot-end-marker
!
no aaa new-model
!
resource policy
!
ip subnet-zero
ip cef
!
no ip dhcp use vrf connected!
!
no ip ips deny-action ips-interface
!
interface Loopback0
 ip address 1.1.1.1 255.255.255.255
!

interface FastEthernet0/0
 no ip address
 shutdown
 duplex half
!
interface FastEthernet1/0
 ip address 172.16.10.2 255.255.255.252
 duplex auto
 speed auto
!

interface FastEthernet1/1
 no ip address
 shutdown
 duplex auto
 speed auto
!
router rip
 version 2
 network 1.0.0.0
 network 172.16.0.0
 no auto-summary
!

ip classless
no ip http server
no ip http secure-server!
!
control-plane!
!
gatekeeper
 shutdown!
!
line con 0
 stopbits 1
line aux 0
 stopbits 1
line vty 0 4
 login!
!
end

 

 

######R2(PE1)######

Current configuration : 1901 bytes
!
version 12.4
service timestamps debug datetime msec
service timestamps log datetime msec
no service password-encryption
!
hostname Router
!
boot-start-marker
boot-end-marker
!
!
no aaa new-model
!
resource policy
!
ip subnet-zero
ip cef
!
!
no ip dhcp use vrf connected
!
!
ip vrf 1
 rd 1:100
 route-target export 1:100
 route-target import 1:100
!

no ip ips deny-action ips-interface
!
mpls label protocol ldp
mpls ldp router-id Loopback0
!
!
interface Loopback0
 ip address 10.10.10.101 255.255.255.255
!
interface FastEthernet0/0
 no ip address
 shutdown
 duplex half
!
interface FastEthernet1/0
 ip vrf forwarding 1
 ip address 172.16.10.1 255.255.255.252
 duplex auto
 speed auto
!
interface FastEthernet1/1
 no ip address
 shutdown
 duplex auto
 speed auto
!
interface ATM2/0
 ip address 10.10.10.1 255.255.255.252
 ip ospf network broadcast
 no atm ilmi-keepalive
 mpls ip
 pvc 2/200
  broadcast
  encapsulation aal5snap
 !
!
router ospf 1
 log-adjacency-changes
 network 0.0.0.0 255.255.255.255 area 0
!
router rip
 version 2
 !
 address-family ipv4 vrf 1
 redistribute bgp 1 metric transparent  !这条命令的作用就是通过MBGP原封不动的copy rip的metric供CE使用。
 network 172.16.0.0
 no auto-summary
 exit-address-family
!

router bgp 1
 no synchronization
 bgp log-neighbor-changes
 neighbor 10.10.10.102 remote-as 1
 neighbor 10.10.10.102 update-source Loopback0
 no auto-summary
 !
 address-family v4
 neighbor 10.10.10.102 activate
 neighbor 10.10.10.102 send-community extended
 exit-address-family
 !
 address-family ipv4 vrf 1
 redistribute connected
 redistribute static
 redistribute rip
 no auto-summary
 no synchronization
 exit-address-family
!

ip classless
ip route vrf 1 1.1.1.1 255.255.255.255 172.16.10.2
no ip http server
no ip http secure-server
!
!
control-plane
!
!
gatekeeper
 shutdown
!
!
line con 0
 stopbits 1
line aux 0
 stopbits 1
line vty 0 4
 login
!
!
end

 

######R5(PE2)###

!
version 12.4
service timestamps debug datetime msec
service timestamps log datetime msec
no service password-encryption
!
hostname Router
!
boot-start-marker
boot-end-marker
!
!
no aaa new-model
!
resource policy
!
ip subnet-zero
ip cef
!
!
no ip dhcp use vrf connected
!
!
ip vrf 1
 rd 1:100
 route-target export 1:100
 route-target import 1:100
!
no ip ips deny-action ips-interface
!
mpls label protocol ldp
mpls ldp router-id Loopback0
!
interface Loopback0
 ip address 10.10.10.102 255.255.255.255
!
interface FastEthernet0/0
 no ip address
 shutdown
 duplex half
!
interface FastEthernet1/0
 ip vrf forwarding 1
 ip address 172.16.20.1 255.255.255.252
 duplex auto
 speed auto
!
interface FastEthernet1/1
 no ip address
 shutdown
 duplex auto
 speed auto
!
interface ATM2/0
 ip address 10.10.10.10 255.255.255.252
 ip ospf network broadcast
 no atm ilmi-keepalive
 mpls ip
 pvc 2/400
  broadcast
  encapsulation aal5snap
 !
!
router ospf 1
 log-adjacency-changes
 network 0.0.0.0 255.255.255.255 area 0
!
router rip
 version 2
 !
 address-family ipv4 vrf 1
 redistribute bgp 1 metric transparent
 network 172.16.0.0
 no auto-summary
 exit-address-family
!

router bgp 1
 no synchronization
 bgp log-neighbor-changes
 neighbor 10.10.10.101 remote-as 1
 neighbor 10.10.10.101 update-source Loopback0
 no auto-summary
 !
 address-family v4
 neighbor 10.10.10.101 activate
 neighbor 10.10.10.101 send-community extended
 exit-address-family
 !
 address-family ipv4 vrf 1
 redistribute connected
 redistribute static
 redistribute rip
 no auto-summary
 no synchronization
 exit-address-family
!

ip classless
ip route vrf 1 6.6.6.6 255.255.255.255 172.16.20.2
no ip http server
no ip http secure-server
!
control-plane
!
gatekeeper
 shutdown
!
!
line con 0
 stopbits 1
line aux 0
 stopbits 1
line vty 0 4
 login
!
!
end
#R6 (CE2)######

 

!
version 12.4
service timestamps debug datetime msec
service timestamps log datetime msec
no service password-encryption
!
hostname Router
!
boot-start-marker
boot-end-marker
!
!
no aaa new-model
!
resource policy
!
ip subnet-zero
ip cef
!
!
no ip dhcp use vrf connected
!
!
no ip ips deny-action ips-interface
!
interface Loopback0
 ip address 6.6.6.6 255.255.255.255
!
interface FastEthernet0/0
 no ip address
 shutdown
 duplex half
!
interface FastEthernet1/0
 ip address 172.16.20.2 255.255.255.252
 duplex auto
 speed auto
!
interface FastEthernet1/1
 no ip address
 shutdown
 duplex auto
 speed auto
!
router rip
 version 2
 network 6.0.0.0
 network 172.16.0.0
 no auto-summary
!

ip classless
no ip http server
no ip http secure-server
!
!
control-plane!
!
!
gatekeeper
 shutdown
!
!
line con 0
 stopbits 1
line aux 0
 stopbits 1
line vty 0 4
 login
!
!
end

 

3. 接下来还要提的是 与RIP version 1的兼容问题

只需要在绑定VPN的借口下做相应的配置即可。

ip rip send version 1

 

ip rip receive version 1

 

你可能感兴趣的:(Networking)