HCIP真机实验

实验拓扑

设备对应表ip及vlan划分

序号设备逻辑名设备型号
1C-1华三S5700
2C-2华三S5700
3D-1华为S5735
4D-2华为S5700
5D-3华为S5700
6D-4华为S5700
7D-5华为S5700
8D-6华为S5700
9A-1华为S5700
10A-2华为S5700
11A-3华为S5700
12A-4华为S5700
13A-5华为S5700
VLAN用途设备接口地址段网关备注
11财务部A-4G1/0/3-5172.16.11.0/24172.16.11.1/24办公区
12销售部A-4G1/0/6-10172.16.12.0/24172.16.12.1/24
13后勤部A-4G1/0/11-15172.16.13.0/24172.16.13.1/24
14业务部A-5G1/0/3-5172.16.14.0/24172.16.14.1/24
15运维部A-5G1/0/6-10172.16.15.0/24172.16.15.1/24
16研发部A-5G1/0/11-15172.16.16.0/24172.16.16.1/24
21车间1A-1G1/0/3-24172.16.21.0/24172.16.21.1/24生产区
22车间2A-2G1/0/3-24172.16.22.0/24172.16.22.1/24
23车间3A-3G1/0/2-24172.16.23.0/24172.16.23.1/24
31OAD-3G0/0/5-7172.16.31.0/24172.16.31.1/24服务器区
32ERPD-4G0/0/5-7172.16.32.0/24172.16.32.1/24
33生产控制D-3G0/0/8-12172.16.33.0/24172.16.33.1/24
34生产数据D-4G0/0/8-12172.16.34.0/24172.16.34.1/24
35服务器管理D-4G0/0/13-20172.16.35.0/24172.16.35.1/24
100交换机管理C-1vlan100 接口182.16.100.0/26172.16.100.1
100交换机管理C-2vlan100 接口182.16.100.0/26172.16.100.2
100交换机管理D-3vlan100 接口172.16.100.0/26172.16.100.3
100交换机管理D-4vlan100 接口172.16.100.0/26172.16.100.4
100交换机管理D-1vlan100 接口172.16.100.64/26172.16.100.65
100交换机管理D-2vlan100 接口172.16.100.64/26172.16.100.66
100交换机管理D-5vlan100 接口172.16.100.128/26172.16.100.129
100交换机管理D-6vlan100 接口172.16.100.128/26172.16.100.130
100交换机管理A-1vlan100 接口172.16.100.64/26172.16.100.67
100交换机管理A-2vlan100 接口172.16.100.64/26172.16.100.68
100交换机管理A-3vlan100 接口172.16.100.64/26172.16.100.69
100交换机管理A-4vlan100 接口172.16.100.128/26172.16.100.131
100交换机管理A-5vlan100 接口172.16.100.128/26172.16.100.132
1101C1与C2互联C-1,C-2vlan1101接口172.16.0.0/30172.16.0.1/30
1102D1与D2互联D-1,D-2vlan1102接口172.16.0.4/30172.16.0.5/30
1103D5与D6互联D-5,D-6vlan1103接口172.16.0.8/30172.16.0.9/30
1104C1与D1互联C-1,D-1vlan1104接口172.16.0.12/30172.16.0.13/30
1105C1与D2互联C-1,D-2vlan1105接口172.16.0.16/30172.16.0.17/30
1106C1与F1互联C-1,F-1vlan1106接口172.16.0.20/30172.16.0.21/30
1107C1与D5互联C-1,D-5vlan1107接口172.16.0.24/30172.16.0.25/30
1108C1与D6互联C-1,D-6vlan1108接口172.16.0.28/30172.16.0.29/30
1109C2与D1互联C-2,D-1vlan1109接口172.16.0.32/30172.16.0.33/30
1110C2与D2互联C-2,D-2vlan1110接口172.16.0.36/30172.16.0.37/30
1111C2与D5互联C-2,D-5vlan1111接口172.16.0.40/30172.16.0.41/30
1112C2与D6互联C-2,D-6vlan1112接口172.16.0.44/30172.16.0.45/30
1113C2与F1互联C-2,F-1vlan1113接口172.16.0.48/30172.16.0.49/30

