Routing and switching study Day 10: Inter Vlan communication

Routing and switching study Day 10: Inter Vlan communication
<HW-SW4> sys // The system view
[HW-SW4] stp mode stp // mode spanning the STP
[HW-SW4 is] // build VLAN BATCH VLAN20 30 and 20 is 30
[HW-SW4 is] interface G 0 / // enter a 0/1 configuration
[HW-SW4-GigabitEthernet0 / 0 /1] port link-type access // inlet port
[HW-SW4-GigabitEthernet0 / 0 /1] port default vlan 20 // port VLAN labeled 20 is
[-HW-SW4 is the GigabitEthernet0 / 0 /. 1] // enable port STP-edged edge interface port
[HW-SW4-GigabitEthernet0 / 0 /2] port link-type access // inlet port
[HW- SW4-GigabitEthernet0 / 0/2] port default vlan 30 // port VLAN tag 30
[HW-SW4-GigabitEthernet0 / 0 / 2] // enable port STP-edged edge interface port
[HW-SW4-GigabitEthernet0 / 0 / 2] int g 0/0/10 // 10 into the configuration
[HW-SW4-GigabitEthernet0 / 0 /10] port link-type trunk // port Trunk
[-HW-SW4 is the GigabitEthernet0 / 0/10] the allow Trunk port -pass vlan all // allow all VLAN by
[HW-SW4] dis port vlan active // ​​information about the VLAN ports

T =TAG U=UNTAG

Port Link Type PVID VLAN List

GE0/0/1 access 20 U: 20
GE0/0/2 access 30 U: 30
GE0/0/3 hybrid 1 U: 1
GE0/0/4 hybrid 1 U: 1
GE0/0/5 hybrid 1 U: 1
GE0/0/6 hybrid 1 U: 1
GE0/0/7 hybrid 1 U: 1
GE0/0/8 hybrid 1 U: 1
GE0/0/9 hybrid 1 U: 1
GE0/0/10 trunk 1 U: 1
T: 20 30
![]

===============================================

<Huawei>sys //进入系统视图
[Huawei]SYS HW-R3 //系统名称为HW-R3
[HW-R3]interface GigabitEthernet 0/0/0.20 //创建0/0/0.20的子端口
[HW-R3-GigabitEthernet0/0/0.20]dot1q termination vid 20 //该子接口接收vlan20通信
[HW-R3-GigabitEthernet0/0/0.20]ip address 10.1.20.30 27 //该端口地址为10.1.20.30
[HW-R3-GigabitEthernet0/0/0.20]interface GigabitEthernet 0/0/0.30 //创建0/0/0.30的子端口
[HW-R3-GigabitEthernet0/0/0.30]dot1q termination vid 30 //该子接口接收vlan30通信
[HW-R3-GigabitEthernet0/0/0.30]ip address 10.1.30.30 27 //该端口地址为10.1.30.30

[HW-R3]interface GigabitEthernet 0/0/0.20 //配置0/0/0.20的子端口
[HW-R3-GigabitEthernet0/0/0.20]arp broadcast enable //开启ARP广播
[HW-R3-GigabitEthernet0/0/0.20]interface GigabitEthernet 0/0/0.30 //配置0/0/0.30的子端口
[HW-R3-GigabitEthernet0/0/0.30]arp broadcast enable //开启ARP广播

Routing and switching study Day 10: Inter Vlan communication
Routing and switching study Day 10: Inter Vlan communication

==================================================

[HW-SW1]interface Vlanif 8 //配置vlangif8
[HW-SW1-Vlanif8]ip address 10.1.10.13 28 //配置IP地址
[HW-SW1-Vlanif8]int vlan 9 //配置vlangif9
[HW-SW1-Vlanif9]ip address 10.1.10.28 28 //配置IP地址
[HW-SW1-Vlanif9]int vlan 10 //配置vlangif10
[HW-SW1-Vlanif10]ip address 10.1.10.45 28 //配置IP地址

[HW-SW2] interface Vlanif 8 // configuration vlangif8
[HW-SW2-Vlanif8] // IP address to configure the IP address of 10.1.10.13 28
[HW-SW2-Vlanif8] int vlan 9 // configuration vlangif9
[HW-SW2-Vlanif9 ] ip address 10.1.10.28 28 // configure the IP address
int vlan 10 // configuration [HW-SW2-Vlanif9] vlangif10
[HW-SW2-Vlanif10] // IP address to configure the IP address of 10.1.10.45 28

Routing and switching study Day 10: Inter Vlan communication

Routing and switching study Day 10: Inter Vlan communication

Guess you like

Origin blog.51cto.com/63736/2428393