BGP权重实验

R1 配置 :
r1#show running-config
Building configuration...
 
Current configuration : 1299 bytes
!
version 12.3
service timestamps debug datetime msec
service timestamps log datetime msec
no service password-encryption
!
hostname r1
!
boot-start-marker
boot-end-marker
!
!
memory-size iomem 5
no aaa new-model
ip subnet-zero
!
!
no ip domain lookup
!
!
ip cef
ip ips po max-events 100
no ftp-server write-enable
!
interface Loopback1
 ip address 1.1.1 .1 255.255.255.0
!
interface Serial0/0
 ip address 192.168.1.1 255.255.255.0
 serial restart-delay 0
!
interface Serial0/1
 ip address 192.168.3.1 255.255.255.0
 serial restart-delay 0
!
interface Serial0/2
 no ip address
 shutdown
 serial restart-delay 0
!
interface Serial0/3
 no ip address
 shutdown
 serial restart-delay 0
!
router ospf 1
 log-adjacency-changes
 network 1.1.1 .0 0.0.0.255 area 0
 network 192.168.3.0 0.0.0 .255 area 0
!
router bgp 200
 no synchronization
 bgp router-id 1.1.1 .1
 bgp log-neighbor-changes
 neighbor r1 peer-group
 neighbor r1 remote-as 200
 neighbor r1 update-source Loopback1
 neighbor r1 next-hop-self
 neighbor 3.3.3 .3 peer-group r1
 neighbor 4.4.4 .4 peer-group r1
 neighbor 192.168.1.2 remote-as 100
 no auto-summary
!
ip http server
no ip http secure-server
ip classless
!
control-plane
!
!
line con 0
line aux 0
line vty 0 4
 login
!
!
end
 
 
 
 
======================================================================
R2 配置:
r2#show running-config
Building configuration...
 
Current configuration : 1233 bytes
!
version 12.3
service timestamps debug datetime msec
service timestamps log datetime msec
no service password-encryption
!
hostname r2
!
boot-start-marker
boot-end-marker
!
!
memory-size iomem 5
no aaa new-model
ip subnet-zero
!
!
no ip domain lookup
!
!
ip cef
ip ips po max-events 100
no ftp-server write-enable
!
 
interface Loopback21
 ip address 2.2.2 .2 255.255.255.0
!
interface Loopback22
 ip address 22.22.22 .22 255.255.255.0
!
interface Serial0/0
 ip address 192.168.1.2 255.255.255.0
 serial restart-delay 0
!
interface Serial0/1
 ip address 192.168.2.1 255.255.255.0
 serial restart-delay 0
!
interface Serial0/2
 no ip address
 shutdown
 serial restart-delay 0
!
interface Serial0/3
 no ip address
 shutdown
 serial restart-delay 0
!
router bgp 100
 no synchronization
 bgp router-id 2.2.2 .2
 bgp log-neighbor-changes
 network 2.2.2 .0 mask 255.255.255.0
 network 22.22.22 .0 mask 255.255.255.0
 neighbor r2 peer-group
 neighbor r2 remote-as 200
 neighbor 192.168.1.1 peer-group r2
 neighbor 192.168.2.2 peer-group r2
 no auto-summary
!
ip http server
no ip http secure-server
ip classless
!
control-plane
!
line con 0
line aux 0
line vty 0 4
 login
!
!
End
 
 
=====================================================================
R3 配置:
r3#show running-config
Building configuration...
 
Current configuration : 1673 bytes
!
version 12.3
service timestamps debug datetime msec
service timestamps log datetime msec
no service password-encryption
!
hostname r3
!
boot-start-marker
boot-end-marker
!
!
memory-size iomem 5
no aaa new-model
ip subnet-zero
!
!
no ip domain lookup
!
!
ip cef
ip ips po max-events 100
no ftp-server write-enable
!
interface Loopback3
 ip address 3.3.3 .3 255.255.255.0
!
interface Serial0/0
 no ip address
 shutdown
 serial restart-delay 0
!
interface Serial0/1
 ip address 192.168.3.2 255.255.255.0
 serial restart-delay 0
!
interface Serial0/2
 no ip address
 shutdown
 serial restart-delay 0
!
interface Serial0/3
 no ip address
 shutdown
 serial restart-delay 0
!
interface FastEthernet1/0
 ip address 192.168.4.1 255.255.255.0
 duplex auto
 speed auto
!
router ospf 1
 log-adjacency-changes
 network 3.3.3 .0 0.0.0.255 area 0
 network 192.168.3.0 0.0.0 .255 area 0
 network 192.168.4.0 0.0.0 .255 area 0
!
router bgp 200
 no synchronization
 bgp router-id 3.3.3 .3
 bgp log-neighbor-changes
 network 3.3.3 .0 mask 255.255.255.0
 neighbor huawei peer-group
 neighbor huawei remote-as 200
 neighbor huawei update-source Loopback3
 neighbor huawei next-hop-self
 neighbor 1.1.1 .1 peer-group huawei
 neighbor 1.1.1 .1 route-map ro in
 neighbor 4.4.4 .4 peer-group huawei
 no auto-summary
!
ip http server
no ip http secure-server
ip classless
!
ip prefix-list cisco seq 5 permit 2.2.2 .0/24
!
ip prefix-list huawei seq 5 permit 22.22.22 .0/24
!
route-map ro permit 10
 match ip address prefix-list cisco
 set weight 100
!
route-map ro permit 20
!
control-plane
!
line con 0
line aux 0
line vty 0 4
 login
!
!
End
 
 
 
=====================================================================
R4 配置:
r4#show running-config
Building configuration...
 
Current configuration : 1377 bytes
!
version 12.3
service timestamps debug datetime msec
service timestamps log datetime msec
no service password-encryption
!
hostname r4
!
boot-start-marker
boot-end-marker
!
!
memory-size iomem 5
no aaa new-model
ip subnet-zero
!
!
no ip domain lookup
!
ip cef
ip ips po max-events 100
no ftp-server write-enable
!
interface Loopback4
 ip address 4.4.4 .4 255.255.255.0
!
interface Serial0/0
 no ip address
 shutdown
 serial restart-delay 0
!
interface Serial0/1
 ip address 192.168.2.2 255.255.255.0
 serial restart-delay 0
!
interface Serial0/2
 no ip address
 shutdown
 serial restart-delay 0
!
interface Serial0/3
 no ip address
 shutdown
 serial restart-delay 0
!
interface FastEthernet1/0
 ip address 192.168.4.2 255.255.255.0
 duplex auto
 speed auto
!
router ospf 1
 log-adjacency-changes
 network 4.4.4 .0 0.0.0.255 area 0
 network 192.168.4.0 0.0.0 .255 area 0
!
router bgp 200
 no synchronization
 bgp router-id 4.4.4 .4
 bgp log-neighbor-changes
 neighbor r4 peer-group
 neighbor r4 remote-as 200
 neighbor r4 update-source Loopback4
 neighbor r4 next-hop-self
 neighbor 1.1.1 .1 peer-group r4
 neighbor 3.3.3 .3 peer-group r4
 neighbor 192.168.2.1 remote-as 100
 no auto-summary
!
ip http server
no ip http secure-server
ip classless
!
control-plane
!
line con 0
line aux 0
line vty 0 4
 login
!
!
end
 

你可能感兴趣的:(职场,休闲,BGP,配置案例,权重实验)