Huawei switch VLANs + Cisco router

Practise this lab in the free NanoTech-kw Network Lab - a Cisco-style simulator that runs in your browser, with hints, an event log and automatic checking.

โ–ถ Open the free Network Lab

Devices: R1, SW1, PC1, PC2

Your task

The Cisco router is ready (router-on-a-stick). Configure the HUAWEI switch with Huawei commands:
 system-view
 vlan batch 10 20
 interface GigabitEthernet0/0/1 โ†’ port link-type access โ†’ port default vlan 10 โ†’ quit
 interface GigabitEthernet0/0/2 โ†’ port link-type access โ†’ port default vlan 20 โ†’ quit
 interface GigabitEthernet0/0/24 โ†’ port link-type trunk โ†’ port trunk allow-pass vlan 10 20
Check with: display vlan, display current-configuration

Step by step

  1. On the Huawei switch: system-view, then vlan batch 10 20.
  2. Put GE0/0/1 in VLAN 10 and GE0/0/2 in VLAN 20 (port link-type access, port default vlan).
  3. Make GE0/0/24 a trunk (port link-type trunk).
  4. PC1 pings PC2 across VLANs.

โ–ถ Start this lab in the browser๐Ÿ“– Command guide๐Ÿงญ Watch how Ethernet switching works

More labs

Two PCs on a switchRouter between two networksVLANs on a switchStatic routingInter-VLAN routing (router-on-a-stick)Layer-3 switch with SVIsDHCP server on a routerDHCP server + relay + DNSOSPF between three routersRIP v2NAT/PAT to the InternetACL: protect a serverWireless access pointIPv6 static routingEIGRP between three routersProject: build a small office networkOSPF between Huawei and Cisco routersSpanning Tree: who blocks?EtherChannel (LACP)HSRP: a gateway that never diesPort securitySecure remote access (SSH)To the Internet: NAT + DNS + webIPv6 SLAAC + OSPFv3๐Ÿ”ง Fix 1: PC can't leave its network๐Ÿ”ง Fix 2: same VLAN, no ping๐Ÿ”ง Fix 3: one-way routing๐Ÿ”ง Fix 4: inter-VLAN broken๐Ÿ”ง Fix 5: odd subnet problem