資源描述:
《交換機(jī)配置跨交換機(jī)間的通信》由會員上傳分享,免費在線閱讀,更多相關(guān)內(nèi)容在學(xué)術(shù)論文-天天文庫。
1、一組網(wǎng)需求:1.SwitchA與SwitchB用trunk互連,相同VLAN的PC之間可以互訪,不同VLAN的PC之間禁止互訪;2.PC1與PC2之間在不同VLAN,通過設(shè)置上層三層交換機(jī)SwitchB的VLAN接口10的IP地址為10.1.1.254/24,VLAN接口20的IP地址為20.1.1.254/24可以實現(xiàn)VLAN間的互訪。二組網(wǎng)圖:1.VLAN內(nèi)互訪,VLAN間禁訪一、實現(xiàn)VLAN內(nèi)互訪VLAN間禁訪配置過程SwitchA相關(guān)配置:1.創(chuàng)建(進(jìn)入)VLAN10,將E0/1加入到VLAN10[SwitchA]vlan10[SwitchA-vlan10]por
2、tEthernet0/12.創(chuàng)建(進(jìn)入)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相關(guān)配置:1.創(chuàng)建(進(jìn)入)VLAN10,將E0/
3、10加入到VLAN10[SwitchB]vlan10[SwitchB-vlan10]portEthernet0/102.創(chuàng)建(進(jìn)入)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]porttr
4、unkpermitvlan1020二、通過三層交換機(jī)實現(xiàn)VLAN間互訪通過三層交換機(jī)實現(xiàn)VLAN間互訪的配置SwitchA相關(guān)配置:1.創(chuàng)建(進(jìn)入)VLAN10,將E0/1加入到VLAN10[SwitchA]vlan10[SwitchA-vlan10]portEthernet0/12.創(chuàng)建(進(jìn)入)VLAN20,將E0/2加入到VLAN20[SwitchA]vlan20[SwitchA-vlan20]portEthernet0/23.將端口G1/1配置為Trunk端口,并允許VLAN10和VLAN20通過[SwitchA]interfaceGigabitEthernet1/
5、1[SwitchA-GigabitEthernet1/1]portlink-typetrunk[SwitchA-GigabitEthernet1/1]porttrunkpermitvlan1020SwitchB相關(guān)配置:1.創(chuàng)建VLAN10[SwitchB]vlan102.設(shè)置VLAN10的虛接口地址[SwitchB]interfacevlan10[SwitchB-int-vlan10]ipaddress10.1.1.254255.255.255.03.創(chuàng)建VLAN20[SwitchB]vlan204.設(shè)置VLAN20的虛接口地址[SwitchB]interfacevla
6、n20[SwitchB-int-vlan20]ipaddress20.1.1.254255.255.255.05.將端口G1/1配置為Trunk端口,并允許VLAN10和VLAN20通過[SwitchB]interfaceGigabitEthernet1/1[SwitchB-GigabitEthernet1/1]portlink-typetrunk[SwitchB-GigabitEthernet1/1]porttrunkpermitvlan1020