地址划分
72.16.0.0 16
172.16.0.0 19 ---骨干
172.16.0.0 24---P2P链路 /30
172.16.0.0 30 --172.16.0.1 172.16.0.2
172.16.0.4 30--- 172.16.0.5 172.16.0.6 30
172.16.0.8 30
...
172.16.1.0 24--MA链路 /29
172.16.1.0 29
172.16.1.8 29
172.16.1.16 29
172.16.1.24 29
...
172.16.2.0 24
172.16.3.0 24
..
172.16.31.0 24
172.16.32.0 19---区域1
172.16.32.0 24
172.16.32.0 30
172.16.32.4 30
172.16.32.8 30.。。。。
172.16.33.0 24
172.16.33.0 29
172.16.33.8 29
172.16.33.16 29 .。。。
172.16.34.0 24
172.16.35.0 24
.。。。172.16.63.0 24
172.16.64.0 19---区域2
172.16.64.0 24
172.16.64.0 30
172.16.64.4 30
172.16.64.8 30
172.16.65.0 24
172.16.65.0 29
172.16.65.8 29
172.16.65.16 29
172.16.66.0 24
.。。
172.16.96.0 19---区域3
172.16.128.0 19---区域4
172.16.160.0 19-----RIP
172.16.192.0 19
172.16.224.0 19---保留
配置公网ip
<Huawei>system-view
[Huawei]sysname r4
[r4]interface Serial 4/0/0
[r4-Serial4/0/0]ip add 34.1.1.2 24
[r4-Serial4/0/0]int s4/0/1
[r4-Serial4/0/1]ip add 45.1.1.2 24
[r4-Serial4/0/0]int s3/0/0
[r4-Serial3/0/0]ip add 46.1.1.2 24
[r4-Serial3/0/0]int s3/0/1
[r4-Serial3/0/1]ip add 47.1.1.2 24
<Huawei>system-view [Huawei]sysname r3
[r3]int s3/0/0
[r3-Serial3/0/0]ip add 34.1.1.1 24
<Huawei>system-view
[Huawei]sysname r5
[r5]int s4/0/0
[r5-Serial4/0/0]ip add 45.1.1.1 24
r6,r7按表配置
配置静态路由
[r3]ip route-static 0.0.0.0 0 34.1.1.2
[r5]ip route-static 0.0.0.0 0 45.1.1.2
[r6]ip route-static 0.0.0.0 0 46.1.1.2
[r7]ip route-static 0.0.0.0 0 47.1.1.2
配置环回地址
[r3]interface Tunnel 0/0/0
[r3-Tunnel0/0/0]ip add 172.16.0.129 29
[r3-Tunnel0/0/0]tunnel-protocol gre p2mp
[r3-Tunnel0/0/0]source 34.1.1.1
[r3-Tunnel0/0/0]nhrp entry multicast dynamic
[r3-Tunnel0/0/0]nhrp network-id 100
[r3]int g0/0/0
[r3-GigabitEthernet0/0/0]ip add 172.16.32.131 29
[r3-GigabitEthernet0/0/0]int l0
[r3-LoopBack0]ip add 172.16.34.1 25
[r3]ospf 1 router-id 3.3.3.3
[r3-ospf-1]area 1
[r3-ospf-1-area-0.0.0.1]network 172.16.32.0 0.0.3.255
[r3-ospf-1-area-0.0.0.1]q
[r3-ospf-1]area 0
[r3-ospf-1-area-0.0.0.0]network 172.16.0.129 0.0.0.0
[r5]int Tunnel 0/0/0
[r5-Tunnel0/0/0]ip add 172.16.0.130 29
[r5-Tunnel0/0/0]tunnel-protocol gre p2mp
[r5-Tunnel0/0/0]source 45.1.1.1
[r5-Tunnel0/0/0]nhrp network-id 100
[r5-Tunnel0/0/0]nhrp entry 172.16.0.129 34.1.1.1 register
[r5]int l0
[r5-LoopBack0]ip add 172.16.1.129 25
[r5-LoopBack0]q
[r5]ospf 1 router-id 5.5.5.5
[r5-ospf-1]area 0
[r5-ospf-1-area-0.0.0.0]network 172.16.0.0 0.0.255.255
[r6]interface Tunnel 0/0/0
[r6-Tunnel0/0/0]ip add 172.16.0.131 29
[r6-Tunnel0/0/0]tunnel-protocol gre p2mp
[r6-Tunnel0/0/0]source 46.1.1.1
[r6-Tunnel0/0/0]nhrp entry 172.16.0.129 34.1.1.1 register
[r6-Tunnel0/0/0]nhrp network-id 100
[r6]int l0
[r6-LoopBack0]ip add 172.16.2.1 25
[r6-LoopBack0]int g0/0/0
[r6-GigabitEthernet0/0/0]ip add 172.16.64.1 30
[r6]ospf 1 router-id 6.6.6.6
[r6-ospf-1]area 0
[r6-ospf-1-area-0.0.0.0]network 172.16.0.0 0.0.3.255
[r6-ospf-1-area-0.0.0.0]q
[r6-ospf-1]area 2
[r6-ospf-1-area-0.0.0.2]network 172.16.64.1 0.0.0.255
[r7]interface Tunnel 0/0/0
[r7-Tunnel0/0/0]ip add 172.16.0.132 29
[r7-Tunnel0/0/0]tunnel-protocol gre p2mp
[r7-Tunnel0/0/0]source 47.1.1.1
[r7-Tunnel0/0/0]nhrp entry 172.16.0.129 34.1.1.1 register
[r7-Tunnel0/0/0]nhrp network-id 100
[r7]int l0
[r7-LoopBack0]ip add 172.16.2.129 25
[r7-LoopBack0]int g0/0/0
[r7-GigabitEthernet0/0/0]ip add 172.16.96.1 30
[r7]ospf 1 router-id 7.7.7.7
[r7-ospf-1]area 0
[r7-ospf-1-area-0.0.0.0]network 172.16.0.0 0.0.3.255
[r7-ospf-1-area-0.0.0.0]q
[r7-ospf-1]area 3
[r7-ospf-1-area-0.0.0.3]network 172.16.96.1 0.0.0.0