线缆序号源设备名称设备接口目标设备名称设备接口补充说明
1C-15口F-10/0/0电口
2C-11口C-21口聚合光口
3C-12口C-22口
4C-16口D-11口光口
5C-17口D-21口光口
6C-13口D-31口光口
7C-14口D-41口光口
8C-18口D-51口光口
9C-19口D-61口光口
10C-23口F-11/0/0电口
11C-24口D-12口光口
12C-25口D-22口光口
13C-26口D-32口光口
14C-27口D-42口光口
15C-28口D-52口光口
16C-29口D-62口光口
17D-33口D-43口聚合电口
18D-34口D-44口
19D-13口D-23口聚合电口
20D-14口D-24口
21D-15口A-10口电口
22D-16口A-20口电口
23D-25口A-11口电口
24D-26口A-21口电口
25D-27口A-30口电口
26D-53口D-63口聚合电口
27D-54口D-64口
28D-55口A-40口电口
29D-56口A-50口电口
30D-65口A-41口电口
31D-66口A-51口电口

实验需求及步骤

实验步骤

1. 方案验证准备阶段(线上完成):

   1.1 充分理解需求,用华为ENSP模拟器完成配置并测试完备

   1.2 确认真机设备型号与接口,调整模拟器配置脚本匹配现场设备与接口,对于华三设备使用命令翻译器或者参看华三配置手册完成配置脚本匹配

2. 现场联调阶段(线下完成):

   2.1 确认现场物料与环境,包括机柜,设备,线缆,电源,标签纸等

   2.2 设备加电导入脚本,检查配置是否完备并保存配置

   2.3 设备贴标上架安装至预定位置

   2.4 设备安装光模块并连线做好线标

   2.5 确认现场电源,设备加电

 3. 测试阶段(线下完成):

   3.1 基础链路对接测试

   3.2 二层协议互通测试

   3.3 三层路由互通测试

   3.4 路径测试

   3.5 双机热备测试

   3.6 业务测试

二层配置

生产区

生产区需求

配置

先关闭接口关闭接口再进行配置主要是出于管理和安全性的考虑。

  1. 管理考虑:华为交换机的某些配置要求先关闭接口,然后再进行配置。这是因为在接口开启的状态下,某些配置可能无法生效或者可能导致网络故障。关闭接口后,可以确保配置的正确性和一致性,避免配置冲突或错误。

  2. 安全性考虑:关闭接口可以防止未经授权的设备或用户连接到交换机,从而提高网络的安全性。

1.配置之后无法链路聚合,因此先进行链路聚合-------需求2

[d1]int e 0                                                                          
​
[d1]int g0/0/3                                                           [d1]int g0/0/4 
​
[d1-GigabitEthernet0/0/3]eth-trunk 0               [d1-GigabitEthernet0/0/4]eth-trunk 0

根据图表创建与d1相关的vlan

[d1]v b 21 22 100 1102 1104 1109

创建trunk接口,放通必要vlan实现最小透传原则,同理配置g0/0/6---------需求1

[d1]int g0/0/5
[d1-GigabitEthernet0/0/5]p l t 
[d1-GigabitEthernet0/0/5]p t a v 21 22 100
[d1-Eth-Trunk0]p t a v 21 22 100 1102

配置IP地址[d1-Vlanif1109]ip add 172.16.0.34 30

[d1-Vlanif21]ip add 172.16.21.1 24
[d1-Vlanif22]ip add 172.16.22.1 24
[d1-Vlanif100]ip  add 172.16.100.65 26
[d1-Vlanif1102]ip add 172.16.0.5 30
[d1-Vlanif1104]ip add 172.16.0.14 30
[d1-Vlanif1109]ip  add 172.16.0.34 30

配置STP服务------需求3456

[d1]stp enable
[d1]stp mode mstp
[d1]stp region-configuration
[d1-mst-region]region-name SC
[d1-mst-region]instance 1 v 21
[d1-mst-region]instance 2 v 22 23 100
[d1-mst-region]active region-configuration
[d1]stp instance 1 root primary
[d1]stp instance 2 root secondary

