静态路由综合配置实验

 

要求:

1、 全网用192.168.1.0/24进行p地址分配

2 、AR5作为DHCP服务器为PC分配IP地址

3、路由上均具备2个环回地址

4、AR4与AR5之间正常走1000M,备份走100M

5、全网尽量负载均衡

6、减少路由表数量,并避免环路产生

7、全网可达

思路:

1、子网划分17个网段

2、DHCP配置

3、环回接口

4、浮动静态路由

5、等价路由

6、缺省路由、汇总路由、空接口防环

7、能ping通包括环回在内的全网

配置:

配置设备IP和环回IP

192.168.1.0/24
192.168.1.000 00000/27----骨干链路
 192.168.1.000 000 00/30---192.168.1.0/30
 192.168.1.000 001 08/30---192.168.1.4/30
 192.168.1.000 010 00/30---192.168.1.8/30
 192.168.1.000 011 00/30---192.168.1.12/30
 192.168.1.080 108 00/30---192.168.1.16/30
 192.168.1.000 101 00/30---192.168.1.20/30
 192.168.1.000 110 00/30---192.168.1.24/30保留
 192.168.1.000 111 00/30---192.168.1.28/30保留
192.168.1.001 00000/ 27----R1环回
 192.168.1.001 0 0000/28---192.168.1.32/28
 192.168.1.001 1 0000/28---192.168.1.48/28
192.168.1.010 00000/27----R2环回
 192.168.1.010 0 0000/28---192.168.1.64/28
 192.168.1.010 1 0000/28---192.168.1.80/28
192.168.1.011 00000/27----R3环回
 192.168.1.011 0 0000/28---192.168.1.96/28
 192.168.1.011 1 0000/28---192.168.1.112/28
192.168.1.100 00000/27----R4环回
 192.168.1.100 0 0000/28---192.168.1.128/28
 192.168.1.100 1 0000/28---192.168.1.144/28
192.168.1.101 00000/27----R5环回
  192.168.1.101 0 e808/28---192.168.1.160/28
 192.168.1.101 1 0008/28---192.168.1.176/28
192.168.1.110 00000/27----DHCP---192.168.1.192/27
192.168.1.111 00000/27保留

AR1:

[Huawei]interface g0/0/0
[Huawei-GigabitEthernet0/0/0]ip address 192.168.1.1 30
[Huawei-GigabitEthernet0/0/0]
[Huawei-GigabitEthernet0/0/0]interface g0/0/1
[Huawei-GigabitEthernet0/0/1]ip address 192.168.1.5 30 
[Huawei-GigabitEthernet0/0/1]interface Loopback 0
[Huawei-LoopBack0]ip address 192.168.1.33 28
[Huawei-LoopBack0]interface loopback 1
[Huawei-LoopBack1]ip address 192.168.1.49 28

AR2:

[Huawei]interface g0/0/0
[Huawei-GigabitEthernet0/0/0]ip address 192.168.1.2 30
[Huawei-GigabitEthernet0/0/0]interface g0/0/1
[Huawei-GigabitEthernet0/0/1]ip address 192.168.1.9 30
[Huawei-GigabitEthernet0/0/1]interface loopback 0
[Huawei-LoopBack0]ip address 192.168.1.65 28
[Huawei-LoopBack0]interface loopback 1
[Huawei-LoopBack1]ip address 192.168.1.81 28

AR3:

[Huawei]interface g0/0/0
[Huawei-GigabitEthernet0/0/0]ip address 192.168.1.6 30
[Huawei-GigabitEthernet0/0/0]interface g0/0/1
[Huawei-GigabitEthernet0/0/1]ip address 192.168.1.13 30
[Huawei-GigabitEthernet0/0/1]interface loopback 0
[Huawei-LoopBack0]ip add 192.168.1.97 28
[Huawei-LoopBack0]interface l 1
[Huawei-LoopBack1]ip add 192.168.1.113 28

AR4:

[Huawei]interface g0/0/0
[Huawei-GigabitEthernet0/0/0]ip address 192.168.1.10 30
[Huawei-GigabitEthernet0/0/0]int g0/0/1
[Huawei-GigabitEthernet0/0/1]ip add 192.168.1.14 30
[Huawei-GigabitEthernet0/0/1]int g4/0/0
[Huawei-GigabitEthernet4/0/0]ip add 192.168.1.17 30
[Huawei-GigabitEthernet4/0/0]int g0/0/2
[Huawei-GigabitEthernet0/0/2]ip add 192.168.1.21 30
[Huawei-GigabitEthernet0/0/2]int l 0
[Huawei-LoopBack0]ip add 192.168.1.129 28
[Huawei-LoopBack0]int l 1
[Huawei-LoopBack1]ip add 192.168.1.145 28

AR5:

[Huawei]int g0/0/2
[Huawei-GigabitEthernet0/0/2]ip add 192.168.1.18 30
[Huawei-GigabitEthernet0/0/2]int g0/0/0
[Huawei-GigabitEthernet0/0/0]ip add 192.168.1.122 30
[Huawei-GigabitEthernet0/0/0]int g0/0/1
[Huawei-GigabitEthernet0/0/1]ip add 192.168.1.193 27
[Huawei-GigabitEthernet0/0/1]int l 0
[Huawei-LoopBack0]ip add 192.168.1.161 28
[Huawei-LoopBack0]int l 1
[Huawei-LoopBack1]ip add 192.168.1.177 28

环回配置

