Skip to main content

Day 9: Switch Interfaces

CCNASwitch 200-301Interfaces

Study

Overview

Guide:

What are Switch Interface Configuration & Troubleshooting

Introduction: Mastering the Fundamentals of Network Access

The configuration of Layer 2 switchports is a fundamental skill for network professionals. It represents the point of entry for all devices into the network. This guide covers default states, speed/duplex negotiation, collision domains, and essential troubleshooting commands.Interfaces?

CCNA Exam Objectives Covered:

  • 1.1:Physical Roleports andon functiona ofswitch networkwhere componentsdevices (Switches)PCs, servers, routers, other switches) connect

  • 1.4: IdentifyEach interface andcan cablebe issuesindependently (collisions,configured errors,with duplex/speeddifferent mismatch)settings

  • 2.1: ConfigureConfiguration and verifystatus Layermonitoring 2is protocolsdone (Switching)through the Cisco CLI

Key Difference from Routers:

Unlike routers (which default to administratively down), switch interfaces are active by default and don't require no shutdown to enable them.

 


 

1.0Viewing DefaultSwitch Interface States: Routers vs. SwitchesStatus

show ip interface brief

CiscoSW1# devicesshow haveip differentinterface defaultbrief

behaviors


based

This command displays a summary of all interfaces on theirthe role. Switches are generally "plug-and-play," while routers follow a "security-first" approach.switch.

1.1

Output Comparative Analysis of Default SettingsColumns:

FeatureColumn

RouterWhat InterfaceIt Shows

Switch InterfaceDetails

Default StateInterface

DisabledPort (shutdown)name

EnabledFa0/1, Fa0/2, Gi0/1, etc.

IP Address

IP address assigned to interface

Most switch interfaces don't have IPs assigned

Method

How IP was assigned

manual, DHCP, etc. (norarely shutdown)used on access ports)

Status (Unplugged)L1)

administrativelyPhysical downlayer / downstatus

up = connected, down /= downnot connected

StatusProtocol (Connected)L2)

Data link layer status

up /= upoperational, (afterdown manual= enable)

problem

up / up (immediate)

Security Practice

Enable only necessary ports.

Shutdown all unused ports.detected

SecurityStatus Note: Because switchports are active by default, an unauthorized user can gain network access just by plugging in. Always manually disable unused ports.