配置vrrp--------需求89 10

双上行down时优先级减少22,优先级为98小于100会切换网关

[d1]int v 21
[d1-Vlanif21]vrrp vrid 1 virtual-ip 172.16.21.254 
[d1-Vlanif21]vrrp vrid 1 priority 120                                /增加优先级为master
[d1-Vlanif21]vrrp vrid 1 preempt-mode timer delay 20
[d1-Vlanif21]vrrp vrid 1 track interface v 1104 reduced 11
[d1-Vlanif21]vrrp vrid 1 track interface v 1109 reduced 11
[d1-Vlanif22]vrrp vrid 1 virtual-ip 172.16.22.254

打开接口 [d2]interface range g0/0/3 tog0/0/6

同理 配置d2

[d2-GigabitEthernet0/0/5]p t a v 21 22 100
[d2-GigabitEthernet0/0/6]p t a v 21 22 100
[d2-GigabitEthernet0/0/7]p t a v 23 100
[d2-Eth-Trunk0]p t a v 21 22 100 1102
[d2-Vlanif21]ip add 172.16.21.2 24
[d2-Vlanif22]ip add 172.16.22.2 24
[d2-Vlanif23]ip add 172.16.23.1 24
[d2-Vlanif100]ip add 172.16.100.66 26
[d2-Vlanif1102]ip add 172.16.0.6 30 
[d2-Vlanif1105]ip add 172.16.0.18 30
[d2-Vlanif1110]ip add 172.16.0.38 30
[d2]stp enable  
[d2]stp mode mstp
[d2]stp region-configuration    
[d2-mst-region]region-name SC   
[d2-mst-region]instance 1 v 21 
[d2-mst-region]instance 2 v 22 23 100
[d2-mst-region]active region-configuration  
[d2]stp instance 1 root secondary   
[d2]stp instance 2 root primary 
[d2-Vlanif21]vrrp vrid 1 virtual-ip 172.16.21.254
[d2-Vlanif22]vrrp vrid 1 virtual-ip 172.16.22.254   
[d2-Vlanif22]vrrp vrid 1 priority 120   
[d2-Vlanif22]vrrp vrid 1 preempt-mode timer delay 20
[d2-Vlanif22]vrrp vrid 1 track interface v 1105 r 11
[d2-Vlanif22]vrrp vrid 1 track interface v 1110 r 11

配置a1-------需求7

[a1-GigabitEthernet0/0/1]p t a v 21 22 100
[a1-GigabitEthernet0/0/2]p t a v 21 22 100
[a1]port-group group-member g0/0/3 to g0/0/24
[a1-port-group]p l a
[a1-port-group]p d v 21
[a1-Vlanif100]ip add 172.16.0.67 26
[a1-mst-region]region-name SC
[a1-mst-region]instance 1 v 21 
[a1-mst-region]instance 2 v 22 100
[a1-mst-region]active region-configuration
[a1]port-group group-member g0/0/3 to g0/0/24
[a1-port-group]stp edged-port enable
[a1]stp bpdu-protection 

同理配置a2 a3

[a3]v b 23 100
[a3-GigabitEthernet0/0/1]p t a v 23 100
[a3]port-group group-member g0/0/2 to g0/0/24
[a3-port-group]p l a
[a3-port-group]p d v 23
[a3-Vlanif100]ip add 172.16.100.69 26
[a3-port-group]stp edged-port enable 
[a3-port-group]undo shutdown 
a3没有vlan21 22 且直连设备只有d2
查看配置

链路集合

vlan创建及关闭接口

查看最小生成树

vrrp及实例映射

办公区

办公区需求

配置

配置与生产区相同

创建vlan---链路聚合---放通vlan(实现最小透传原则 )---配置ip

[d5-GigabitEthernet0/0/5]p t a v 11 12 13 14 15 16 100
[d5-GigabitEthernet0/0/6]p t a v 11 12 13 14 15 16 100
[d5-Eth-Trunk0]p t a v 11 12 13 14 15 16 100

