当前位置:首页
>
查试题
>
SwitchB为三层交换机,SwitchA为二层交换机,现在要实现研发部和质量部之间的互通,要求SwitchB使用子接口形式实现的配置如下:……# 使连接三层交换机的接口使用trunk方式透传VLAN。[SwitchA] interface gigabitethernet 1/0/5 //(1)[SwitchA-GigabitEthernet1/0/5] (2)[SwitchA-GigabitEthernet1/0/5] port trunk allow-pass (3) [SwitchA-GigabitEthernet1/0/5] quit#接下来配置三层交换机SwitchB,利用子接口对应不同Vlan的网关<HUAWEI> system-view[HUAWEI] sysname SwitchB //修改设备的名称为SwitchB[SwitchB] interface gigabitethernet 1/0/1[SwitchB-GigabitEthernet1/0/1] (4) //配置链路类型为hybrid[SwitchB-GigabitEthernet1/0/1] quit[SwitchB] (5) //创建子接口并进入子接口视图[SwitchB-GigabitEthernet1/0/1.1] (6) //子接口对应接入VLAN 2[SwitchB-GigabitEthernet1/0/1.1] (7) //设置相应的IP地址[SwitchB-GigabitEthernet1/0/1.1] arp broadcast enable //终结子接口默认直接丢弃广播报文,因此需要配置子接口可以转发ARP广播报文的功能[SwitchB-GigabitEthernet1/0/1.1] quit[SwitchB] interface gigabitethernet 1/0/1.2 //创建子接口并进入子接口视图[SwitchB-GigabitEthernet1/0/1.2] dot1q termination vid 3 //子接对应接入VLAN 3[SwitchB-GigabitEthernet1/0/1.2] ip address 2.2.2.1 24[SwitchB-GigabitEthernet1/0/1.2] (8)[SwitchB-GigabitEthernet1/0/1.2] quit