1.分别配置ip地址
[r6]interface g0/0/0
[r6-GigabitEthernet0/0/0]ip address 67.1.1.1 24
[r6]interface g0/0/1
[r6-GigabitEthernet0/0/0]ip address 172.16.1.1 24
[r6]interface g0/0/2
[r6-GigabitEthernet0/0/0]ip address 16.1.1.1 24
[r1]interface g0/0/0
[r1-GigabitEthernet0/0/0]ip address 16.1.1.1 24
[r1]interface g0/0/1
[r1-GigabitEthernet0/0/0]ip address 12.1.1.1 24
[r1]interface g0/0/2
[r1-GigabitEthernet0/0/0]ip address 21.1.1.1 24
[r1]interface g4/0/0
[r1-GigabitEthernet4/0/0]ip address 13.1.1.1 24
[r2]interface g0/0/0
[r2-GigabitEthernet0/0/0]ip address 12.1.1.2 24
[r2]interface g0/0/1
[r2-GigabitEthernet0/0/0]ip address 21.1.1.2 24
[r2]interface g0/0/2
[r2-GigabitEthernet0/0/0]ip address 24.1.1.1 24
[r3]interface g0/0/0
[r3-GigabitEthernet0/0/0]ip address 13.1.1.2 24
[r3]interface g0/0/1
[r3-GigabitEthernet0/0/0]ip address 34.1.1.1 24
[r3]interface g0/0/2
[r3-GigabitEthernet0/0/0]ip address 43.1.1.1 24
[r4]interface g0/0/0
[r4-GigabitEthernet0/0/0]ip address 24.1.1.2 24
[r4]interface g0/0/1
[r4-GigabitEthernet0/0/0]ip address 34.1.1.2 24
[r4]interface g0/0/2
[r4-GigabitEthernet0/0/0]ip address 43.1.1.2 24
[r4]interface g4/0/0
[r4-GigabitEthernet4/0/0]ip address 45.1.1.1 24
[r5]interface g0/0/0
[r5-GigabitEthernet0/0/0]ip address 192.168.1.1 24
[r5]interface g0/0/1
[r5-GigabitEthernet0/0/0]ip address 192.168.2.1 24
[r5]interface g0/0/2
[r5-GigabitEthernet0/0/0]ip address 45.1.1.2 24
2.测试互通
3.pc的网段(DHCP)
[r6]dhcp enable
[r6]ip pool 1
Info: It's successful to create an IP address pool.
[r6-ip-pool-1]network 172.16.1.0 mask 255.255.255.0
[r6-ip-pool-1]gateway-list 172.16.1.1
[r6-ip-pool-1]dns-list 8.8.8.8 114.114.114.114
[r6]interface g0/0/0
[r6-GigabitEthernet0/0/0]dhcp select globa
[r5]dhcp enable
[r5]ip pool 1
Info: It's successful to create an IP address pool.
[r5-ip-pool-1]network 192.168.1.0 mask 255.255.255.0
[r5-ip-pool-1]gateway-list 192.168.1.1
[r5-ip-pool-1]dns-list 8.8.8.8 114.114.114.114
[r5]ip pool 2
Info: It's successful to create an IP address pool.
[r5-ip-pool-2]network 192.168.2.0 mask 255.255.255.0
[r5-ip-pool-2]gateway-list 192.168.2.1
[r5-ip-pool-2]dns-list 8.8.8.8 114.114.114.114
[r5]interface g0/0/0
[r5-GigabitEthernet0/0/0]dhcp select globa
[r5]interface g0/0/1
[r5-GigabitEthernet0/0/0]dhcp select globa
4.做静态
[r6]ip route-static 12.1.1.0 24 16.1.1.2
[r6]ip route-static 21.1.1.0 24 16.1.1.2
[r6]ip route-static 24.1.1.0 24 16.1.1.2
[r6]ip route-static 13.1.1.0 24 16.1.1.2
[r6]ip route-static 34.1.1.0 24 16.1.1.2
[r6]ip route-static 43.1.1.0 24 16.1.1.2
[r6]ip route-static 45.1.1.0 24 16.1.1.2
[r6]ip route-static 192.168.0.0 22 16.1.1.2
[r1]ip route-static 172.16.1.0 24 16.1.1.1
[r1]ip route-static 24.1.1.0 24 12.1.1.2
[r1]ip route-static 24.1.1.0 24 21.1.1.2 preference 61
[r1]ip route-static 192.168.0.0 22 12.1.1.2
[r1]ip route-static 192.168.0.0 22 21.1.1.2 preference 61
[r2]ip route-static 16.1.1.0 24 12.1.1.1
[r2]ip route-static 16.1.1.0 24 21.1.1.1 preference 61
[r2]ip route-static 172.16.1.0 24 12.1.1.1
[r2]ip route-static 172.16.1.0 24 21.1.1.1 preference 61
[r2]ip route-static 45.1.1.0 24 12.1.1.2
[r2]ip route-static 192.168.0.0 22 12.1.1.2
r3 r4 r5省略
5.写缺省
[r6]ip route-static 0.0.0.0 0 67.1.1.2
[r1]ip route-static 0.0.0.0 0 16.1.1.1
[r2]ip route-static 0.0.0.0 0 12.1.1.1
[r2]ip route-static 0.0.0.0 0 21.1.1.1 preference 61
[r3]ip route-static 0.0.0.0 0 13.1.1.1
[r4]ip route-static 0.0.0.0 0 24.1.1.1
[r5]ip route-static 0.0.0.0 0 45.1.1.1
6.在汇总的路由器上防环
[r5]ip route-static 192.168.0.0 22 NULL 0
465

被折叠的 条评论
为什么被折叠?