d5配置stp vrrp

[d5]stp enable  
[d5]stp mode mstp   
[d5]stp region-configuration    
[d5-mst-region]region-name BG   
[d5-mst-region]instance 1 V 11 12 13    
[d5-mst-region]instance 2 v 14 15 16 100        
[d5-mst-region]active region-configuration  
[d5]stp instance 1 root primary     
[d5]stp instance 2 root secondary 
[d5]int v 11
[d5-Vlanif11]vrrp vrid 1 v  
[d5-Vlanif11]vrrp vrid 1 virtual-ip 172.16.11.254
[d5-Vlanif11]vrrp vrid 1 priority 120   
[d5-Vlanif11]vrrp vrid 1 preempt-mode timer delay 20    
[d5-Vlanif11]vrrp vrid 1 track interface v 1107 reduced 11
[d5-Vlanif11]vrrp vrid 1 track interface v 1111 reduced 11
​

vlanif 11 与12 13 配置相同,14 15 16 为备默认优先级且不监控上行链路 只需配置ip

d6与d5配置相似

a4 a5配置与a1 a2类似

[d5]v b 11 12 13 14 15 16 100
[d5-GigabitEthernet0/0/1]p t a v 11 12 13 14 15 16 100
[d5-GigabitEthernet0/0/2]p t a v 11 12 13 14 15 16 100
[d5]port-group group-member g0/0/3 t g0/0/5
[d5-port-group]p l a
[d5-port-group]p d v 14
[d5]port-group group-member g0/0/6 t g0/0/10
[d5-port-group]p l a
[d5-port-group]p d v 15
[d5]port-group group-member g0/0/11 t g0/0/15
[d5-port-group]p l a
[d5-port-group]p d v 16
[d5]int v 100
[d5-Vlanif100]ip add 172.16.100.132 26
[d5]stp mode mstp   
[d5]stp region-configuration    
[d5-mst-region]region-name BG   
[d5-mst-region]instance 1 v 11 12 13
[d5-mst-region]instance 2 v 14 15 16 100    
[d5-mst-region]active region-configuration  
[d5]port-group group-member g0/0/3 t g0/0/15
[d5-port-group]stp edged-port enable
[d5]stp bpdu-protection 
[d5]port-group group-member g0/0/3 t g0/0/15    
[d5-port-group]undo shutdown 
​
查看

vlan

双击热备

最小生成树

服务区

服务器区需求

配置

配置同上,c1配置

创建vlan---链路集合---设置接口---放通vlan---配置ip

![image-20240406143327622](C:\Users\pc\AppData\Roaming\Typora\typora-user-images\image-20240406143327622.png)

```
开启stp服务完成需求4,5
[c1]stp enable     
[c1]stp mode mstp
[c1]stp region-configuration     
[c1-mst-region]region-name FWQ
[c1-mst-region]instance 1 v 31 33 100    
[c1-mst-region]instance 2 v 32 34 35 
[c1-mst-region]active region-configuration 
需求6
[c1]stp instance 1 root primary     
[c1]stp instance 2 root secondary
需求9 10 11
[c1-Vlanif31]vrrp vrid 1 virtual-ip 172.16.31.254    
[c1-Vlanif31]vrrp vrid 1 priority 120     ----------------------通过提高优先级成为master
[c1-Vlanif31]vrrp vrid 1 preempt-mode timer delay 20    
[c1-Vlanif31]vrrp vrid 1 track interface Vlanif 1106 reduced 30----------上行链路只有一条连接f1                                                                        的,优先级需要降低20以上
同理配置其他vlanif33提高优先级,32 34 35不变配置虚拟ip
```

a3配置,a4与a3相同

