You are previewing CCNA Routing and Switching Portable Command Guide.
O'Reilly logo
CCNA Routing and Switching Portable Command Guide

Book Description

Here are all the CCNA-level Routing and Switching commands you need in one condensed, portable resource. CCNA Routing and Switching Portable Command Guide is filled with valuable, easy-to-access information–and it’s portable enough to use whether you’re in the server room or the equipment closet.

The guide summarizes all CCNA certification-level Cisco IOS Software commands, keywords, command arguments, and associated prompts, providing you with tips and examples of how to apply the commands to real-world scenarios. Throughout, configuration examples give you a better understanding of how these commands are used in simple network designs.

This book has been completely updated to cover all topics in the new ICND1 100-105, ICND2 200-105, and CCNA 200-125 exams. Use this quick reference resource to help you memorize commands and concepts as you work to pass the CCNA Routing and Switching certification exam. Coverage includes

Network Fundamentals: Subnetting, VLSM, route summarization, cables/connections, CLI

LAN Switching: Switch configuration, VLANs, VLAN trunking protocol, inter-VLAN communication, STP, EtherChannel

Routing (IPv4/IPv6): Router configuration, static routing, RIPng, EIGRP/EIGRPv6, OSPFv2/OSPFv3

WAN: Point-to-point protocols, eBGP, GRE tunnels, QoS

Infrastructure Services: DHCP, FHRP, HSRP, NAT

Infrastructure Security: Switch port security, ACL traffic management, device hardening

Infrastructure Management: Backup/restore, password recovery, CDP, LLDP, IOS tools, device monitoring, IOS licensing, troubleshooting

Quick, offline access to all CCNA Routing and Switching commands for research and solutions

--Logical how-to topic groupings for a one-stop resource

--Great for review before CCNA Routing and Switching certification exams

--Compact size makes it easy to carry with you wherever you go

--“Create Your Own Journal” section with blank, lined pages enables you to personalize the book for your needs

--“What Do You Want to Do?” chart inside the back cover helps you to quickly reference specific tasks

This book is part of the Cisco Press Certification Self-Study Product Family, which offers readers a self-paced study routine for Cisco® certification exams. Titles in the Cisco Press Certification Self-Study Product Family are part of a recommended learning program from Cisco that includes simulation and hands-on training from authorized Cisco Learning Partners and self-study products from Cisco Press.

