每个路由器配置:
R1配置:
#
interface GigabitEthernet0/0/0
ip address 192.168.16.2 255.255.255.0
#
interface GigabitEthernet0/0/1
ip address 192.168.12.1 255.255.255.0
#
interface GigabitEthernet0/0/2
ip address 192.168.17.1 255.255.255.0
#
interface NULL0
#
interface LoopBack0
ip address 10.10.1.1 255.255.255.0
#
bgp 64512
router-id 1.1.1.1
confederation id 100
peer 10.10.2.2 as-number 64512
peer 10.10.2.2 connect-interface LoopBack0
peer 192.168.16.6 as-number 200
peer 192.168.17.7 as-number 200
#
ipv4-family unicast
undo synchronization
import-route direct
peer 10.10.2.2 enable
peer 10.10.2.2 next-hop-local
peer 192.168.16.6 enable
peer 192.168.17.7 enable
#
ospf 1 router-id 1.1.1.1
area 0.0.0.0
network 10.10.1.1 0.0.0.0
network 192.168.12.0 0.0.0.255
AR2配置:
#
interface GigabitEthernet0/0/0
ip address 192.168.12.2 255.255.255.0
#
interface GigabitEthernet0/0/1
ip address 192.168.23.2 255.255.255.0
#
interface GigabitEthernet0/0/2
#
interface NULL0
#
interface LoopBack0
ip address 10.10.2.2 255.255.255.0
#
bgp 64512
router-id 2.2.2.2
confederation id 100
peer 10.10.1.1 as-number 64512
peer 10.10.1.1 connect-interface LoopBack0
peer 10.10.3.3 as-number 64512
peer 10.10.3.3 connect-interface LoopBack0
#
ipv4-family unicast
undo synchronization
peer 10.10.1.1 enable
peer 10.10.1.1 reflect-client
peer 10.10.3.3 enable
#
ospf 1 router-id 2.2.2.2
area 0.0.0.0
network 10.10.2.2 0.0.0.0
network 192.168.12.0 0.0.0.255
network 192.168.23.0 0.0.0.255
AR3配置:
#
interface GigabitEthernet0/0/0
ip address 192.168.23.3 255.255.255.0
#
interface GigabitEthernet0/0/1
ip address 192.168.34.3 255.255.255.0
#
interface GigabitEthernet0/0/2
#
interface NULL0
#
interface LoopBack0
ip address 10.10.3.3 255.255.255.0
#
bgp 64512
router-id 3.3.3.3
confederation id 100
confederation peer-as 64513
peer 10.10.2.2 as-number 64512
peer 10.10.2.2 connect-interface LoopBack0
peer 192.168.34.4 as-number 64513
#
ipv4-family unicast
undo synchronization
peer 10.10.2.2 enable
peer 192.168.34.4 enable
#
ospf 1 router-id 3.3.3.3
area 0.0.0.0
network 10.10.3.3 0.0.0.0
network 192.168.23.0 0.0.0.255
network 192.168.34.0 0.0.0.255
AR4配置:
#
interface GigabitEthernet0/0/0
ip address 192.168.34.4 255.255.255.0
#
interface GigabitEthernet0/0/1
ip address 192.168.45.4 255.255.255.0
#
interface GigabitEthernet0/0/2
#
interface NULL0
#
interface LoopBack0
ip address 10.10.4.4 255.255.255.0
#
bgp 64513
confederation id 100
confederation peer-as 64512
peer 10.10.5.5 as-number 64513
peer 10.10.5.5 connect-interface LoopBack0
peer 192.168.34.3 as-number 64512
#
ipv4-family unicast
undo synchronization
peer 10.10.5.5 enable
peer 192.168.34.3 enable
#
ospf 1 router-id 4.4.4.4
area 0.0.0.0
network 10.10.4.4 0.0.0.0
network 192.168.34.0 0.0.0.255
network 192.168.45.0 0.0.0.255
AR5配置:
#
interface GigabitEthernet0/0/0
ip address 192.168.45.5 255.255.255.0
#
interface GigabitEthernet0/0/1
ip address 192.168.59.5 255.255.255.0
#
interface GigabitEthernet0/0/2
ip address 192.168.20.254 255.255.255.0
#
interface NULL0
#
interface LoopBack0
ip address 10.10.5.5 255.255.255.0
#
bgp 64513
confederation id 100
peer 10.10.4.4 as-number 64513
peer 10.10.4.4 connect-interface LoopBack0
peer 192.168.59.9 as-number 900
#
ipv4-family unicast
undo synchronization
network 192.168.20.0
peer 10.10.4.4 enable
peer 10.10.4.4 next-hop-local
peer 192.168.59.9 enable
#
ospf 1 router-id 5.5.5.5
area 0.0.0.0
network 10.10.5.5 0.0.0.0
network 192.168.45.0 0.0.0.255
AR6配置:
#
interface GigabitEthernet0/0/0
ip address 192.168.68.6 255.255.255.0
#
interface GigabitEthernet0/0/1
ip address 192.168.16.6 255.255.255.0
#
interface GigabitEthernet0/0/2
#
interface NULL0
#
interface LoopBack0
ip address 10.10.6.6 255.255.255.0
#
bgp 200
peer 10.10.8.8 as-number 200
peer 10.10.8.8 connect-interface LoopBack0
peer 192.168.16.2 as-number 100
#
ipv4-family unicast
undo synchronization
peer 10.10.8.8 enable
peer 10.10.8.8 next-hop-local
peer 192.168.16.2 enable
#
rip 1
version 2
network 10.0.0.0
network 192.168.68.0
AR7配置:
#
interface GigabitEthernet0/0/0
ip address 192.168.78.7 255.255.255.0
#
interface GigabitEthernet0/0/1
#
interface GigabitEthernet0/0/2
ip address 192.168.17.7 255.255.255.0
#
interface NULL0
#
interface LoopBack0
ip address 10.10.7.7 255.255.255.0
#
bgp 200
peer 10.10.8.8 as-number 200
peer 10.10.8.8 connect-interface LoopBack0
peer 192.168.17.1 as-number 100
#
ipv4-family unicast
undo synchronization
peer 10.10.8.8 enable
peer 10.10.8.8 next-hop-local
peer 192.168.17.1 enable
#
rip 1
version 2
network 10.0.0.0
network 192.168.78.0
AR8配置:
#
interface GigabitEthernet0/0/0
ip address 192.168.68.8 255.255.255.0
#
interface GigabitEthernet0/0/1
ip address 192.168.78.8 255.255.255.0
#
interface GigabitEthernet0/0/2
ip address 192.168.30.254 255.255.255.0
#
interface NULL0
#
interface LoopBack0
ip address 10.10.8.8 255.255.255.0
#
bgp 200
peer 10.10.6.6 as-number 200
peer 10.10.6.6 connect-interface LoopBack0
peer 10.10.7.7 as-number 200
peer 10.10.7.7 connect-interface LoopBack0
#
ipv4-family unicast
undo synchronization
network 192.168.30.0
peer 10.10.6.6 enable
peer 10.10.7.7 enable
#
rip 1
version 2
network 10.0.0.0
network 192.168.78.0
network 192.168.68.0
AR9配置:
#
interface GigabitEthernet0/0/0
ip address 192.168.40.254 255.255.255.0
#
interface GigabitEthernet0/0/1
ip address 192.168.59.9 255.255.255.0
#
interface GigabitEthernet0/0/2
#
interface NULL0
#
bgp 900
peer 192.168.59.5 as-number 100
#
ipv4-family unicast
undo synchronization
import-route direct
peer 192.168.59.5 enable
原文地址:http://blog.51cto.com/13585615/2083949