```
[d3]v b 31 t 35 100
[d3]int e 0
[d3-Eth-Trunk0]int g0/0/3
[d3-GigabitEthernet0/0/3]eth-trunk 0    
[d3-GigabitEthernet0/0/3]int g0/0/4
[d3-GigabitEthernet0/0/4]eth-trunk 0
[d3-GigabitEthernet0/0/1]p l t
[d3-GigabitEthernet0/0/1]p t a v 31 t 35 100
[d3-GigabitEthernet0/0/2]p l t
[d3-GigabitEthernet0/0/2]p t a v 31 t 35 100
[d3]int e 0
[d3-Eth-Trunk0]p l t 
[d3-Eth-Trunk0]p t a v 31 t 35 100 
[d3]port-group group-member g0/0/5 t g 0/0/7
[d3-port-group]p l a
[d3-port-group]p d v 31
[d3]p g g0/0/8 t g0/0/12
[d3-port-group]p l a
[d3-port-group]p d v 33
[d3]int v 100
[d3-Vlanif100]ip add 172.16.100.3 26
[d3]stp enable 
[d3]stp mode mstp
[d3]stp region-configuration     
[d3-mst-region]region-name FWQ    
[d3-mst-region]instance 1 v 31 33 100
[d3-mst-region]instance 2 v 32 34 35    
[d3-mst-region]active region-configuration 
[d3]p g g0/0/5 to g0/0/12    
[d3-port-group]stp edged-port enable  
[d3]stp bpdu-protection 
[d3]p g g0/0/1 t g0/0/12
[d3-port-group]undo shutdown 
```

查看

上行链路down时

最小生成树

三层策略及优化

需求

c1

c1配置

把接口划入vlan,设置为access类型(使用access不用设置pvid)

关闭与d1 d2 f1 d5 d6相连接口的stp服务,防止出现阻塞

划分ospf区域并进行宣告

```
[c1]ospf 1 router-id 2.2.2.2    
[c1-ospf-1]area 0
[c1-ospf-1-area-0.0.0.0]network 172.16.0.1 0.0.0.0
[c1-ospf-1-area-0.0.0.0]network 172.16.0.21 0.0.0.0
[c1-ospf-1-area-0.0.0.0]network 172.16.100.1 0.0.0.0

```

同理配置其它接口

c1查看

同理配置c2 d2及其他

c2 d6 查看

ospf表

f1

f1配置

```
[f1-GigabitEthernet0/0/0]ip add 172.16.0.22 30
[f1-GigabitEthernet1/0/0]ip add 172.16.0.50 30
[f1]firewall zone trust 
[f1-zone-trust]add int g0/0/0
[f1-zone-trust]add int g1/0/0
[f1]security-policy 
[f1-policy-security]rule name policy-1
f1-policy-security-rule-policy-1]source-zone trust 
[f1-policy-security-rule-policy-1]destination-zone untrust 
[f1-policy-security-rule-policy-1]action permit 
[f1]ospf 1 r 1.1.1.1
[f1-ospf-1]a 0
[f1-ospf-1-area-0.0.0.0]net 172.16.0.22 0.0.0.0
[f1-ospf-1-area-0.0.0.0]net 172.16.0.50 0.0.0.0

```

f1查看



其余配置

区域认证
[f1-ospf-1-area-0.0.0.0]authentication-mode md5 1 plain 123456
[c1-ospf-1-area-0.0.0.0]authentication-mode md5 1 plain 123456
[c2-ospf-1-area-0.0.0.0]authentication-mode md5 1 plain 123456
末梢区域,同理配置area2
[c1-ospf-1-area-0.0.0.1]stub
[c1-ospf-1-area-0.0.0.2]stub no-summary 
[d1-ospf-1-area-0.0.0.1]stub
设置静默接口,简化ospf表
[d1-ospf-1]silent-interface v 21
[d1-ospf-1]silent-interface v 22
[d1-ospf-1]silent-interface v 100
[d1-ospf-1]silent-interface v 1102
接口类型变为p2p简化邻居关系
[c2]int Vlanif 1109
[c2-Vlanif1109]ospf network-type p2p
[c2-Vlanif1109]int v 1110
[c2-Vlanif1110]ospf network-type p2p
[c2-Vlanif1110]int v 1111
[c2-Vlanif1111]ospf network-type p2p
[c2-Vlanif1111]int v 1112
[c2-Vlanif1112]ospf network-type p2p
[c2-Vlanif1112]int v 1113
[c2-Vlanif1113]ospf network-type p2p
[f1-GigabitEthernet0/0/0]ospf network-type p2p
[f1-GigabitEthernet0/0/0]int g1/0/0
[f1-GigabitEthernet1/0/0]ospf network-type p2p
​

