您好,登錄后才能下訂單哦!
<Huawei>sys
[Huawei]sysname R1
[R1]int g0/0/0.10
[R1-GigabitEthernet0/0/0.10]dot1q termination vid 10
//封裝dot1q協(xié)議,該子接口對應(yīng)vlan10
[R1-GigabitEthernet0/0/0.10]ip add 192.168.10.1 24
[R1-GigabitEthernet0/0/0.10]arp broadcast enable
//開啟arp廣播
[R1-GigabitEthernet0/0/0.10]interface g0/0/0.20
[R1-GigabitEthernet0/0/0.20]dot1q termination vid 20
[R1-GigabitEthernet0/0/0.20]ip address 192.168.20.1 24
[R1-GigabitEthernet0/0/0.20]arp broadcast enable
<Huawei>sys
[Huawei]sysname sw1
[SW1]vlan batch 10 20
//創(chuàng)建vlan10 20
[SW1]int e0/0/1
[SW1-Ethernet0/0/1]port link-type access
//配置access鏈路
[SW1-Ethernet0/0/1]port default vlan 10
//接口劃入vlan10
[SW1-Ethernet0/0/1]undo shutdown
[SW1-Ethernet0/0/1]int e0/0/2
[SW1-Ethernet0/0/2]port link-type access
[SW1-Ethernet0/0/2]port default vlan 20
[SW1-Ethernet0/0/2undo shutdown
[SW1-Ethernet0/0/2]int g0/0/1
[SW1-GigabitEthernet0/0/1]port link-type trunk
//配置trunk鏈路
[SW1-GigabitEthernet0/0/1]port trunk allow-pass vlan all
//設(shè)置放行所有vlan
[SW1-GigabitEthernet0/0/1]undo sh
免責(zé)聲明:本站發(fā)布的內(nèi)容(圖片、視頻和文字)以原創(chuàng)、轉(zhuǎn)載和分享為主,文章觀點(diǎn)不代表本網(wǎng)站立場,如果涉及侵權(quán)請聯(lián)系站長郵箱:is@yisu.com進(jìn)行舉報(bào),并提供相關(guān)證據(jù),一經(jīng)查實(shí),將立刻刪除涉嫌侵權(quán)內(nèi)容。