Table of Contents

  1. About This E-Book
  2. Title Page
  3. Copyright Page
  4. Contents at a Glance
  5. Contents
  6. About the Author
  7. About the Technical Reviewer
  8. Dedications
  9. Acknowledgments
  10. Reader Services
  11. Command Syntax Conventions
  12. Introduction
    1. Networking Devices Used in the Preparation of This Book
    2. Private Addressing Used in This Book
    3. Who Should Read This Book
    4. Optional Sections
    5. Organization of This Book
    6. Did I Miss Anything?
  13. Part I: Network Fundamentals
    1. Chapter 1. How to Subnet
      1. Class A–E Addresses
      2. Converting Between Decimal Numbers and Binary
      3. Subnetting a Class C Network Using Binary
      4. Subnetting a Class B Network Using Binary
      5. Binary ANDing
        1. So Why AND?
        2. Shortcuts in Binary ANDing
      6. The Enhanced Bob Maneuver for Subnetting (or How to Subnet Anything in Under a Minute)
    2. Chapter 2. VLSM
      1. IP Subnet Zero
      2. VLSM Example
        1. Step 1: Determine How Many H Bits Will Be Needed to Satisfy the Largest Network
        2. Step 2: Pick a Subnet for the Largest Network to Use
        3. Step 3: Pick the Next Largest Network to Work With
        4. Step 4: Pick the Third Largest Network to Work With
        5. Step 5: Determine Network Numbers for Serial Links
    3. Chapter 3. Route Summarization
      1. Example for Understanding Route Summarization
        1. Step 1: Summarize Winnipeg’s Routes
        2. Step 2: Summarize Calgary’s Routes
        3. Step 3: Summarize Edmonton’s Routes
        4. Step 4: Summarize Vancouver’s Routes
      2. Route Summarization and Route Flapping
      3. Requirements for Route Summarization
    4. Chapter 4. Cables and Connections
      1. Connecting a Rollover Cable to Your Router or Switch
      2. Using a USB Cable to Connect to Your Router or Switch
      3. Terminal Settings
      4. LAN Connections
      5. Serial Cable Types
      6. Which Cable to Use?
      7. 568A Versus 568B Cables
    5. Chapter 5. The Command-Line Interface
      1. Shortcuts for Entering Commands
      2. Using the Key to Complete Commands
      3. Console Error Messages
      4. Using the Question Mark for Help
      5. enable Command
      6. exit Command
      7. disable Command
      8. logout Command
      9. Setup Mode
      10. Keyboard Help
      11. History Commands
      12. terminal Commands
      13. show Commands
      14. Using the Pipe Parameter (|) with the show Command
  14. Part II: LAN Switching Technologies
    1. Chapter 6. Configuring a Switch
      1. Help Commands
      2. Command Modes
      3. Verifying Commands
      4. Resetting Switch Configuration
      5. Setting Host Names
      6. Setting Passwords
      7. Setting IP Addresses and Default Gateways
      8. Setting Interface Descriptions
      9. The mdix auto Command
      10. Setting Duplex Operation
      11. Setting Operation Speed
      12. Managing the MAC Address Table
      13. Configuration Example
    2. Chapter 7. VLANs
      1. Creating Static VLANs
        1. Using VLAN Configuration Mode
        2. Using VLAN Database Mode
      2. Assigning Ports to VLANs
      3. Using the range Command
      4. Configuring a Voice VLAN
        1. Configuring Voice and Data with Trust
        2. Configuring Voice and Data Without Trust
      5. Verifying VLAN Information
      6. Saving VLAN Configurations
      7. Erasing VLAN Configurations
      8. Configuration Example: VLANs
        1. 2960 Switch
    3. Chapter 8. VLAN Trunking Protocol and Inter-VLAN Communication
      1. Dynamic Trunking Protocol (DTP)
      2. Setting the VLAN Encapsulation Type
      3. VLAN Trunking Protocol (VTP)
      4. Verifying VTP
      5. Inter-VLAN Communication Using an External Router: Router-on-a-Stick
      6. Inter-VLAN Communication on a Multilayer Switch Through a Switch Virtual Interface
        1. Remove L2 Switchport Capability of an Interface on an L3 Switch
        2. Configuring Inter-VLAN Communication on an L3 Switch
      7. Inter-VLAN Communication Tips
      8. Configuration Example: Inter-VLAN Communication
        1. ISP Router
        2. CORP Router
        3. L2Switch2 (Catalyst 2960)
        4. L3Switch1 (Catalyst 3560)
        5. L2Switch1 (Catalyst 2960)
    4. Chapter 9. Spanning Tree Protocol
      1. Spanning Tree Protocol Definition
      2. Enabling Spanning Tree Protocol
      3. Configuring the Root Switch
      4. Configuring a Secondary Root Switch
      5. Configuring Port Priority
      6. Configuring the Path Cost
      7. Configuring the Switch Priority of a VLAN
      8. Configuring STP Timers
      9. Verifying STP
      10. Cisco STP Toolkit
        1. PortFast
        2. BPDU Guard
      11. Changing the Spanning-Tree Mode
      12. Extended System ID
      13. Enabling Rapid Spanning Tree
      14. Troubleshooting Spanning Tree
      15. Configuration Example: PVST+
        1. Core Switch (3560)
        2. Distribution 1 Switch (3560)
        3. Distribution 2 Switch (3560)
        4. Access 1 Switch (2960)
        5. Access 2 Switch (2960)
      16. Spanning-Tree Migration Example: PVST+ to Rapid-PVST+
        1. Access 1 Switch (2960)
        2. Access 2 Switch (2960)
        3. Distribution 1 Switch (3560)
        4. Distribution 2 Switch (3560)
        5. Core Switch (3560)
    5. Chapter 10. EtherChannel
      1. EtherChannel
        1. Interface Modes in EtherChannel
        2. Guidelines for Configuring EtherChannel
        3. Configuring Layer 2 EtherChannel
        4. Configuring L3 EtherChannel
        5. Verifying EtherChannel
      2. Configuration Example: EtherChannel
        1. DLSwitch (3560)
        2. ALSwitch1 (2960)
        3. ALSwitch2 (2960)
  15. Part III: Routing Technologies: IPv4 and IPv6
    1. Chapter 11. Configuring a Cisco Router
      1. Router Modes
      2. Entering Global Configuration Mode
      3. Configuring a Router Name
      4. Configuring Passwords
      5. Password Encryption
      6. Interface Names
      7. Moving Between Interfaces
      8. Configuring a Serial Interface
      9. Configuring a Fast Ethernet Interface
      10. Configuring a Gigabit Ethernet Interface
      11. Assigning IPv6 Addresses to Interfaces
      12. Creating a Message-of-the-Day Banner
      13. Creating a Login Banner
      14. Setting the Clock Time Zone
      15. Mapping a Local Hostname to a Remote IP Address
      16. The no ip domain-lookup Command
      17. The logging synchronous Command
      18. The exec-timeout Command
      19. Saving Configurations
      20. Erasing Configurations
      21. show Commands
      22. EXEC Commands in Configuration Mode: The do Command
      23. Configuration Example: Basic Router Configuration
        1. Boston Router
    2. Chapter 12. Static Routing
      1. Configuring an IPv4 Static Route on a Router
      2. Static Routes and Recursive Lookups
      3. The permanent Keyword (Optional)
      4. Floating Static Routes and Administrative Distance (Optional)
      5. Configuring an IPv4 Default Route on a Router
      6. Verifying IPv4 Static Routes
      7. Configuration Example: IPv4 Static Routes
        1. Boston Router
        2. Buffalo Router
        3. Bangor Router
      8. Static Routes in IPv6
      9. Floating Static Routes in IPv6
      10. Default Routes in IPv6
      11. Verifying and Troubleshooting IPv6
    3. Chapter 13. RIP Next Generation (RIPng)
      1. Implementing RIP Next Generation
      2. Verifying and Troubleshooting RIPng
      3. Configuration Example: RIPng
        1. Austin Router
        2. Houston Router
    4. Chapter 14. EIGRP and EIGRPv6
      1. Configuring Enhanced Interior Gateway Routing Protocol (EIGRP) for IPv4
        1. Adjusting the EIGRP for IPv4 Metric Weights
        2. Adjusting the EIGRPv6 Metric Weights
        3. Configuring EIGRPv6 on an Interface
      2. EIGRP Router ID
      3. EIGRP Timers
      4. EIGRP Auto-Summarization for IPv4
      5. EIGRP Manual Summarization for IPv4
        1. EIGRPv6 Summary Addresses
      6. Passive EIGRP Interfaces
      7. Equal-Cost Load Balancing: Maximum Paths
      8. Unequal-Cost Load Balancing: Variance
      9. Bandwidth Use
      10. Verifying EIGRP and EIGRPv6
      11. Troubleshooting EIGRP and EIGRPv6
      12. Configuration Example: EIGRP
        1. Austin Router
        2. Houston Router
      13. Configuration Example: EIGRPv6
        1. R3 Router
        2. R2 Router
        3. R1 Router
    5. Chapter 15. OSPFv2 and OSPFv3
      1. OSPFv2 Versus OSPFv3
      2. Configuring OSPF
      3. Using Wildcard Masks with OSPF Areas
      4. Configuring Multiarea OSPF
      5. Multiarea OSPF Router Types
      6. Loopback Interfaces
      7. Router ID
      8. DR/BDR Elections
      9. Passive Interfaces
      10. Modifying Cost Metrics
      11. OSPF auto-cost reference-bandwidth
      12. Timers
      13. Propagating a Default Route
      14. Route Summarization
        1. Interarea Route Summarization
        2. External Route Summarization
      15. IPv6 and OSPFv3
        1. Enabling OSPF for IPv6 on an Interface
        2. Interarea OSPFv3 Route Summarization
        3. Enabling an IPv4 Router ID for OSPFv3
      16. Verifying OSPFv2 and OSPFv3 Configurations
      17. Troubleshooting OSPFv2 and OSPFv3
      18. Configuration Example: Single-Area OSPF
        1. Austin Router
        2. Houston Router
        3. Galveston Router
      19. Configuration Example: Multiarea OSPF
        1. ASBR Router
        2. ABR-1 Router
        3. ABR-2 Router
        4. Internal Router
      20. Configuration Example: IPv6 and OSPFv3
        1. R3 Router
        2. R2 Router
        3. R1 Router
        4. R4 Router
  16. Part IV: WAN Technologies
    1. Chapter 16. Understanding Point-to-Point Protocols
      1. Configuring High-Level Data Link Control Encapsulation on a Serial Line
      2. Configuring Point-to-Point Protocol (PPP) on a Serial Line (Mandatory Commands)
      3. Configuring PPP on a Serial Line (Optional Commands): Compression
      4. Configuring PPP on a Serial Line (Optional Commands): Link Quality Monitoring
      5. Configuring PPP on a Serial Line (Optional Commands): Authentication
      6. Verifying and Troubleshooting a Serial Link/PPP Encapsulation
      7. Configuration Example: PPP with CHAP Authentication
        1. Boston Router
        2. Buffalo Router
      8. Configuring Multilink Point-to-Point Protocol
        1. Branch Router
        2. HQ Router
      9. Verifying and Troubleshooting MLPPP
      10. Configuring a DSL Connection Using Point-to-Point Protocol over Ethernet
        1. Step 1: Configure PPPoE (External Modem)
        2. Step 2: Configure the Dialer Interface
        3. Step 3: Define Interesting Traffic and Specify Default Routing
        4. Step 4: Configure NAT (Choose 1 Method Only)
        5. Step 4a: Configure NAT Using an ACL
        6. Step 4b: Configure NAT Using a Route Map
        7. Step 5: Configure DHCP Service
        8. Step 6: Apply NAT Programming
        9. Step 7: Verify a PPPoE Connection
    2. Chapter 17. External Border Gateway Protocol (eBGP)
      1. Configuring Border Gateway Protocol
      2. BGP and Loopback Addresses
      3. Configuration Example: eBGP
      4. eBGP Multihop
      5. Verifying BGP Connections
      6. Troubleshooting BGP Connections
    3. Chapter 18. Configuring Generic Routing Encapsulation (GRE) Tunnels
      1. Configuring a GRE Tunnel
        1. Branch Router
        2. HQ Router
      2. Verifying a GRE Tunnel
    4. Chapter 19. Quality of Service (QoS)
      1. High Availability for Voice and Video
      2. Configuring Basic QoS
      3. Verifying Basic QoS
      4. Auto-QoS
        1. Restrictions for Auto-QoS
        2. Configuring Auto-QoS: 2960-X/3650/3750
        3. Verifying Auto QoS: 2960-X/3650/3750
        4. Configuring Auto-QoS: 6500
        5. Verifying Auto-QoS Information: 6500
  17. Part V: Infrastructure Services
    1. Chapter 20. DHCP
      1. Configuring a DHCP Server on an IOS Router
      2. Using Cisco IP Phones with a DHCP Server
      3. Verifying and Troubleshooting DHCP Configuration
      4. Configuring a DHCP Helper Address
      5. DHCP Client on a Cisco IOS Software Ethernet Interface
      6. Configuration Example: DHCP
        1. Edmonton Router
        2. Gibbons Router
    2. Chapter 21. First Hop Redundancy Protocols (FHRP): Hot Standby Router Protocol (HSRP)
      1. First Hop Redundancy
      2. HSRP
      3. Configuring HSRP on a Router
      4. Default HSRP Configuration Settings
      5. Verifying HSRP
      6. HSRP Optimization Options
        1. Preempt
        2. HSRP Message Timers
        3. Interface Tracking
      7. Debugging HSRP
      8. Configuration Example: HSRP
        1. Router 1
        2. Router 2
    3. Chapter 22. Network Address Translation (NAT)
      1. Private IP Addresses: RFC 1918
      2. Configuring Dynamic Network Address Translation: One Private to One Public Address Translation
      3. Configuring PAT: Many Private to One Public Address Translation
      4. Configuring Static NAT: One Private to One Permanent Public Address Translation
      5. Verifying NAT and PAT Configurations
      6. Troubleshooting NAT and PAT Configurations
      7. Configuration Example: PAT
        1. ISP Router
        2. Company Router
  18. Part VI: Infrastructure Security
    1. Chapter 23. Switch Port Security
      1. Setting Passwords on a Switch
      2. Configuring Static MAC Addresses
      3. Switch Port Security
      4. Verifying Switch Port Security
      5. Sticky MAC Addresses
      6. Recovering Automatically from Error-Disabled Ports
      7. Verifying Autorecovery of Error-Disabled Ports
      8. Configuration Example
    2. Chapter 24. Managing Traffic Using Access Control Lists (ACL)
      1. Access List Numbers
      2. Using Wildcard Masks
      3. ACL Keywords
      4. Creating Standard ACLs
      5. Applying Standard ACLs to an Interface
      6. Verifying ACLs
      7. Removing ACLs
      8. Creating Extended ACLs
      9. Applying Extended ACLs to an Interface
      10. The established Keyword
      11. The log Keyword
      12. Creating Named ACLs
      13. Using Sequence Numbers in Named ACLs
      14. Removing Specific Lines in Named ACLs Using Sequence Numbers
      15. Sequence Number Tips
      16. Including Comments About Entries in ACLs
      17. Restricting Virtual Terminal Access
      18. Tips for Configuring ACLs
      19. IPv6 ACLs
      20. Verifying IPv6 ACLs
      21. Configuration Examples: IPv4 ACLs
      22. Configuration Examples: IPv6 ACLs
    3. Chapter 25. Device Hardening
      1. Securing Cisco Device According to Recommended Practices
      2. Securing Cisco IOS Routers Checklist
      3. Components of a Router Security Policy
      4. Configuring Passwords
      5. Password Encryption
      6. Configuring SSH
      7. Verifying SSH
      8. Restricting Virtual Terminal Access
      9. Disabling Unneeded Services
  19. Part VII: Infrastructure Management
    1. Chapter 26. Backing Up and Restoring Cisco IOS Software and Configurations
      1. Boot System Commands
      2. The Cisco IOS File System
      3. Viewing the Cisco IOS File System
      4. Commonly Used URL Prefixes for Cisco Network Devices
      5. Deciphering IOS Image Filenames
      6. Backing Up Configurations to a TFTP Server
      7. Restoring Configurations from a TFTP Server
      8. Backing Up the Cisco IOS Software to a TFTP Server
      9. Restoring/Upgrading the Cisco IOS Software from a TFTP Server
      10. Restoring the Cisco IOS Software from ROM Monitor Mode Using Xmodem
      11. Restoring the Cisco IOS Software Using the ROM Monitor Environmental Variables and tftpdnld Command
      12. Secure Copy
      13. Configuring a Secure Copy Server
      14. Verifying and Troubleshooting Secure Copy
      15. Configuration Example: Using Secure Copy
    2. Chapter 27. Password Recovery Procedures and the Configuration Register
      1. The Configuration Register
      2. A Visual Representation of the Configuration Register
      3. What the Bits Mean
      4. The Boot Field
      5. Console Terminal Baud Rate Settings
      6. Changing the Console Line Speed: CLI
      7. Changing the Console Line Speed: ROM Monitor Mode
      8. Password-Recovery Procedures for Cisco Routers
      9. Password Recovery for 2960 Series Switches
    3. Chapter 28. Cisco Discovery Protocol (CDP) and Link Layer Discovery Protocol (LLDP)
      1. Cisco Discovery Protocol
      2. Configuring CDP
      3. Verifying and Troubleshooting CDP
      4. CDP Design Tips
      5. Link Layer Discovery Protocol (802.1AB)
      6. Configuring LLDP (802.1AB)
      7. Verifying and Troubleshooting LLDP
    4. Chapter 29. IOS Tools
      1. Configuring a Device to Accept a Remote Telnet Connection
      2. Using Telnet to Remotely Connect to Other Devices
      3. Verifying Telnet
      4. Internet Control Message Protocol Redirect Messages
      5. The ping Command
      6. Examples of Using the ping and the Extended ping Commands
      7. The traceroute Command
    5. Chapter 30. Device Monitoring
      1. Device Monitoring
      2. Simple Network Management Protocol
      3. Configuring SNMP
      4. Securing SNMPv1 or SNMPv2
      5. Securing SNMPv3
      6. Verifying SNMP
      7. Configuration Backups
      8. Implementing Logging
      9. Configuring Syslog
      10. Syslog Message Format
      11. Syslog Severity Levels
      12. Syslog Message Example
      13. Configuring NetFlow
      14. Verifying NetFlow
      15. Network Time Protocol
      16. Network Time Protocol Configuration
      17. Verifying NTP
      18. Setting the Clock on a Router
      19. Using Time Stamps
    6. Chapter 31. Cisco IOS Licensing
      1. Cisco Licensing Earlier Than IOS 15.0
      2. Cisco Licensing for the ISR G2 Platforms: IOS 15.0 and Later
      3. Verifying Licenses
      4. Cisco License Manager
      5. Cisco Smart Software Manager
      6. Installing a Permanent License
      7. Installing an Evaluation License
      8. Backing Up a License
      9. Uninstalling a License
    7. Chapter 32. Basic Troubleshooting
      1. Viewing the Routing Table
      2. Clearing the Routing Table
      3. Determining the Gateway of Last Resort
      4. Determining the Last Routing Update
      5. OSI Layer 3 Testing
      6. OSI Layer 7 Testing
      7. Interpreting the show interface Command
      8. Clearing Interface Counters
      9. Using CDP to Troubleshoot
      10. The traceroute Command
      11. The show controllers Command
      12. debug Commands
      13. Using Time Stamps
      14. Operating System IP Verification Commands
      15. The ip http server Command
      16. The netstat Command
      17. The arp Command
  20. Part VIII: Appendixes
    1. Appendix A. Binary/Hex/Decimal Conversion Chart
    2. Appendix B. Create Your Own Journal Here
  21. Index
  22. Inside Front Cover
  23. Inside Back Cover
  24. What Do You Want to Do Today?
  25. Code Snippets