目录
步骤二. 在 S1 和 S2 批量创建 VLAN 3 到 VLAN 7
一,实验1-5:配置三层交换
【实验目的】
· 掌握通过三层交换机实现VLAN间通信的配置方法
· 掌握通过以太网Trunk链路实现VLAN间通信的配置方法
· 掌握在丌同VLAN间配置劢态路由协议OSPF的方法
【实验环境】
在企业网络中,通过使用三层交换机可以简便的实现VLAN间通信。作为企业的网络管理员,您需要在三层交换机配置VLANIF接口的三层功能,使得如上所示拓扑图中的网络能够实现VLAN间通信。此外,为了使S1和S2所连接不同网络能够迚行三层通信,还需要配置路由协议。
【实验过程】
拓扑图
操作步骤
步骤一. 实验环境准备
将R1上的G0/0/1接口的IP地址配置为10.33.4.1/24,在S1和S2之间配置Eth-Trunk,并关闭S3和S4上的无关端口。
<Huawei>system-view
[Huawei]sysname hyj R1
[R1]interface GigabitEthernet 0/0/1
[R1-GigabitEthernet0/0/1]ip address 10.33.4.1 24
<Huawei>system-view
[Huawei]sysname hyj R3
<Quidway>system-view
[Quidway]sysname hyj S1
[S1]interface Eth-Trunk 1
[S1-Eth-Trunk1]mode lacp-static
[S1-Eth-Trunk1]port link-type trunk
[S1-Eth-Trunk1]port trunk allow-pass vlan all
[S1-Eth-Trunk1]quit
[S1]interface GigabitEthernet 0/0/9
[S1-GigabitEthernet0/0/9]eth-trunk 1
[S1-GigabitEthernet0/0/9]interface GigabitEthernet 0/0/10
[S1-GigabitEthernet0/0/10]eth-trunk 1
<Quidway>system-view
[Quidway]sysname hyj S2
[S2]interface Eth-Trunk 1
[S2-Eth-Trunk1]mode lacp-static
[S2-Eth-Trunk1]port link-type trunk
[S2-Eth-Trunk1]port trunk allow-pass vlan all
[S2-Eth-Trunk1]quit
[S2]interface GigabitEthernet 0/0/9
[S2-GigabitEthernet0/0/9]eth-trunk 1
[S2-GigabitEthernet0/0/9]interface GigabitEthernet 0/0/10
[S2-GigabitEthernet0/0/10]eth-trunk 1
<Quidway>system-view
[Quidway]sysname hyj S3
[S3]interface Ethernet 0/0/23
[S3-Ethernet0/0/23]shutdown
<Quidway>system-view
[Quidway]sysname hyj S4
[S4]interface Ethernet 0/0/12
[S4-Ethernet0/0/14]shutdown
步骤二. 在 S1 和 S2 批量创建 VLAN 3 到 VLAN 7
[S1]vlan batch 3 to 7
Info: This operation may take a few seconds. Please wait for a moment...done.
[S2]vlan batch 3 to 7
Info: This operation may take a few seconds. Please wait for a moment...done.
确认VLAN已成功创建。
[S1]display vlan