AR1:

[Huawei]ip route-static 192.168.1.64 27 192.168.1.2
[Huawei]ip route-static 192.168.1.96 27 192.168.1.6
[Huawei]ip route-static 192.168.1.8 30 192.168.1.2
[Huawei]ip route-static 192.168.1.12 30 192.168.1.6

[Huawei]ip route-static 0.0.0.0 0 192.168.1.2
[Huawei]ip route-static 0.0.0.0 0 192.168.1.6

AR2:

[Huawei]ip route-static 192.168.1.32 27 192.168.1.1
[Huawei]ip route-static 192.168.1.4 30 192.168.1.1
[Huawei]ip route-static 192.168.1.96 27 192.168.1.1
[Huawei]ip route-static 192.168.1.96 27 192.168.1.10

[Huawei]ip route-static 0.0.0.0 0 192.168.1.10

AR3:

[Huawei]ip route-static 192.168.1.32 27 192.168.1.5
[Huawei]ip route-static 192.168.1.0 30 192.168.1.5
[Huawei]ip route-static 192.168.1.64 27 192.168.1.5
[Huawei]ip route-static 192.168.1.64 27 192.168.1.14
[Huawei]ip route-static 0.0.0.0 0 192.168.1.14

AR4:

[Huawei]ip route-static 192.168.1.32 27 192.168.1.9
[Huawei]ip route-static 192.168.1.32 27 192.168.1.13
[Huawei]ip route-static 192.168.1.0 30 192.168.1.9
[Huawei]ip route-static 192.168.1.4 30 192.168.1.13
[Huawei]ip route-static 192.168.1.64 27 192.168.1.9
[Huawei]ip route-static 192.168.1.96 27 192.168.1.13
[Huawei]ip route-static 0.0.0.0 0 192.168.1.18
[Huawei]ip route-static 0.0.0.0 0 192.168.1.22 preference 90

AR5:

[Huawei]ip route-static 192.168.1.0 24 192.168.1.17
[Huawei]ip route-static 192.168.1.0 24 192.168.1.21 preference 90

AR5DHCP配置

[Huawei]dhcp enable

[Huawei]ip pool 1

[Huawei-ip-pool-1]network 192.168.1.192 mask 27

[Huawei-ip-pool-1]gateway-list 192.168.1.193
[Huawei-ip-pool-1]dns-list 114.114.114.114

[Huawei-ip-pool-1]q

[Huawei]int g0/0/1
[Huawei-GigabitEthernet0/0/1]dhcp select global

ipconfigPC1:

PC>ipconfig

Link local IPv6 address...........: fe80::5689:98ff:feb0:2d4b
IPv6 address......................: :: / 128
IPv6 gateway......................: ::
IPv4 address......................: 192.168.1.222
Subnet mask.......................: 255.255.255.224
Gateway...........................: 192.168.1.193
Physical address..................: 54-89-98-B0-2D-4B
DNS server........................: 114.114.114.114

ipconfigPC2:

PC>ipconfig

Link local IPv6 address...........: fe80::5689:98ff:fec8:11d8
IPv6 address......................: :: / 128
IPv6 gateway......................: ::
IPv4 address......................: 192.168.1.221
Subnet mask.......................: 255.255.255.224
Gateway...........................: 192.168.1.193
Physical address..................: 54-89-98-C8-11-D8
DNS server........................: 114.114.114.114

空接口防环配置

AR1:

[Huawei]ip route-static 192.168.1.32 27 NULL 0

AR2:

[Huawei]ip route-static 192.168.1.64 27 NULL 0

AR3:

[Huawei]ip route-static 192.168.1.96 27 NULL 0

AR4:

[Huawei]ip route-static 192.168.1.128 27 NULL 0

测试

 PC1pingAR1:

PC>ping 192.168.1.33

Ping 192.168.1.33: 32 data bytes, Press Ctrl_C to break
Request timeout!
Request timeout!
Request timeout!
From 192.168.1.33: bytes=32 seq=4 ttl=252 time=47 ms
From 192.168.1.33: bytes=32 seq=5 ttl=252 time=62 ms

--- 192.168.1.33 ping statistics ---
  5 packet(s) transmitted
  2 packet(s) received
  60.00% packet loss
  round-trip min/avg/max = 0/54/62 ms

PC1pingAR4:

PC>ping 192.168.1.17

Ping 192.168.1.17: 32 data bytes, Press Ctrl_C to break
Request timeout!
From 192.168.1.17: bytes=32 seq=2 ttl=254 time=62 ms
From 192.168.1.17: bytes=32 seq=3 ttl=254 time=32 ms
From 192.168.1.17: bytes=32 seq=4 ttl=254 time=47 ms
From 192.168.1.17: bytes=32 seq=5 ttl=254 time=31 ms

--- 192.168.1.17 ping statistics ---
  5 packet(s) transmitted
  4 packet(s) received
  20.00% packet loss
  round-trip min/avg/max = 0/43/62 ms

PC1pingAR5环回:

PC>ping 192.168.1.161

Ping 192.168.1.161: 32 data bytes,Press ]ctrl_c to break

From 192.168.1.161: bytes=32 seq=1 tt1=255 time=47 ms

From 192.168.1.161: bytes=32 seq=2 ttl=255 time=31 ms

--- 192.168.1.161 ping statistics ---

2 packet(s) transmitted

2packet(s) received

0.00% packet loss

round-trip min/avg/max =32/37/48 ms

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值