您好,欢迎访问三七文档
当前位置:首页 > IT计算机/网络 > C/C++资料 > H3C交换机Trunk端口配置
组网需求:1.SwitchA与SwitchB用trunk互连,相同VLAN的PC之间可以互访,不同VLAN的PC之间禁止互访;2.PC1与PC2之间在不同VLAN,通过设置上层三层交换机SwitchB的VLAN接口10的IP地址为10.1.1.254/24,VLAN接口20的IP地址为20.1.1.254/24可以实现VLAN间的互访。组网图:1.VLAN内互访,VLAN间禁访2.通过三层交换机实现VLAN间互访配置步骤:实现VLAN内互访VLAN间禁访配置过程SwitchA相关配置:1.创建(进入)VLAN10,将E0/1加入到VLAN10[SwitchA]vlan10[SwitchA-vlan10]portEthernet0/12.创建(进入)VLAN20,将E0/2加入到VLAN20[SwitchA]vlan20[SwitchA-vlan20]portEthernet0/23.将端口G1/1配置为Trunk端口,并允许VLAN10和VLAN20通过[SwitchA]interfaceGigabitEthernet1/1[SwitchA-GigabitEthernet1/1]portlink-typetrunk[SwitchA-GigabitEthernet1/1]porttrunkpermitvlan1020SwitchB相关配置:1.创建(进入)VLAN10,将E0/10加入到VLAN10[SwitchB]vlan10[SwitchB-vlan10]portEthernet0/102.创建(进入)VLAN20,将E0/20加入到VLAN20[SwitchB]vlan20[SwitchB-vlan20]portEthernet0/203.将端口G1/1配置为Trunk端口,并允许VLAN10和VLAN20通过[SwitchB]interfaceGigabitEthernet1/1[SwitchB-GigabitEthernet1/1]portlink-typetrunk[SwitchB-GigabitEthernet1/1]porttrunkpermitvlan1020通过三层交换机实现VLAN间互访的配置SwitchA相关配置:1.创建(进入)VLAN10,将E0/1加入到VLAN10[SwitchA]vlan10[SwitchA-vlan10]portEthernet0/12.创建(进入)VLAN20,将E0/2加入到VLAN20[SwitchA]vlan20[SwitchA-vlan20]portEthernet0/23.将端口G1/1配置为Trunk端口,并允许VLAN10和VLAN20通过[SwitchA]interfaceGigabitEthernet1/1[SwitchA-GigabitEthernet1/1]portlink-typetrunk[SwitchA-GigabitEthernet1/1]porttrunkpermitvlan1020SwitchB相关配置:1.创建VLAN10[SwitchB]vlan102.设置VLAN10的虚接口地址[SwitchB]interfacevlan10[SwitchB-int-vlan10]ipaddress10.1.1.254255.255.255.03.创建VLAN20[SwitchB]vlan204.设置VLAN20的虚接口地址[SwitchB]interfacevlan20[SwitchB-int-vlan20]ipaddress20.1.1.254255.255.255.05.将端口G1/1配置为Trunk端口,并允许VLAN10和VLAN20通过[SwitchA]interfaceGigabitEthernet1/1[SwitchA-GigabitEthernet1/1]portlink-typetrunk[SwitchA-GigabitEthernet1/1]porttrunkpermitvlan1020
本文标题:H3C交换机Trunk端口配置
链接地址:https://www.777doc.com/doc-7028870 .html