Network lab library

30 ready-made networking labs with step-by-step guidance, hints and scores - plus troubleshooting challenges with hidden faults. Each opens instantly in the free browser simulator.

β–Ά Open the free Network Lab

Guided labs

Two PCs on a switch

Devices: SW1, PC1, PC2
Two PCs on one switch. Open PC1 and run: ping 192.168.1.20
  1. Open PC1 and look at its IP settings (it's 192.168.1.10/24).
  2. From PC1's ⌨ Prompt, ping PC2: ping 192.168.1.20
β–Ά Open this lab

Router between two networks

Devices: R1, SW1, SW2, PC1, PC2
Task: configure R1 (Config tab or CLI):
 enable
 conf t
 int g0/0
 ip add 192.168.1.1 255.255.255.0
 no shut
 int g0/1
 ip add 192.168.2.1 255.255.255.0
 no shut
Then ping 192.168.2.10 from PC1.
  1. Give R1 G0/0 the address 192.168.1.1/24 and turn it on.
  2. Give R1 G0/1 the address 192.168.2.1/24 and turn it on.
  3. Ping PC2 (192.168.2.10) from PC1.
β–Ά Open this lab

VLANs on a switch

Devices: SW1, PC1, PC2, PC3, PC4
Task: put PC1+PC2 in VLAN 10 and PC3+PC4 in VLAN 20 on SW1:
 conf t
 vlan 10
 vlan 20
 int fa0/1
 switchport access vlan 10
 ...
Then press βœ” Check.
  1. Create VLAN 10 and VLAN 20 on SW1.
  2. Put Fa0/1 and Fa0/2 (PC1, PC2) in VLAN 10.
  3. Put Fa0/3 and Fa0/4 (PC3, PC4) in VLAN 20.
  4. Prove it: PC1 reaches PC2 but not PC3.
β–Ά Open this lab

Static routing

Devices: R1, R2, PC1, PC2
Task: the routers don't know each other's LANs. Add static routes:
 R1: ip route 192.168.2.0 255.255.255.0 10.0.0.2
 R2: ip route 192.168.1.0 255.255.255.0 10.0.0.1
  1. On R1, add a route to 192.168.2.0/24 via 10.0.0.2.
  2. On R2, add the route back to 192.168.1.0/24 via 10.0.0.1.
  3. Ping PC2 from PC1 and check the path in πŸ“œ Events.
β–Ά Open this lab

Inter-VLAN routing (router-on-a-stick)

Devices: R1, SW1, PC1, PC2, PC3, PC4
Task: route between VLAN 10 and VLAN 20 on one router port.
 SW1: int g0/1 β†’ switchport mode trunk
 R1: int g0/0 β†’ no shut
     int g0/0.10 β†’ encapsulation dot1Q 10 β†’ ip add 192.168.10.1 255.255.255.0
     int g0/0.20 β†’ encapsulation dot1Q 20 β†’ ip add 192.168.20.1 255.255.255.0
  1. Make SW1's port to R1 (G0/1) a trunk.
  2. Turn on R1 G0/0 (the physical port).
  3. Create G0/0.10 (dot1Q 10) with 192.168.10.1/24.
  4. Create G0/0.20 (dot1Q 20) with 192.168.20.1/24.
  5. PC1 (VLAN 10) pings PC3 (192.168.20.11).
β–Ά Open this lab

Layer-3 switch with SVIs

Devices: MLS1, PC1, PC2, PC3, PC4
Task: make MLS1 route between its VLANs:
 conf t
 ip routing
 int vlan 10
 ip add 10.10.0.1 255.255.255.0
 no shut
 int vlan 20
 ip add 10.20.0.1 255.255.255.0
 no shut
  1. Create interface VLAN 10 with 10.10.0.1/24 and turn it on.
  2. Create interface VLAN 20 with 10.20.0.1/24 and turn it on.
  3. Enable routing on the switch.
  4. PC1 pings PC3 (10.20.0.11).
β–Ά Open this lab

DHCP server on a router

Devices: R1, SW1, PC1, PC2, PC3
Task: make R1 hand out addresses:
 conf t
 ip dhcp excluded-address 192.168.1.1 192.168.1.9
 ip dhcp pool LAN
 network 192.168.1.0 255.255.255.0
 default-router 192.168.1.1
Then on each PC: ipconfig /renew (or the DHCP button).
  1. Exclude 192.168.1.1-192.168.1.9 from DHCP on R1.
  2. Create pool LAN for 192.168.1.0/24 with default-router 192.168.1.1.
  3. Get an address on PC1 (πŸ”„ Get address, or ipconfig /renew).
  4. PC1 pings R1 (192.168.1.1).
β–Ά Open this lab

DHCP server + relay + DNS

Devices: R1, SW1, SW2, SRV1, PC1, PC2
SRV1 runs DHCP + DNS, but it's on another subnet, so DHCP broadcasts can't reach it.
Task: on R1 int g0/1 add: ip helper-address 10.0.0.10
Then renew the PCs and try: ping intranet.local
  1. Try πŸ”„ Get address on PC1 - it fails (APIPA). Why?
  2. On R1 G0/1 add: ip helper-address 10.0.0.10
  3. Renew PC1 - it gets 192.168.50.x from SRV1.
  4. From PC1: ping intranet.local (DNS on SRV1).
β–Ά Open this lab

OSPF between three routers

Devices: R1, R2, R3, PC1, PC2, PC3
Task: run OSPF on all three routers, e.g. on each:
 conf t
 router ospf 1
 network 10.0.0.0 0.0.255.255 area 0
 network 192.168.0.0 0.0.255.255 area 0
Then: show ip ospf neighbor, show ip route. Try shutting a link - traffic reroutes!
  1. Enable OSPF on R1 with networks 10.0.0.0/16 and 192.168.0.0/16 in area 0.
  2. Do the same on R2 and R3.
  3. Check neighbours: show ip ospf neighbor on R1 (should list 2).
  4. Shut R2 G0/1 and ping PC3 from PC2 - OSPF reroutes via R1.
β–Ά Open this lab

RIP v2

Devices: R1, R2, PC1, PC2
Task: the routers are joined by a serial link. Run RIP v2 on both:
 conf t
 router rip
 version 2
 no auto-summary
 network 172.16.0.0
 network 192.168.1.0   (R2: 192.168.2.0)
  1. Enable RIP v2 on R1 with networks 172.16.0.0 and 192.168.1.0.
  2. Enable RIP v2 on R2 with networks 172.16.0.0 and 192.168.2.0.
  3. Ping PC2 from PC1 across the serial link.
β–Ά Open this lab

NAT/PAT to the Internet

Devices: R1, ISP, SW1, WEB, PC1, PC2
The ISP has no route back to your private 192.168.1.0/24, so pings fail.
Task: configure PAT on R1:
 conf t
 access-list 1 permit 192.168.1.0 0.0.0.255
 ip nat inside source list 1 interface g0/0 overload
 int g0/1 β†’ ip nat inside
 int g0/0 β†’ ip nat outside
Then: show ip nat translations
  1. Create access-list 1 permitting 192.168.1.0/24.
  2. Mark G0/1 as NAT inside and G0/0 as NAT outside.
  3. Turn on PAT: ip nat inside source list 1 interface g0/0 overload
  4. PC1 pings WEB (198.51.100.10).
β–Ά Open this lab

ACL: protect a server

Devices: R1, SW1, SW2, PC1, PC2, SRV1
Task: block PC1 (only) from reaching SRV1 with an extended ACL on R1:
 conf t
 access-list 100 deny icmp host 192.168.1.10 host 192.168.2.100
 access-list 100 permit ip any any
 int g0/0
 ip access-group 100 in
  1. Create access-list 100: deny icmp from PC1 to SRV1, then permit everything else.
  2. Apply it inbound on R1 G0/0.
  3. Verify: PC1 is blocked, PC2 still reaches SRV1.
β–Ά Open this lab

Wireless access point

Devices: R1, SW1, AP1, PC1, LAP1, PH1
Wireless devices join AP1; R1 already runs DHCP. Open each device and press πŸ”„ Get address (DHCP), then ping between them.
  1. Get an address on the phone (PH1): open it β†’ πŸ”„ Get address.
  2. Get addresses on PC1 and LAP1 too.
  3. Ping PC1 from the phone.
β–Ά Open this lab

IPv6 static routing

Devices: R1, R2, PC1, PC2
IPv6 is configured on every interface, but the routers don't know the remote LANs.
Task:
 R1: ipv6 route 2001:db8:2::/64 2001:db8:12::2
 R2: ipv6 route 2001:db8:1::/64 2001:db8:12::1
  1. On R1: ipv6 route 2001:db8:2::/64 2001:db8:12::2
  2. On R2: ipv6 route 2001:db8:1::/64 2001:db8:12::1
  3. PC1 pings 2001:db8:2::10.
β–Ά Open this lab

EIGRP between three routers

Devices: R1, R2, R3, PC1, PC2, PC3
Task: run EIGRP AS 100 on all three routers, e.g.:
 conf t
 router eigrp 100
 network 10.1.0.0 0.0.255.255
 network 172.16.0.0
 no auto-summary
Then: show ip eigrp neighbors, show ip route (D routes). R2-R3 is a slow serial link - which path does PC2 take to PC3?
  1. Start EIGRP AS 100 on R1 with networks 10.1.0.0 0.0.255.255 and 172.16.0.0.
  2. Do the same on R2 and R3 (same AS number!).
  3. Check neighbours: show ip eigrp neighbors on R1 (2 neighbours).
  4. PC2 pings PC3 - note it goes via R1 (fast Gigabit) not the slow serial link.
β–Ά Open this lab

Project: build a small office network

Devices: NET1, R1, SW1, PC1, PC2, LAP1, SRV1
Project - build it all yourself (no hints in the steps!):
- VLAN 10 Staff (PC1, PC2, LAP1) = 192.168.10.0/24, VLAN 20 Servers (SRV1) = 192.168.20.0/24
- SW1 g0/1 trunk to R1; R1 routes between VLANs (subinterfaces g0/1.10 / g0/1.20)
- R1 hands out DHCP in VLAN 10 (gateway .1, DNS 8.8.8.8); SRV1 static 192.168.20.10, gateway .1
- Default route to the Internet (203.0.113.1) and PAT for both VLANs
Press βœ” Check to see which goals pass.
  1. Create VLAN 10 and VLAN 20 on SW1, put PC1, PC2, LAP1 in 10 and SRV1 in 20, trunk g0/1.
  2. Router-on-a-stick on R1 (g0/1.10 and g0/1.20 with .1 addresses).
  3. DHCP pool for VLAN 10 on R1; renew PC1, PC2 and LAP1.
  4. Default route + PAT; all goals green in βœ” Check.
β–Ά Open this lab

Huawei switch VLANs + Cisco router

Devices: R1, SW1, PC1, PC2
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
  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.
β–Ά Open this lab

OSPF between Huawei and Cisco routers

Devices: R1, R2, PC1, PC2
Multi-vendor OSPF. Addresses are set. Configure OSPF area 0 on both:
 HUAWEI R1: system-view β†’ ospf 1 β†’ area 0 β†’ network 172.16.0.0 0.0.0.3 β†’ network 10.1.1.0 0.0.0.255
 CISCO R2: en β†’ conf t β†’ router ospf 1 β†’ network 172.16.0.0 0.0.0.3 area 0 β†’ network 10.2.2.0 0.0.0.255 area 0
Verify: display ospf peer (Huawei) / show ip ospf neighbor (Cisco).
  1. Huawei R1: ospf 1, area 0, network statements for both links.
  2. Cisco R2: router ospf 1 with both networks in area 0.
  3. PC1 pings PC2 - OSPF works across vendors.
β–Ά Open this lab

Spanning Tree: who blocks?

Devices: SW1, SW2, SW3, PC1, PC2
Three switches in a triangle = a loop. Spanning Tree blocks one port (amber LED).
Task: run show spanning-tree on each switch. Then make SW1 the root: spanning-tree vlan 1 root primary - watch which port blocks.
  1. Run show spanning-tree on SW3 - find the blocked (BLK) port.
  2. Make SW1 the root: spanning-tree vlan 1 root primary
  3. Check that SW1 is now the root and PC1 still reaches PC2.
β–Ά Open this lab

EtherChannel (LACP)

Devices: SW1, SW2, PC1, PC2
Two links between the switches - STP blocks one, wasting bandwidth.
Task: bundle them on both switches:
 interface range g0/1 - 2
 channel-group 1 mode active
Then: show etherchannel summary and show spanning-tree (one logical link, nothing blocked).
  1. On SW1: interface range g0/1 - 2 β†’ channel-group 1 mode active
  2. On SW2: the same (mode active or passive).
  3. Verify: no port is blocked and PC1 reaches PC2.
β–Ά Open this lab

HSRP: a gateway that never dies

Devices: R1, R2, SW1, PC1, PC2
The PCs use 192.168.1.254 as gateway - but no router owns it yet.
Task:
 R1 g0/0: standby 1 ip 192.168.1.254 Β· standby 1 priority 110 Β· standby 1 preempt
 R2 g0/0: standby 1 ip 192.168.1.254
Then shut R1 g0/0 - R2 takes over and PC1 still pings .254. show standby brief.
  1. R1 g0/0: standby 1 ip 192.168.1.254 and priority 110.
  2. R2 g0/0: standby 1 ip 192.168.1.254
  3. PC1 pings 192.168.1.254 (R1 is Active).
  4. Shut R1 g0/0 - PC1 can still ping .254 (R2 took over).
β–Ά Open this lab

Port security

Devices: SW1, HUB1, PC1, LAP1, PC2
SW1 Fa0/1 goes to a hub where PC1 sits. Lock that port to one device:
 int fa0/1 β†’ switchport mode access β†’ switchport port-security β†’ switchport port-security mac-address sticky
Then connect the rogue laptop LAP1 to the hub - the port goes err-disabled! (show port-security, show interfaces status). Recover with shutdown / no shutdown after removing it.
  1. On SW1 int fa0/1: switchport port-security + mac-address sticky
  2. Cable the rogue laptop LAP1 to HUB1.
  3. See the violation: show port-security / show interfaces status (err-disabled).
  4. Remove LAP1's cable, then shutdown + no shutdown on fa0/1. PC1 works again.
β–Ά Open this lab

Secure remote access (SSH)

Devices: R1, SW1, PC1
Task: allow only SSH to R1 with a local user:
 ip domain-name nanotech.local
 crypto key generate rsa
 username admin secret Cisco123
 enable secret class
 line vty 0 4 β†’ transport input ssh β†’ login local
Then from PC1: ssh -l admin 192.168.1.1 (password Cisco123). Try telnet 192.168.1.1 - it's refused.
  1. Set a domain name and generate RSA keys.
  2. Create user admin and allow only SSH with login local.
  3. From PC1: ssh -l admin 192.168.1.1
β–Ά Open this lab

To the Internet: NAT + DNS + web

Devices: NET1, R1, SW1, PC1, LAP1
NET1 is the Internet (its link to you is 203.0.113.1). Task on R1:
 ip route 0.0.0.0 0.0.0.0 203.0.113.1
 access-list 1 permit 192.168.1.0 0.0.0.255
 ip nat inside source list 1 interface g0/0 overload
 g0/1: ip nat inside Β· g0/0: ip nat outside
Then from PC1: ping 8.8.8.8 and http www.example.com
  1. Add a default route on R1 to 203.0.113.1.
  2. Configure PAT (access-list 1 + ip nat inside/outside + overload).
  3. From PC1: ping 8.8.8.8
  4. From PC1: http www.example.com (DNS 8.8.8.8 resolves it).
β–Ά Open this lab

IPv6 SLAAC + OSPFv3

Devices: R1, R2, SW1, SW2, PC1, PC2
Task:
1. On PC1 and PC2 run: ipconfig /renew6 (SLAAC builds an address from the router's prefix + MAC).
2. Run OSPFv3 on both routers: ipv6 router ospf 1, then on each interface: ipv6 ospf 1 area 0
3. Ping PC2's new IPv6 address from PC1.
  1. On PC1 and PC2: ipconfig /renew6
  2. Run OSPFv3 on both routers on all interfaces.
  3. PC1 pings PC2's IPv6 address.
β–Ά Open this lab

Troubleshooting challenges

πŸ”§ Fix 1: PC can't leave its network

Devices: R1, SW1, SW2, PC1, PC2
Users say PC1 can reach other PCs on its LAN but nothing beyond the router. PC2 is fine. Find and fix the fault.
β–Ά Open this lab

πŸ”§ Fix 2: same VLAN, no ping

Devices: SW1, PC1, PC2, PC3, PC4
PC1 and PC2 are both meant to be in VLAN 10, but they can't ping each other. Find out why.
β–Ά Open this lab

πŸ”§ Fix 3: one-way routing

Devices: R1, R2, PC1, PC2
Both routers have static routes, yet PC1 β†’ PC2 fails. The Events log says the request arrives… so what's wrong?
β–Ά Open this lab

πŸ”§ Fix 4: inter-VLAN broken

Devices: R1, SW1, PC1, PC2, PC3, PC4
Router-on-a-stick is fully configured on R1, but no PC can reach its gateway. Check the switch side.
β–Ά Open this lab

πŸ”§ Fix 5: odd subnet problem

Devices: R1, SW1, SW2, PC1, PC2
PC1 can ping R1 but not PC2 (192.168.2.10), even though R1 routes fine. Look closely at PC1's settings.
β–Ά Open this lab