需求
1 AS1存在两个环回,一个地址为192.168.1.0/24,该地址不能再任何协议中宣告
AS3存在两个环回,一个地址为192.168.2.0/24,该地址不能再任何协议中宣告
AS1还有一个环回地址为10.1.1.0/24,AS3另一个环回地址是11.1.1.0/24
最终要求这两个环回可以互相通讯。
2 整个AS2的IP地址为172.16.0.0/16
3 AS间的骨干链路IP地址随意分配
4 使用BGP协议让整个网络所有设备的环回可以互相访问
5 减少路由条目数量,避免环路出现
[V200R003C00]
#
sysname R1
#
snmp-agent local-engineid 800007DB03000000000000
snmp-agent
#
clock timezone China-Standard-Time minus 08:00:00
#
portal local-server load portalpage.zip
#
drop illegal-mac alarm
#
set cpu-usage threshold 80 restore 75
#
aaa
authentication-scheme default
authorization-scheme default
accounting-scheme default
domain default
domain default_admin
local-user admin password cipher %$%$K8m.Nt84DZ}e#<0`8bmE3Uw}%$%$
local-user admin service-type http
#
firewall zone Local
priority 15
#
interface GigabitEthernet0/0/0
ip address 12.1.1.1 255.255.255.0
#
interface GigabitEthernet0/0/1
#
interface GigabitEthernet0/0/2
#
interface NULL0
#
interface LoopBack0
ip address 192.168.1.1 255.255.255.0
#
interface LoopBack1
ip address 10.1.1.1 255.255.255.0
#
interface LoopBack2
ip address 1.1.1.1 255.255.255.0
#
bgp 1
router-id 1.1.1.1
peer 172.16.2.1 as-number 2
peer 172.16.2.1 ebgp-max-hop 2
peer 172.16.2.1 connect-interface LoopBack0
#
ipv4-family unicast
undo synchronization
network 10.1.1.0 255.255.255.0
peer 172.16.2.1 enable
#
ip route-static 172.16.2.1 255.255.255.255 12.0.0.2
#
user-interface con 0
authentication-mode password
user-interface vty 0 4
user-interface vty 16 20
#
wlan ac
#
return
[V200R003C00]
#
sysname R2
#
snmp-agent local-engineid 800007DB03000000000000
snmp-agent
#
clock timezone China-Standard-Time minus 08:00:00
#
portal local-server load portalpage.zip
#
drop illegal-mac alarm
#
set cpu-usage threshold 80 restore 75
#
aaa
authentication-scheme default
authorization-scheme default
accounting-scheme default
domain default
domain default_admin
local-user admin password cipher %$%$K8m.Nt84DZ}e#<0`8bmE3Uw}%$%$
local-user admin service-type http
#
firewall zone Local
priority 15
#
interface GigabitEthernet0/0/0
ip address 12.1.1.2 255.255.255.0
#
interface GigabitEthernet0/0/1
ip address 172.16.0.9 255.255.255.252
#
interface GigabitEthernet0/0/2
ip address 172.16.0.1 255.255.255.252
#
interface NULL0
#
interface LoopBack0
ip address 172.16.2.1 255.255.255.0
#
interface LoopBack2
ip address 2.2.2.2 255.255.255.0
#
bgp 64512
router-id 2.2.2.2
confederation id 2
confederation peer-as 64513
peer 172.16.3.1 as-number 64512
peer 172.16.3.1 connect-interface LoopBack0
peer 172.16.5.1 as-number 64513
peer 172.16.5.1 ebgp-max-hop 255
peer 172.16.5.1 connect-interface LoopBack0
peer 192.168.1.1 as-number 1
peer 192.168.1.1 ebgp-max-hop 2
peer 192.168.1.1 connect-interface LoopBack0
#
ipv4-family unicast
undo synchronization
network 172.16.0.0 255.255.248.0
peer 172.16.3.1 enable
peer 172.16.3.1 next-hop-local
peer 172.16.5.1 enable
peer 172.16.5.1 next-hop-local
peer 192.168.1.1 enable
#
ospf 1 router-id 2.2.2.2
area 0.0.0.0
network 172.16.0.0 0.0.255.255
#
ip route-static 172.16.0.0 255.255.248.0 NULL0
ip route-static 192.168.1.1 255.255.255.255 12.0.0.1
#
user-interface con 0
authentication-mode password
user-interface vty 0 4
user-interface vty 16 20
#
wlan ac
#
return
[V200R003C00]
#
sysname R3
#
snmp-agent local-engineid 800007DB03000000000000
snmp-agent
#
clock timezone China-Standard-Time minus 08:00:00
#
portal local-server load portalpage.zip
#
drop illegal-mac alarm
#
set cpu-usage threshold 80 restore 75
#
aaa
authentication-scheme default
authorization-scheme default
accounting-scheme default
domain default
domain default_admin
local-user admin password cipher %$%$K8m.Nt84DZ}e#<0`8bmE3Uw}%$%$
local-user admin service-type http
#
firewall zone Local
priority 15
#
interface GigabitEthernet0/0/0
ip address 172.16.0.2 255.255.255.252
#
interface GigabitEthernet0/0/1
ip address 172.16.0.5 255.255.255.252
#
interface GigabitEthernet0/0/2
#
interface NULL0
#
interface LoopBack0
ip address 172.16.3.1 255.255.255.0
#
bgp 64512
router-id 3.3.3.3
confederation id 2
peer 172.16.2.1 as-number 64512
peer 172.16.2.1 connect-interface LoopBack0
peer 172.16.4.1 as-number 64512
peer 172.16.4.1 connect-interface LoopBack0
#
ipv4-family unicast
undo synchronization
peer 172.16.2.1 enable
peer 172.16.2.1 reflect-client
peer 172.16.4.1 enable
peer 172.16.4.1 reflect-client
#
ospf 1 router-id 3.3.3.3
area 0.0.0.0
network 172.16.0.0 0.0.255.255
#
user-interface con 0
authentication-mode password
user-interface vty 0 4
user-interface vty 16 20
#
wlan ac
#
return
[V200R003C00]
#
sysname R4
#
snmp-agent local-engineid 800007DB03000000000000
snmp-agent
#
clock timezone China-Standard-Time minus 08:00:00
#
portal local-server load portalpage.zip
#
drop illegal-mac alarm
#
set cpu-usage threshold 80 restore 75
#
aaa
authentication-scheme default
authorization-scheme default
accounting-scheme default
domain default
domain default_admin
local-user admin password cipher %$%$K8m.Nt84DZ}e#<0`8bmE3Uw}%$%$
local-user admin service-type http
#
firewall zone Local
priority 15
#
interface GigabitEthernet0/0/0
ip address 172.16.0.6 255.255.255.252
#
interface GigabitEthernet0/0/1
ip address 172.16.0.13 255.255.255.252
#
interface GigabitEthernet0/0/2
#
interface NULL0
#
interface LoopBack0
ip address 172.16.4.1 255.255.255.0
#
bgp 64512
router-id 4.4.4.4
confederation id 2
confederation peer-as 64513
peer 172.16.3.1 as-number 64512
peer 172.16.3.1 connect-interface LoopBack0
peer 172.16.7.1 as-number 64513
peer 172.16.7.1 ebgp-max-hop 255
peer 172.16.7.1 connect-interface LoopBack0
#
ipv4-family unicast
undo synchronization
peer 172.16.3.1 enable
peer 172.16.3.1 next-hop-local
peer 172.16.7.1 enable
#
ospf 1 router-id 4.4.4.4
area 0.0.0.0
network 172.16.0.0 0.0.255.255
#
user-interface con 0
authentication-mode password
user-interface vty 0 4
user-interface vty 16 20
#
wlan ac
#
return
[V200R003C00]
#
sysname R5
#
snmp-agent local-engineid 800007DB03000000000000
snmp-agent
#
clock timezone China-Standard-Time minus 08:00:00
#
portal local-server load portalpage.zip
#
drop illegal-mac alarm
#
set cpu-usage threshold 80 restore 75
#
aaa
authentication-scheme default
authorization-scheme default
accounting-scheme default
domain default
domain default_admin
local-user admin password cipher %$%$K8m.Nt84DZ}e#<0`8bmE3Uw}%$%$
local-user admin service-type http
#
firewall zone Local
priority 15
#
interface GigabitEthernet0/0/0
ip address 172.16.9.10 255.255.255.252
#
interface GigabitEthernet0/0/1
ip address 172.16.0.17 255.255.255.252
#
interface GigabitEthernet0/0/2
#
interface NULL0
#
interface LoopBack0
ip address 172.16.5.1 255.255.255.0
#
bgp 64513
router-id 5.5.5.5
confederation id 2
confederation peer-as 64512
peer 172.16.2.1 as-number 64512
peer 172.16.2.1 ebgp-max-hop 255
peer 172.16.2.1 connect-interface LoopBack0
peer 172.16.6.1 as-number 64513
peer 172.16.6.1 connect-interface LoopBack0
#
ipv4-family unicast
undo synchronization
peer 172.16.2.1 enable
peer 172.16.6.1 enable
peer 172.16.6.1 next-hop-local
#
ospf 1 router-id 5.5.5.5
area 0.0.0.0
network 172.16.0.0 0.0.255.255
#
user-interface con 0
authentication-mode password
user-interface vty 0 4
user-interface vty 16 20
#
wlan ac
#
return
[V200R003C00]
#
sysname R6
#
snmp-agent local-engineid 800007DB03000000000000
snmp-agent
#
clock timezone China-Standard-Time minus 08:00:00
#
portal local-server load portalpage.zip
#
drop illegal-mac alarm
#
set cpu-usage threshold 80 restore 75
#
aaa
authentication-scheme default
authorization-scheme default
accounting-scheme default
domain default
domain default_admin
local-user admin password cipher %$%$K8m.Nt84DZ}e#<0`8bmE3Uw}%$%$
local-user admin service-type http
#
firewall zone Local
priority 15
#
interface GigabitEthernet0/0/0
ip address 172.16.0.18 255.255.255.252
#
interface GigabitEthernet0/0/1
ip address 172.16.0.21 255.255.255.252
#
interface GigabitEthernet0/0/2
#
interface NULL0
#
interface LoopBack0
ip address 172.16.6.1 255.255.255.0
#
bgp 64513
router-id 6.6.6.6
confederation id 2
peer 172.16.5.1 as-number 64513
peer 172.16.5.1 connect-interface LoopBack0
peer 172.16.7.1 as-number 64513
peer 172.16.7.1 connect-interface LoopBack0
#
ipv4-family unicast
undo synchronization
peer 172.16.5.1 enable
peer 172.16.5.1 reflect-client
peer 172.16.7.1 enable
peer 172.16.7.1 reflect-client
#
ospf 1 router-id 6.6.6.6
area 0.0.0.0
network 172.16.0.0 0.0.255.255
#
user-interface con 0
authentication-mode password
user-interface vty 0 4
user-interface vty 16 20
#
wlan ac
#
return
[V200R003C00]
#
sysname R7
#
snmp-agent local-engineid 800007DB03000000000000
snmp-agent
#
clock timezone China-Standard-Time minus 08:00:00
#
portal local-server load portalpage.zip
#
drop illegal-mac alarm
#
set cpu-usage threshold 80 restore 75
#
aaa
authentication-scheme default
authorization-scheme default
accounting-scheme default
domain default
domain default_admin
local-user admin password cipher %$%$K8m.Nt84DZ}e#<0`8bmE3Uw}%$%$
local-user admin service-type http
#
firewall zone Local
priority 15
#
interface GigabitEthernet0/0/0
ip address 172.16.0.22 255.255.255.252
#
interface GigabitEthernet0/0/1
ip address 172.16.0.14 255.255.255.252
#
interface GigabitEthernet0/0/2
ip address 78.1.1.7 255.255.255.0
#
interface NULL0
#
interface LoopBack0
ip address 172.16.7.1 255.255.255.0
#
bgp 64513
confederation id 2
confederation peer-as 64512
peer 172.16.4.1 as-number 64512
peer 172.16.4.1 ebgp-max-hop 255
peer 172.16.4.1 connect-interface LoopBack0
peer 172.16.6.1 as-number 64513
peer 172.16.6.1 connect-interface LoopBack0
peer 192.168.2.1 as-number 3
peer 192.168.2.1 ebgp-max-hop 2
peer 192.168.2.1 connect-interface LoopBack0
#
ipv4-family unicast
undo synchronization
network 172.16.0.0 255.255.248.0
peer 172.16.4.1 enable
peer 172.16.4.1 next-hop-local
peer 172.16.6.1 enable
peer 172.16.6.1 next-hop-local
peer 192.168.2.1 enable
#
ospf 1 router-id 7.7.7.7
area 0.0.0.0
network 172.16.0.0 0.0.255.255
#
ip route-static 172.16.0.0 255.255.248.0 NULL0
ip route-static 192.168.2.1 255.255.255.255 78.0.0.8
#
user-interface con 0
authentication-mode password
user-interface vty 0 4
user-interface vty 16 20
#
wlan ac
#
return
[V200R003C00]
#
sysname R8
#
snmp-agent local-engineid 800007DB03000000000000
snmp-agent
#
clock timezone China-Standard-Time minus 08:00:00
#
portal local-server load portalpage.zip
#
drop illegal-mac alarm
#
set cpu-usage threshold 80 restore 75
#
aaa
authentication-scheme default
authorization-scheme default
accounting-scheme default
domain default
domain default_admin
local-user admin password cipher %$%$K8m.Nt84DZ}e#<0`8bmE3Uw}%$%$
local-user admin service-type http
#
firewall zone Local
priority 15
#
interface GigabitEthernet0/0/0
ip address 78.1.1.8 255.255.255.0
#
interface GigabitEthernet0/0/1
#
interface GigabitEthernet0/0/2
#
interface NULL0
#
interface LoopBack0
ip address 192.168.2.1 255.255.255.0
#
interface LoopBack1
ip address 11.1.1.1 255.255.255.0
#
bgp 3
router-id 8.8.8.8
peer 172.16.7.1 as-number 2
peer 172.16.7.1 ebgp-max-hop 2
peer 172.16.7.1 connect-interface LoopBack0
#
ipv4-family unicast
undo synchronization
network 11.1.1.0 255.255.255.0
peer 172.16.7.1 enable
#
ip route-static 172.16.7.1 255.255.255.255 78.0.0.7
#
user-interface con 0
authentication-mode password
user-interface vty 0 4
user-interface vty 16 20
#
wlan ac
#
return