2.0 Mastering Speed and Duplex Settings

    Speed: The data rate (10, 100, 1000 Mbps).

    Duplex: The direction of flow (Half = one way at a time; Full = simultaneous).

    2.1 The Autonegotiation Process

    By default, ports use autonegotiation to find the highest common denominator for speed and duplex. If a 1 Gbps port connects to a 100 Mbps port, they agreeMeanings on 100 Mbps/Full.Switches:

    2.2 The Duplex Mismatch

    A mismatch occurs when one side is hardcoded (manual) and the other is set to Auto. The "Auto" side disables negotiation and must guess:

      Speed: Sensed via electrical signal (usually successful).

      Duplex Rule:

        If Speed = 10 or 100 Mbps $\rightarrow$ Default to Half-Duplex.

        If Speed = 1000 Mbps or higher $\rightarrow$ Default to Full-Duplex.

        Result: A 100 Mbps link where one side is Full and the other defaults to Half causes massive Late Collisions and CRC errors.

        3.0 Understanding Collision Domains and CSMA/CD

        DeviceStatus

        Collision Domain LogicProtocol

        Duplex CapabilityMeaning

        Hub (Layer 1)up

        All ports share one collision domain.up

        Half-DuplexInterface only.is connected and operational

        Switch (Layer 2)down

        Each port is a separate collision domain.down

        Full-Interface has no cable or no device connected

        administratively down

        down

        Interface has been disabled with shutdown

        Key Difference: Unlike routers, switch interfaces do NOT default to "administratively down" — they are active by default.

        show interfaces status

        SW1# show interfaces status


        This provides a more detailed view of all interfaces.

        Output Columns:

        Column

        Purpose

        Port

        Interface name (Fa0/1, Fa0/2, etc.)

        Name

        Description assigned to the interface (for organization)

        Status

        connected, notconnect, disabled, err-disabled

        VLAN

        VLAN assignment (default is VLAN 1)

        Duplex

        half, full, or auto

        Speed

        10, 100, 1000 (Mbps) or auto

        Type

        10/100BaseTX, 10/100/1000BaseTX, etc.

         


         

        Interface Configuration Basics

        Entering Interface Configuration Mode

        SW1# configure terminal

        SW1(config)# interface fastethernet 0/1

        SW1(config-if)#


        Or use shorthand:

        SW1(config)# interface fa0/1

        SW1(config-if)#


        Adding a Description

        SW1(config-if)# description ## Connection to PC1 ##


        Descriptions are useful for documenting what each port is connected to.

        Disabling an Interface

        SW1(config-if)# shutdown


          Puts interface in "administratively down" status

          Useful for security (disabling unused ports)

          Can be re-enabled with no shutdown

          Enabling a Disabled Interface

          SW1(config-if)# no shutdown


           


           

          Configuring Multiple Interfaces at Once

          Interface Range Command

          Manually configuring each unused interface would be tedious. Use the interface range command:

          SW1(config)# interface range fastethernet 0/5 - 12

          SW1(config-if-range)#


          This selects interfaces Fa0/5 through Fa0/12 (inclusive).

          Apply configuration to all selected interfaces:

          SW1(config-if-range)# description ## Not in use ##

          SW1(config-if-range)# shutdown


          Both commands are applied to all 8 interfaces (0/5, 0/6, 0/7, ... 0/12) at once.

          Verify the changes:

          SW1# show interfaces status


          You should see all the selected interfaces now show "disabled" status.

          Other Range Syntax

          // Separate specific interfaces

          SW1(config)# interface range fa0/1, fa0/5, fa0/10

          SW1(config-if-range)# shutdown


          // Combine multiple ranges

          SW1(config)# interface range fa0/1 - 5, fa0/10 - 15

          SW1(config-if-range)# shutdown


           


           

          Duplex capable.and Collisions

          Half Duplex vs. Full Duplex

          Half Duplex:

            Device cannot send AND receive at the same time

            Must wait to receive before sending

            Must wait to send before receiving

            Like a walkie-talkie — only one person can talk at a time

            Full Duplex:

              Device can send AND receive simultaneously

              No waiting required

              Like a telephone — both parties can talk at the same time

              More efficient, uses available bandwidth fully

              Modern Switch Reality

              Most modern switches and devices support Full Duplex.

              Half duplex is virtually unused today, except in legacy or specialized scenarios.

              Historical Context: Hubs vs. Switches

              Hubs (Layer 1 Devices):

                Simple repeaters that flood frames to all ports

                All connected devices share the same collision domain

                When multiple devices send simultaneously, collisions occur (frames corrupt each other)

                All devices use Half Duplex (because collisions are common)

                Use CSMA/CD to detect and handle collisions

                Switches (Layer 2 Devices):

                  Intelligent devices that forward frames based on MAC addresses

                  Each port has its own collision domain

                  Collisions rarely occur (only within the same port pair, very unlikely)

                  All devices can use Full Duplex (no collision risk)

                  CSMA/CD is almost never triggered

                  CSMA/CD (Carrier Sense Multiple Access with Collision Detection)

                  How it works (for historical context):

                    Device listens to the network (carrier sense)

                    Waits until no other devices are transmitting

                    Begins transmitting data

                    If collision detected (two devices send at once), jam signal is sent

                    All devices stop transmitting

                    Each device waits a random amount of time

                    Retry transmission

                    Process repeats until successful

                    Why it's obsolete: Full Duplex switches make collisions impossible within normal operation.

                     


                     

                    Speed and Duplex Autonegotiation

                    Default Settings

                    Modern switch interfaces support automatic negotiation of speed and duplex:

                    Interface Type | Default Speed | Default Duplex |

                    10/100 | Auto | Auto |

                    10/100/1000 | Auto | Auto |


                    How autonegotiation works:

                      Both devices advertise their capabilities (speeds and duplex modes they support)

                      Devices negotiate the best mutually supported speed and duplex

                      Both ends use the negotiated settings

                      Example:

                      Device A: Supports 10/100/1000 Full Duplex

                      Device B: Supports 10/100 Full Duplex

                      Result: Both use 100 Mbps Full Duplex (best common speed)


                      What Happens When Autonegotiation Fails?

                      If a device doesn't support autonegotiation (or it's disabled), the switch must guess:

                      Speed Fallback:

                        Switch tries to detect the speed the other device is using

                        If detection fails, defaults to the slowest supported speed

                        Example: On a 10/100/1000 interface, defaults to 10 Mbps

                        Duplex Fallback:

                        Speed

                        Default Duplex

                        10 Mbps

                        Half Duplex

                        100 Mbps

                        Half Duplex

                        1000 Mbps

                        Full Duplex

                        Why this matters:

                          Mismatched duplex causes performance problems and errors

                          Speed mismatch causes data loss or slow throughput

                          Always ensure both sides match or both use autonegotiation

                          Manually Configuring Speed and Duplex

                          If autonegotiation isn't working properly, manually set the interface:

                          SW1(config-if)# speed 100

                          SW1(config-if)# duplex full


                          Both sides must match manually (best practice: set both to auto if possible).

                           


                           

                          Interface Errors and Counters

                          Viewing Interface Statistics

                          SW1# show interfaces fastethernet 0/1


                          This displays detailed statistics including error counters at the bottom.

                          Error Types and Meanings

                          Frame Reception Statistics:

                          Counter

                          Meaning

                          Normal?

                          Runts

                          Frames smaller than minimum 64 bytes

                          Should be 0

                          Giants

                          Frames larger than maximum 1518 bytes

                          Should be 0

                          CRC Errors

                          Frames that failed CRC check (FCS trailer)

                          Should be 0

                          Frame Errors

                          Frames with incorrect format due to errors

                          Should be 0

                          Aggregated Counters:

                          Counter

                          Meaning

                          Input Errors

                          Total of various receive errors (runts, CRC, frame, etc.)

                          Output Errors

                          Count of frames switch tried to send but failed

                          3.1What TheThese RoleErrors ofIndicate

                          CSMA/CD

                          Error Type

                          Common Causes

                          Runts

                          Cable issues, duplex mismatch, electromagnetic interference (EMI)

                          Giants

                          Device doesn't properly enforce frame size limits, MTU mismatch

                          CRC Errors

                          Bad cable, duplex mismatch, EMI, faulty NIC

                          Frame Errors

                          Cable problems, duplex mismatch, hardware failure

                          Output Errors

                          Switch interface hardware problem, buffer overflow

                          Troubleshooting with Error Counters

                          CarrierHigh Senserunt/CRC Multipleerrors?

                          Access
                          with Collision

                          Check Detectioncable managesquality mediaand accessconnections

                          in Half-Duplex environments.

                          Verify duplex settings on both ends

                          Check for electrical interference

                          Replace faulty cable or NIC

                          Increasing errors after configuration change?

                            Verify speed/duplex settings match on both ends

                            Check if autonegotiation is conflicting

                            Look at interface utilization (might be saturated)

                             


                             

                            Complete Interface Configuration Example

                            Scenario: Setting up a PC Connection

                            Requirements:

                            • Full-Duplex:Connect CollisionsPC areto impossible; CSMA/CD is disabled.Fa0/1

                            • Half-Duplex:Label Devicesthe mustport

                              listen
                            before talking;

                            Ensure CSMA/CDit's enabled

                            Verify speed/duplex is enabled.auto (default)

                            Configuration:

                            SW1# configure terminal

                            SW1(config)# interface fastethernet 0/1

                            SW1(config-if)# description ## PC1 - Finance Department ##

                            SW1(config-if)# speed auto

                            SW1(config-if)# duplex auto

                            SW1(config-if)# no shutdown

                            SW1(config-if)# exit


                            // Verify configuration

                            SW1# show interfaces status


                            Expected output:

                            Port      Name                          Status    Vlan   Duplex  Speed Type

                            Fa0/1     ## PC1 - Finance Dept ##      connected  1      auto   auto  10/100BaseTX


                             


                             

                            4.0Disabling VerificationUnused Ports for Security

                            The Problem

                            Unused ports are a security risk — unauthorized devices can connect and Troubleshootingaccess the network.

                            The Solution: Disable Them

                            SW1# configure terminal

                            SW1(config)# interface range fastethernet 0/5 - 28

                            SW1(config-if-range)# description ## Unused - Security ##

                            SW1(config-if-range)# shutdown

                            SW1(config-if-range)# exit


                            // Verify

                            SW1# show interfaces status


                            Result:

                            All ports Fa0/5 through Fa0/28 now show "disabled" status and will not accept any connections.

                             


                             

                            Quick Reference: Common Interface Commands

                            4.Configuration Mode

                            Command

                            Purpose

                            interface fa0/1

                            Enter interface configuration mode

                            interface range fa0/1 Essential- "show"5

                            Commands

                            Configure multiple interfaces at once

                            description <text>

                            Add description to interface

                            no shutdown

                            Enable interface

                            shutdown

                            Disable interface

                            speed 10 | 100 | 1000 | auto

                            Set interface speed

                            duplex half | full | auto

                            Set duplex mode

                            Privileged EXEC Mode

                            Command

                            Purpose

                            show ip interface brief

                            High-levelSummary status:of Statusall (L1) and Protocol (L2).interfaces

                            show interfaces status

                            (SwitchDetailed only)interface Tabular view of VLAN, Speed, and Duplex.status

                            show interfaces <id>fa0/1

                            Detailed countersstats andfor errorone statistics.interface

                            show interfaces description

                            Show interface descriptions

                            4.2

                             Interpreting

                            Error Counters

                              Runts: Frames $< 64$ bytes. Often caused by collisions.

                              Summary

                              Table: Interface Status States

                              Giants: Frames $> 1518$ bytes.Status

                              CRC:Protocol

                              Checksum failure. Indicates

                              Meaning

                              corrupted data, usually

                              Solution

                              due to
                              badcabling

                              up

                              up

                              Operational

                              None needed

                              down

                              down

                              No cable or EMI.device

                              LateCheck Collisions:cable, Occurreconnect after the first 64 bytes. The primary indicator of a duplex mismatch or excessive cable length ($> 100$m).device

                              5.0 CLI Configuration Command Reference

                              5.1 Basic Interface Setup

                              SW1(config)# interface g0/1down

                              SW1(config-if)# description ## Connection to Server_01 ##down

                              SW1(config-if)# speed 100           # Manual speed: 10, 100, 1000Disabled

                              SW1(config-if)#

                              duplex full         # Manual duplex: full, half

                              SW1(config-if)# shutdown            # Disable port

                              SW1(config-if)#Use no shutdown #to Enable portenable


                              up

                              5.2

                              Bulk Configuration

                              SW1(config)# interface range f0/1 - 10, g0/1 - 2down

                              SW1(config-if-range)#Physical descriptiongood, ##L2 User Access Ports ##problem

                              SW1(config-if-range)#Check shutdownconfigurations, VLAN issues


                               

                              5.3 Saving Configuration


                                Standard: copy running-config startup-config

                                Shortcuts: copy run start or write memory (wr)

                                6.0 Key Takeaways Summaryfor CCNA

                                  ✅

                                  Switch

                                  Defaults: Switchportsinterfaces are active by default — no shutdown by default; Router ports are shutdown by default.

                                  Mismatches: If autonegotiation fails at 10/100 Mbps, the auto-side defaultsneeded to Half-Duplex.enable them (unlike routers)

                                  ✅

                                  show

                                  Troubleshooting:ip Useinterface brief shows summary status; show interfaces status shows detailed info

                                  ✅ Interface range command allows configuring multiple ports at once for efficiency

                                  ✅ Full Duplex is standard on modern switches; Half Duplex is legacy (used with hubs)

                                  ✅ CSMA/CD was used to finddetect Latecollisions Collisionson hubs; obsolete with full-duplex switches

                                  ✅ Autonegotiation lets devices automatically negotiate speed and duplex (Mismatch)default and preferred)

                                  ✅ Mismatched speed/duplex causes performance problems and errors

                                  ✅ Error counters (runts, giants, CRC) indicate cable, duplex, or CRChardware Errors (Bad Cable).issues

                                  ✅

                                  Disable unused ports with shutdown command for security

                                  CSMA/CD:✅ Only activeDescriptions on Half-interfaces help with organization and troubleshooting

                                  ✅ Always verify interface status after making changes using show commands

                                  ✅ Typical default is Speed auto, Duplex links.auto — change only if autonegotiation fails