HCIP静态综合实验

HCIP静态综合实验_第1张图片

实验报告:第一步合理划分IP地址本实验最佳划分只需六个网段即可,所以将192.168.1.0网段划分为8个.一个骨干,五个配置环回,剩下两个用作备用网段。第二步在R3开启DHCP,创建一个池塘abc.用来自动获取r3下两台电脑的ip。第三步r1-r5配置静态路由,缺省路由,空接口路由。使得全网可达。第四步配置nat和端口映射然后就可以pingISP。

配置IP地址

ip划分图

HCIP静态综合实验_第2张图片

R1
[r1]int g0/0/0
[r1-GigabitEthernet0/0/0]ip add 192.168.1.1 30
[r1-GigabitEthernet0/0/0]int g0/0/1
[r1-GigabitEthernet0/0/1]ip add 192.168.1.13 30
[r1-GigabitEthernet0/0/1]int loopback0
[r1-LoopBack0]ip add 192.168.1.33 28
[r1-LoopBack0]int loopback1
[r1-LoopBack1]ip add 192.168.1.49 28
R2
[r2]int g0/0/0
[r2-GigabitEthernet0/0/0]ip add 192.168.1.2 30
[r2-GigabitEthernet0/0/0]int g0/0/1
[r2-GigabitEthernet0/0/1]ip add 192.168.1.5 30
[r2-GigabitEthernet0/0/1]int loopback0
[r2-LoopBack0]ip add 192.168.1.65 28
[r2-LoopBack0]int loopback1
[r2-LoopBack1]ip add 192.168.1.81 28
R3
[r3]int g0/0/1
[r3-GigabitEthernet0/0/1]ip add 192.168.1.14 30
[r3-GigabitEthernet0/0/1]int g0/0/0
[r3-GigabitEthernet0/0/0]ip add 192.168.1.9 30
[r3-GigabitEthernet0/0/0]int g0/0/2
[r3-GigabitEthernet0/0/2]ip add 192.168.1.161 27
R4
[r4]int g0/0/0
[r4-GigabitEthernet0/0/0]ip add 192.168.1.6 30
[r4-GigabitEthernet0/0/0]int g0/0/1
[r4-GigabitEthernet0/0/1]ip add 192.168.1.10 30
[r4-GigabitEthernet0/0/1]int g0/0/2
[r4-GigabitEthernet2/0/0]ip add 192.168.1.17 30
[r4-GigabitEthernet2/0/0]int g4/0/0
[r4-GigabitEthernet0/0/2]ip add 192.168.1.21 30
[r4-GigabitEthernet0/0/2]int loopback0
[r4-LoopBack0]ip add 192.168.1.97 28
[r4-LoopBack0]int loopback1
[r4-LoopBack1]ip add 192.168.1.113 28
R5
[r5]int g0/0/0
[r5-GigabitEthernet0/0/1]ip add 192.168.1.18 30
[r5-GigabitEthernet0/0/1]int g0/0/1
[r5-GigabitEthernet0/0/2]ip add 12.0.0.1 24
[r5-GigabitEthernet0/0/2]int g0/0/2
[r5-GigabitEthernet0/0/0]ip add 192.168.1.22 30
[r5-GigabitEthernet0/0/0]int loopback0
[r5-LoopBack0]ip add 192.168.1.129 28
R6
[r6]int g0/0/0
[r6-GigabitEthernet0/0/0]ip add 12.0.0.2 24
[r6-GigabitEthernet0/0/0]int loopback0
[r6-LoopBack0]ip add 1.1.1.1 24

r3配置DHCP动态


[r3]dhcp enable
[r3]ip pool abc
[r3-ip-pool-abc]network 192.168.1.160 mask 27
[r3-ip-pool-abc]gateway-list 192.168.1.161
[r3-ip-pool-abc]int g0/0/2
[r3-GigabitEthernet0/0/2]dhcp select global

r1-r5静态路由,缺省路由,空接口路由

R1:
ip route-static 0.0.0.0 0.0.0.0 192.168.1.2
ip route-static 0.0.0.0 0.0.0.0 192.168.1.14
ip route-static 192.168.1.4 255.255.255.252 192.168.1.2
ip route-static 192.168.1.8 255.255.255.252 192.168.1.14
ip route-static 192.168.1.64 255.255.255.224 192.168.1.2
ip route-static 192.168.1.160 255.255.255.224 192.168.1.14
ip route-static 192.168.1.32 255.255.255.224 NULL0

R2:
ip route-static 0.0.0.0 0.0.0.0 192.168.1.6
ip route-static 192.168.1.12 255.255.255.252 192.168.1.1
ip route-static 192.168.1.32 255.255.255.224 192.168.1.1
ip route-static 192.168.1.160 255.255.255.224 192.168.1.6
ip route-static 192.168.1.160 255.255.255.224 192.168.1.1
ip route-static 192.168.1.64 255.255.255.224 NULL0

R3:
ip route-static 0.0.0.0 0.0.0.0 192.168.1.10
ip route-static 192.168.1.0 255.255.255.252 192.168.1.13
ip route-static 192.168.1.32 255.255.255.224 192.168.1.13
ip route-static 192.168.1.64 255.255.255.224 192.168.1.13
ip route-static 192.168.1.64 255.255.255.224 192.168.1.10

R4:
ip route-static 0.0.0.0 0.0.0.0 GigabitEthernet0/0/2 192.168.1.18
ip route-static 0.0.0.0 0.0.0.0 192.168.1.22 preference 70
ip route-static 192.168.1.0 255.255.255.252 192.168.1.5
ip route-static 192.168.1.12 255.255.255.252 192.168.1.9
ip route-static 192.168.1.32 255.255.255.224 192.168.1.9
ip route-static 192.168.1.32 255.255.255.224 192.168.1.5
ip route-static 192.168.1.64 255.255.255.224 192.168.1.5
ip route-static 192.168.1.160 255.255.255.224 192.168.1.9
ip route-static 192.168.1.96 255.255.255.224 NULL0
ip route-static 192.168.1.0 255.255.255.0 NULL0
ip route-static 192.168.1.128 255.255.255.224 192.168.1.18
ip route-static 192.168.1.128 255.255.255.224 192.168.1.22 preference 70
ip route-static 192.168.1.160 255.255.255.224 192.168.1.9

R5:
ip route-static 0.0.0.0 0.0.0.0 12.0.0.2
ip route-static 192.168.1.0 255.255.255.0 192.168.1.17
ip route-static 192.168.1.0 255.255.255.0 192.168.1.21 preference 70

r5进行nat配置和端口映射:

[r5]acl 2000
[r5-acl-basic-2000]rule permit source 192.168.1.0 0.0.0.255
[r5-acl-basic-2000]int g0/0/1
[r5-GigabitEthernet0/0/1]nat outbound 2000
[r1]aaa
[r1-aaa]local-user admin privilege level 15 password cipher 123456
[r1-aaa]local-user admin service-type telnet
[r1-aaa]quit
[r1]user-group
[r1]user-interface vty 0 4
[r1-ui-vty0-4]authentication-mode aaa
[r5]int g0/0/1
[r5-GigabitEthernet0/0/1]nat server protocol tcp global current-interface 23 inside 192.168.1.1 23

实验结果:

1.R1-R5成功访问R6环回

HCIP静态综合实验_第3张图片

2.PC6登陆到PC1端

HCIP静态综合实验_第4张图片

至此该实验所有要求完成

你可能感兴趣的:(服务器,负载均衡,网络)