IT Routing and Switching Recap

A fast, hands-on recap of switching and routing in Cisco Packet Tracer: 21 short lessons from first cable to DHCP.

This is a fast, practical recap of switching and routing, built one lab at a time in Cisco Packet Tracer. Each lesson covers one skill. You read a short explanation, look at the slide and the topology, type the exact commands, and then prove it works with the show commands. Every lesson ends with practice questions, a troubleshooting scenario and a lab challenge, so you know whether you can do it without help. Module 1 sets up the foundations: Packet Tracer, cables and interface names, CLI modes, a secure baseline configuration, IP addressing, and console and Telnet access. Module 2 covers VLANs, 802.1Q trunks, router-on-a-stick, routing on a layer 3 switch with SVIs, and a structured way to troubleshoot all of it. Module 3 covers spanning tree: why loops are dangerous, Rapid PVST+ and root bridge placement, PortFast with BPDU Guard, and Root Guard. Module 4 covers EtherChannel with LACP: how the modes negotiate, building an EtherChannel trunk, load balancing and the four faults behind most broken channels. Module 5 adds three skills every network engineer uses: SSH, port security and DHCPv4 on a router. Each module ends with a quiz and a graded practical assignment where you submit your Packet Tracer file and verification output.

Curriculum Outline

Module 1: Foundations

  • 1. Packet Tracer setup and a tour of the window (text)

    You cannot buy ten routers and a dozen switches to practise on. You do not need to. Cisco Packet Tracer gives you all of them on one laptop, and every lab in this recap runs on it.

    1. Packet Tracer setup and a tour of the window

    What Packet Tracer is

    Slide: What is Packet Tracer?. Packet Tracer in four points.
    Packet Tracer in four points.

    Packet Tracer is a free network simulator from Cisco. You place routers, switches and PCs on the screen, cable them together, and type the same IOS commands you would type on real equipment. This recap uses version 8.2.1. If your output looks different from what is described here, check your version first.

    To get it, sign in to Cisco's Skills for All or Networking Academy site, download the installer for your operating system, install it, and sign in once when it first opens.

    Finding your way around

    Slide: The Packet Tracer window. The parts of the Packet Tracer window you will use in every lab.
    The parts of the Packet Tracer window you will use in every lab.
    • Workspace. The big white area in the middle. This is where you build the network.
    • Device box. Bottom left. The top row holds categories such as Network Devices and End Devices. Pick one and you get sub-categories, then the actual models.
    • Device window. Click any device to open it. A switch or router has Physical, Config and CLI tabs. A PC has a Desktop tab with IP Configuration and a Command Prompt.
    • Realtime and Simulation. Bottom right. Realtime is normal operation. Simulation lets you step through packets one at a time.
    • Fast Forward Time. Also bottom right. It moves the simulation clock forward so protocols such as spanning tree and LACP settle quickly. You will use it a lot.

    Lab: your first topology

    1. Open Network Devices, then Switches, and pick the 2960. Click it, then click the workspace.
    2. Open End Devices, then End Devices again, and place a PC.
    3. Click the switch. Look at the Physical, Config and CLI tabs. The CLI tab is where you will spend most of your time.
    4. Click the PC and open the Desktop tab. Find IP Configuration and Command Prompt.
    5. Find the Realtime and Simulation toggle and the Fast Forward Time button.
    6. Save the file: File, Save As, and give it a clear name such as Lab 1.

    Save early and save often. Packet Tracer does not save for you.

    Common mistakes

    • Closing Packet Tracer without saving and losing the whole lab.
    • Typing IOS commands in the Config tab instead of the CLI tab. The Config tab is a shortcut menu, the CLI is what you will be assessed on.

    Practice questions

    Answer each one before you open the explanation.

    Q1. Where do you type Cisco IOS commands on a switch in Packet Tracer?

    1. Desktop tab
    2. CLI tab
    3. Physical tab
    4. Simulation panel
    Show answer

    B. CLI tab The CLI tab opens the switch's command line.

    Q2. Which button makes STP and other protocols settle faster?

    1. Simulation
    2. Reset
    3. Fast Forward Time
    4. Power cycle
    Show answer

    C. Fast Forward Time Fast Forward Time speeds up the simulation clock.

    Q3. Where do you set a PC's IP address?

    1. CLI tab
    2. Desktop > IP Configuration
    3. Config > Settings
    4. Physical tab
    Show answer

    B. Desktop > IP Configuration End devices are addressed under Desktop > IP Configuration.

    Troubleshooting scenario

    A colleague built a lab yesterday but today the file is empty.

    Show model answer

    They closed Packet Tracer without saving. Always use File > Save As before closing, and save often while you work.

    Lab challenge

    Rebuild this lab from a blank workspace without this page open. Then verify it with the show commands from this lesson. If any output differs, find out why before you move on.

  • 2. Cables and interface names (text)

    Plug the wrong cable into the wrong port and nothing works. This lesson covers the two cables you need for almost every lab, and how to read interface names such as Fa0/1 and G0/0/0.

    2. Cables and interface names

    The cables you need

    Slide: Cables you need. Copper straight-through and console cover nearly every lab in this recap.
    Copper straight-through and console cover nearly every lab in this recap.
    • Copper straight-through (solid black line). PC to switch, and switch to router.
    • Switch to switch. In theory this needs a crossover. In practice modern ports and Packet Tracer correct it automatically (auto-MDIX), so straight-through works.
    • Console (light blue). From a laptop's RS 232 port to the device's Console port. It lets you manage a device before it has any IP address.

    Reading interface names

    Slide: Reading interface names. Interface naming and what the link lights mean.
    Interface naming and what the link lights mean.
    • FastEthernet0/1 is a 100 Mb/s port, slot 0, port 1.
    • GigabitEthernet0/1 is a 1 Gb/s port, slot 0, port 1.
    • On the ISR 4331 router you get three numbers: GigabitEthernet0/0/0 is slot 0, sub-slot 0, port 0.

    The link lights tell you the state. Green is up. Orange is starting, or blocked by spanning tree. Red is down.

    Lab: cable the network

    Slide: The lab. The lab: R1, S1, two PCs and a laptop with a console connection.
    The lab: R1, S1, two PCs and a laptop with a console connection.
    Slide: Cabling table. Use this cabling table. Pick the cable yourself each time.
    Use this cabling table. Pick the cable yourself each time.
    1. Click the lightning bolt and choose Copper Straight-Through. Do not use the automatic cable. You need to know what you are choosing.
    2. Click R1, choose GigabitEthernet0/0/0, then click S1 and choose GigabitEthernet0/1.
    3. Connect PC-A to Fa0/5, PC-B to Fa0/6 and LAPTOP-A to Fa0/24.
    4. Choose the Console cable and connect LAPTOP-A's RS 232 port to the S1 Console port.

    The router link stays red. That is expected. Router interfaces are shut down by default, and you will bring it up in lesson 5. On S1, check which ports are up:

    show ip interface brief

    Common mistakes

    • Using the automatic cable and never learning which cable is which.
    • Clicking the wrong port in the interface list, so the cabling does not match the table.

    Practice questions

    Answer each one before you open the explanation.

    Q1. Which cable connects a laptop to a switch's Console port?

    1. Straight-through
    2. Crossover
    3. Console
    4. Fibre
    Show answer

    C. Console The console (rollover) cable goes from RS 232 to Console.

    Q2. What does the 0/0/0 in GigabitEthernet0/0/0 mean?

    1. VLAN, port, speed
    2. Slot, sub-slot, port
    3. Speed, duplex, port
    4. Module, VLAN, port
    Show answer

    B. Slot, sub-slot, port ISR 4000 routers use slot/sub-slot/port.

    Q3. A router link shows red right after cabling. Most likely cause?

    1. Wrong cable
    2. Router interfaces are shut down by default
    3. STP is blocking it
    4. VLAN mismatch
    Show answer

    B. Router interfaces are shut down by default Router interfaces need no shutdown.

    Troubleshooting scenario

    You cabled a PC to a switch and both ends are green, but the router link is red.

    Show model answer

    Nothing is wrong with the cable. The router interface is administratively down. Enter interface configuration on the router and type no shutdown.

    Lab challenge

    Rebuild this lab from a blank workspace without this page open. Then verify it with the show commands from this lesson. If any output differs, find out why before you move on.

  • 3. CLI modes and shortcuts (text)

    Half of all beginner CLI errors come from being in the wrong mode. Learn the four modes and how to move between them, and most of those errors go away.

    3. CLI modes and shortcuts

    The four modes

    Slide: The four modes. The four IOS modes and the prompt for each.
    The four IOS modes and the prompt for each.
    • S1> User EXEC. You can look, but you cannot change anything.
    • S1# Privileged EXEC. Reached with enable. Run show commands, test and save here.
    • S1(config)# Global configuration. Reached with configure terminal. Changes here affect the whole device.
    • S1(config-if)# Interface configuration. Reached with interface followed by a port name. Changes here affect one port.

    Moving around, and the shortcuts

    Slide: Moving and shortcuts. Moving between modes, plus the shortcuts you will use every day.
    Moving between modes, plus the shortcuts you will use every day.
    • exit goes back one level.
    • end jumps straight back to privileged EXEC from any configuration mode.
    • ? lists what you can type at this point.
    • Tab completes a word.
    • Abbreviations work, so conf t is configure terminal.
    • do lets you run a show command from inside configuration mode.
    • The up arrow brings back your last command.

    Lab: walk through every mode

    Open the S1 CLI and type these one at a time. Say the mode out loud after each prompt change.

    enable
    configure terminal
    interface fastEthernet0/5
    exit
    end
    show ?
    conf t
    do show ip interface brief

    Now make a typo on purpose. Type sh ip intr and press Enter. The switch puts a caret ^ under the exact character it did not understand. Read that marker. It tells you where your mistake is.

    Common mistakes

    • Typing configuration commands at the # prompt. hostname and friends only work in global configuration.
    • Running show commands inside configuration mode without do in front.

    Practice questions

    Answer each one before you open the explanation.

    Q1. Which prompt shows global configuration mode?

    1. S1>
    2. S1#
    3. S1(config)#
    4. S1(config-if)#
    Show answer

    C. S1(config)# (config)# is global configuration.

    Q2. Which command takes you straight from interface mode to privileged EXEC?

    1. exit
    2. end
    3. disable
    4. logout
    Show answer

    B. end end returns directly to the # prompt.

    Q3. How do you run show ip interface brief from global configuration mode?

    1. You cannot
    2. show ip interface brief
    3. do show ip interface brief
    4. run show ip interface brief
    Show answer

    C. do show ip interface brief Prefix it with do.

    Troubleshooting scenario

    An engineer types hostname S1 at the S1# prompt and gets an Invalid input error.

    Show model answer

    hostname is a global configuration command. Type configure terminal first, then hostname S1.

    Lab challenge

    Rebuild this lab from a blank workspace without this page open. Then verify it with the show commands from this lesson. If any output differs, find out why before you move on.

  • 4. Basic device configuration: hostname, passwords and banner (text)

    A new Cisco device has no name and no passwords. Anyone with a console cable can take full control. This lesson gives every device the same secure baseline.

    4. Basic device configuration: hostname, passwords and banner

    The baseline every device needs

    Slide: The baseline every device needs. The baseline settings and why each one is there.
    The baseline settings and why each one is there.
    • hostname so you always know which device you are on.
    • no ip domain-lookup so a typo does not freeze the screen while the device looks for a DNS server that does not exist.
    • enable password to protect privileged mode. On real networks use enable secret, which is hashed. Your task sheet will say which one to use, so read it.
    • Console and VTY passwords with login. VTY lines are the remote access lines. Without login the password is stored but never asked for.
    • banner motd as a legal warning.
    • write to save it all to the startup configuration.

    Lab: lock down R1 and S1

    Slide: The lab. The lab: same topology as lesson 2.
    The lab: same topology as lesson 2.
    1. Open the R1 CLI. Answer no to the setup dialog.
    2. Enter the baseline below. The prompt changes as soon as you set the hostname.
    3. For the banner, the # is the start and end marker.
    4. Finish with end and write. You should see Building configuration... [OK].
    5. Repeat on S1 with hostname S1.
    Slide: Baseline commands. All the baseline commands on one screen.
    All the baseline commands on one screen.
    enable
    configure terminal
    hostname R1
    no ip domain-lookup
    enable password class
    line console 0
     password cisco
     login
     exit
    line vty 0 4
     password cisco
     login
     exit
    banner motd #Authorised access only#
    end
    write

    Verify

    Exit all the way out of the CLI and press Enter. You should see the banner and a password prompt. Then log back in and check the lines:

    show running-config | section line

    Both the console and VTY lines should show a password and login.

    Common mistakes

    • Forgetting login, so the password is never asked for.
    • A typo in the password, then locking yourself out.
    • Forgetting write, so everything is gone after a reload.

    Practice questions

    Answer each one before you open the explanation.

    Q1. You set a console password but the device never asks for it. What is missing?

    1. enable secret
    2. login
    3. service password-encryption
    4. write
    Show answer

    B. login login turns on the password check for the line.

    Q2. Which lines are used for Telnet and SSH access?

    1. line console 0
    2. line aux 0
    3. line vty 0 4
    4. line tty 1
    Show answer

    C. line vty 0 4 VTY lines are the virtual remote-access lines.

    Q3. What does no ip domain-lookup prevent?

    1. Remote logins
    2. Delays when a typo is treated as a host name
    3. Saving the configuration
    4. Banner display
    Show answer

    B. Delays when a typo is treated as a host name Mistyped commands are no longer sent to DNS.

    Troubleshooting scenario

    After a power cut, S1 has lost its hostname and passwords.

    Show model answer

    The running configuration was never saved. After configuring, run write (or copy running-config startup-config).

    Lab challenge

    Rebuild this lab from a blank workspace without this page open. Then verify it with the show commands from this lesson. If any output differs, find out why before you move on.

  • 5. IP addressing on a router, a switch and a PC (text)
  • 6. Managing a switch over console and Telnet (text)
  • Quiz: Foundations (quiz)
  • Assignment: Build and secure the foundation lab (assignment)