与其他接口设置hello包时间-------6.3

[c1]int v 1104
[c1-Vlanif1104]OSPF timer hello 1
[c1-Vlanif1104]int v 1105
[c1-Vlanif1105]OSPF timer hello 1
[c1-Vlanif1105]int v 1106
[c1-Vlanif1106]OSPF timer hello 1
[c1-Vlanif1106]int v 1107
[c1-Vlanif1107]OSPF timer hello 1
[c1-Vlanif1107]int v 1108
[c1-Vlanif1108]OSPF timer hello 1
增加c1区域2cost值, 增加c2区域1cost值,实现2 3
[c1-ospf-1-area-0.0.0.2]default-cost 5
[c2-ospf-1-area-0.0.0.1]default-cost 5
制定acl规则,控制列表实现6.4 6.5

d1部分配置,同理配置d2

rule 5 permit ip source 172.16.21.0 0.0.0.255 destination 172.16.31.0 0.0.0.255
rule 50 permit ip source 172.16.21.0 0.0.0.255 destination 172.16.16.0 0.0.0.255
rule 55 permit ip source 172.16.22.0 0.0.0.255 destination 172.16.12.0 0.0.0.255
rule 100 permit ip source 172.16.22.0 0.0.0.255 destination 172.16.35.0 0.0.0.255
[d1-acl-adv-3000]rule 110 permit ip source 172.16.22.0 0.0.0.255 destination 172
.16.23.0 0.0.0.255------------连通v23
[d1-acl-adv-3000]rule 10000 d ip source 172.16.21.0 0.0.0.255
[d2-acl-adv-3000]rule 10005 d ip source 172.16.22.0 0.0.0.255

d2查看

