实验目的:
1、掌握VLAN的划分
2、掌握单臂路由的配置
3、掌握怎样开启DHCP功能
4、掌握配置接口IP地址和描述,及ping命令的使用。
5、掌握怎样储存配置命令
实验拓扑:
实验步骤:
1、配置IP地址
PC1
PC2
PC3
SW1
SW2
1、在SW1、SW2上分别划分VLAN
1、将e0/0/1、e0/0/2分别放入VLAN10、VLAN20
[Huawei]int e0/0/1
[Huawei-Ethernet0/0/1]port link-type access
[Huawei-Ethernet0/0/1]port default vlan 10
[Huawei]int e0/0/2
[Huawei-Ethernet0/0/2]port link-type access
[Huawei-Ethernet0/0/2]port default vlan 20
2、开中继口
SW1
[Huawei]int g0/0/1
[Huawei-GigabitEthernet0/0/1]portlink-type trunk
[Huawei-GigabitEthernet0/0/1]port trunk allow-pass vlan 10 20
[Huawei]int g0/0/2
[Huawei-GigabitEthernet0/0/2]port link-typetrunk
[Huawei-GigabitEthernet0/0/2]porttrunk allow-pass vlan 10 20
SW2
[Huawei]int g0/0/1
[Huawei-GigabitEthernet0/0/1]port link-type trunk
[Huawei-GigabitEthernet0/0/1]port trunkallow-pass vlan 10 20
1、AR做单臂路由
<Huawei>system-view//进接口先打开端口
[Huawei]int g0/0/2.10 //进接口
[Huawei-GigabitEthernet0/0/2.10]dot1q termination vid 10 //配封装
[Huawei-GigabitEthernet0/0/2.10]ip add 192.168.10.1 24 //配子接口IP地址
[Huawei-GigabitEthernet0/0/2.10]arp broadcast enable //开启arp功能
[Huawei-GigabitEthernet0/0/2.10]int g0/0/2.20
[Huawei-GigabitEthernet0/0/2.20]dot1q termination vid 20
[Huawei-GigabitEthernet0/0/2.20]ip add 192.168.20.1 24
[Huawei-GigabitEthernet0/0/2.20]arp broadcast enable
[Huawei-GigabitEthernet0/0/2.20]quit
[Huawei]
1、开启DHCP功能
[Huawei]dhcpenable
[Huawei]intg0/0/2.20
[Huawei-GigabitEthernet0/0/2.20]dhcpselect interface
[Huawei-GigabitEthernet0/0/2.20]dhcpserver dns-list 8.8.8.8
2、在PC4上自动获取IP地址
点右下角的“应用”
1、用ping命令检测网络是否互通
End
本文出自 “学习进程” 博客,转载请与作者联系!