Module 2: VLANs and Inter-VLAN Routing

  • 7. VLANs: separating Sales and HR on one switch (text)
  • 8. 802.1Q trunks and the 3560 encapsulation trap (text)
  • 9. Router-on-a-stick inter-VLAN routing (text)
  • 10. Inter-VLAN routing on a layer 3 switch with SVIs (text)
  • 11. VLAN and inter-VLAN troubleshooting (text)
  • Quiz: VLANs and Inter-VLAN Routing (quiz)
  • Assignment: Two-site VLAN network with both inter-VLAN routing methods (assignment)

Module 3: Spanning Tree

  • 12. Switching loops and how STP breaks them (text)
  • 13. Rapid PVST+ and choosing the root bridge (text)
  • 14. PortFast and BPDU Guard on access ports (text)
  • 15. Root Guard (text)
  • Quiz: Spanning Tree (quiz)
  • Assignment: Design and protect a predictable spanning tree (assignment)

Module 4: EtherChannel

  • 16. EtherChannel and LACP: active, passive, PAgP and on (text)
  • 17. Configure an LACP EtherChannel trunk step by step (text)
  • 18. EtherChannel load balancing and troubleshooting (text)
  • Quiz: EtherChannel (quiz)
  • Assignment: Build, test and troubleshoot LACP EtherChannel trunks (assignment)

Module 5: SSH, Port Security and DHCPv4

  • 19. Replace Telnet with SSH (text)
  • 20. Port security (text)
  • 21. DHCPv4 on a router (text)
  • Quiz: SSH, Port Security and DHCPv4 (quiz)
  • Assignment: Secure access, port security and DHCP (assignment)