[d2-acl-adv-3000]dis th
#
acl number 3000
 rule 5 permit ip source 172.16.21.0 0.0.0.255 destination 172.16.31.0 0.0.0.255
 rule 10 permit ip source 172.16.21.0 0.0.0.255 destination 172.16.32.0 0.0.0.255
 rule 15 permit ip source 172.16.21.0 0.0.0.255 destination 172.16.33.0 0.0.0.255
 rule 20 permit ip source 172.16.21.0 0.0.0.255 destination 172.16.34.0 0.0.0.255
 rule 25 permit ip source 172.16.21.0 0.0.0.255 destination 172.16.35.0 0.0.0.255
 rule 30 permit ip source 172.16.21.0 0.0.0.255 destination 172.16.12.0 0.0.0.255
 rule 35 permit ip source 172.16.21.0 0.0.0.255 destination 172.16.13.0 0.0.0.255
 rule 40 permit ip source 172.16.21.0 0.0.0.255 destination 172.16.14.0 0.0.0.255
 rule 45 permit ip source 172.16.21.0 0.0.0.255 destination 172.16.15.0 0.0.0.255
 rule 50 permit ip source 172.16.21.0 0.0.0.255 destination 172.16.16.0 0.0.0.255
 rule 55 permit ip source 172.16.22.0 0.0.0.255 destination 172.16.16.0 0.0.0.255
 rule 60 permit ip source 172.16.22.0 0.0.0.255 destination 172.16.15.0 0.0.0.255
 rule 65 permit ip source 172.16.22.0 0.0.0.255 destination 172.16.14.0 0.0.0.255
 rule 70 permit ip source 172.16.22.0 0.0.0.255 destination 172.16.13.0 0.0.0.255
 rule 75 permit ip source 172.16.22.0 0.0.0.255 destination 172.16.12.0 0.0.0.255
 rule 80 permit ip source 172.16.22.0 0.0.0.255 destination 172.16.31.0 0.0.0.255
 rule 85 permit ip source 172.16.22.0 0.0.0.255 destination 172.16.32.0 0.0.0.255
 rule 90 permit ip source 172.16.22.0 0.0.0.255 destination 172.16.33.0 0.0.0.255
 rule 95 permit ip source 172.16.22.0 0.0.0.255 destination 172.16.34.0 0.0.0.255
 rule 100 permit ip source 172.16.22.0 0.0.0.255 destination 172.16.35.0 0.0.0.255
 rule 105 permit ip source 172.16.22.0 0.0.0.255 destination 172.16.23.0 0.0.0.255
 rule 110 permit ip source 172.16.21.0 0.0.0.255 destination 172.16.23.0 0.0.0.255
 rule 115 permit ip source 172.16.23.0 0.0.0.255 destination 172.16.12.0 0.0.0.255
 rule 120 permit ip source 172.16.23.0 0.0.0.255 destination 172.16.13.0 0.0.0.255
 rule 125 permit ip source 172.16.23.0 0.0.0.255 destination 172.16.14.0 0.0.0.255
 rule 130 permit ip source 172.16.23.0 0.0.0.255 destination 172.16.15.0 0.0.0.255
 rule 135 permit ip source 172.16.23.0 0.0.0.255 destination 172.16.16.0 0.0.0.255
 rule 140 permit ip source 172.16.23.0 0.0.0.255 destination 172.16.31.0 0.0.0.255
 rule 145 permit ip source 172.16.23.0 0.0.0.255 destination 172.16.32.0 0.0.0.255
 rule 150 permit ip source 172.16.23.0 0.0.0.255 destination 172.16.33.0 0.0.0.255
 rule 155 permit ip source 172.16.23.0 0.0.0.255 destination 172.16.34.0 0.0.0.255
 rule 160 permit ip source 172.16.23.0 0.0.0.255 destination 172.16.35.0 0.0.0.255
 rule 10000 deny ip source 172.16.23.0 0.0.0.255
 rule 10005 deny ip source 172.16.22.0 0.0.0.255
 rule 10010 deny ip source 172.16.21.0 0.0.0.255
 [d5-GigabitEthernet0/0/6]traffic-filter inbound acl 3000----
​

c1配置

[c1-acl-adv-3000]dis th
#
acl number 3000
 rule 5 permit ip source 172.16.15.0 0.0.0.255 destination 172.16.35.0 0.0.0.255
 rule 10 deny ip destination 172.16.35.0 0.0.0.255
 rule 1000 permit ip
 [c1-GigabitEthernet0/0/6]traffic-filter inbound acl 3000
[c1-GigabitEthernet0/0/6]int g0/0/7
[c1-GigabitEthernet0/0/7]traffic-filter inbound acl 3000
[c1-GigabitEthernet0/0/7]int g0/0/8
[c1-GigabitEthernet0/0/8]traffic-filter inbound acl 3000
[c1-GigabitEthernet0/0/8]int g0/0/9
[c1-GigabitEthernet0/0/9]traffic-filter inbound acl 3000

创建新用户

[d5]telnet server enable
[d5]user-interface vty 0 4
[d5-ui-vty0-4]authentication-mode aaa   
[d5-ui-vty0-4]authentication-mode password  
[d5-ui-vty0-4]user privilege level 3
[d5]aaa
[d5-aaa]local-user huawei password cipher admin@123
​

总结

通过本次实验我明白了放通VLAN时选择逐个放通而不是全部放通(all)的原因是逐个放通VLAN可以提供更精细的控制和更好的安全性也可以减少消耗。通过逐个放通,网络管理员可以明确地知道哪些VLAN需要被放通,哪些不需要,从而避免不必要的安全风险。配置之前关闭交换机配置可以实现对特定设备的隔离。例如,当需要对某个设备进行排查或者修复时,关闭交换机配置可以避免其他设备的干扰,提高维护效率。关闭交换机配置可以增强网络的安全性。在某些情况下,可能需要限制某些设备之间的通信,关闭交换机配置可以实现网络分段或隔离,从而提高网络安全性。

  • 17
    点赞
  • 17
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值