Basic and Essential Cisco IOS Commands for Device Management

This article provides a complete and practical guide to the most important basic Cisco IOS commands. It covers switching between different modes (enable, disable, exit, configure terminal), setting hostname, entering interface mode, viewing IP information, displaying and managing configurations (running-config and startup-config), as well as commands for saving and erasing configuration. Each command is explained with clear descriptions and practical examples.

Cisco IOS Basic Commandsenable conf tshow running-config

~3 دقیقه مطالعه · آخرین به‌روزرسانی ۱۹ فروردین ۱۴۰۵

Introduction

Learning the basic Cisco IOS commands is the first and most important step when working with Cisco routers and switches. These commands allow you to move between different device modes, perform configurations, check the device status, and save or erase changes.

Mode Switching Commands

1. enable

Moves from User EXEC mode to Privileged EXEC mode and grants access to advanced commands.

Router> enable
Router#

2. disable

Returns from Privileged EXEC mode back to User EXEC mode.

Router# disable
Router>

3. exit

Moves up one level from the current mode (for example, from Interface mode to Global Configuration or from Global Configuration to Privileged EXEC).

Router(config-if)# exit
Router(config)#

4. conf or configure terminal

Enters Global Configuration mode to make changes that affect the entire device.

Router# configure terminal
Router(config)#

You can also use the short form: conf t

Hostname and Interface Commands

5. hostname

Changes the name of the device.

Router(config)# hostname R1
R1(config)#

6. interface gi (or interface GigabitEthernet)

Enters the configuration mode for a specific interface.

R1(config)# interface GigabitEthernet0/0
R1(config-if)#

Common short form: int gi0/0

Show Commands

7. show ip interface brief

Displays a summary of all interfaces with their IP addresses and status.

R1# show ip interface brief

8. show ip interface

Shows detailed information about a specific interface or all interfaces (status, IP address, subnet mask, etc.).

R1# show ip interface GigabitEthernet0/0

9. show running-config

Displays the current configuration stored in RAM (running-config).

R1# show running-config

10. show startup-config

Displays the saved configuration in NVRAM that will be loaded on the next boot.

R1# show startup-config

Saving and Erasing Configuration

Saving the Configuration

To make sure your changes survive a reboot, you must copy the running-config to startup-config.

R1# copy running-config startup-config
or
R1# write memory
or short form:
R1# wr

Erasing the Configuration

To completely delete the saved configuration:

R1# erase startup-config
or
R1# write erase

After this command, you usually reload the device to return it to factory default settings.

Complete Example: Basic Router Configuration

Router> enable
Router# configure terminal
Router(config)# hostname R1
R1(config)# interface GigabitEthernet0/0
R1(config-if)# ip address 192.168.1.1 255.255.255.0
R1(config-if)# no shutdown
R1(config-if)# exit
R1(config)# exit
R1# show running-config
R1# copy running-config startup-config
R1# show startup-config

Important Tips

  • Always run copy running-config startup-config before powering off the device.
  • show ip interface brief is the fastest way to check the status of all interfaces.
  • Use the exit command to move up one level at a time.
  • You can quickly exit any mode by typing end or pressing Ctrl + Z.

Conclusion

These basic commands are the fundamental tools for working with Cisco IOS. With regular practice, you will quickly become comfortable in the Cisco CLI and be able to configure, monitor, and troubleshoot devices efficiently.

نوشته و پژوهش‌شده توسط دکتر شاهین صیامی

مقالات مرتبط

Systematic Network Troubleshooting: A Methodology Tying Everything Together

Every protocol and technology covered throughout this series is only useful if a problem involving it can actually be diagnosed and fixed efficiently under real-world pressure. This article presents a systematic troubleshooting methodology built around the OSI layers, walks through applying it to a realistic connectivity problem, and shows how the specific verification commands covered throughout this entire series fit into a structured diagnostic process.

ادامه

NETCONF, YANG, and Python: Programmatic Network Configuration at Scale

The REST APIs and JSON/YAML formats covered earlier in this series represent one approach to network automation, but NETCONF and YANG provide a more structured, standards-based alternative purpose-built for network device configuration. This article explains what distinguishes NETCONF from a simple REST API, covers how YANG models define exactly what configuration data looks like, and walks through using Python to programmatically interact with network devices.

ادامه

IPsec VPN Fundamentals: Securing Traffic Across Untrusted Networks

Connecting two sites across the public internet exposes traffic to interception unless it is properly encrypted, and IPsec provides the standard framework for building secure, authenticated tunnels between sites. This article explains the two-phase IKE negotiation process, covers the distinction between AH and ESP protocols, walks through configuring a basic site-to-site IPsec VPN, and covers essential verification commands.

ادامه

MPLS Fundamentals: Label Switching Explained

Traditional IP routing requires every router along a path to perform a full routing table lookup on every packet, but MPLS takes a fundamentally different approach by making that forwarding decision once and attaching a simple label that every subsequent router can use instead. This article explains the core label-switching concept, walks through how the Label Distribution Protocol builds the label forwarding tables that make this possible, and covers the practical benefits MPLS provides in real provider networks.

ادامه

BGP Route Reflectors and Confederations: Scaling iBGP Beyond Full Mesh

The iBGP full-mesh requirement, briefly mentioned earlier in this series, becomes a serious scaling problem as an autonomous system grows, requiring a number of sessions that increases quadratically with router count. This article explains exactly why full mesh does not scale, walks through how route reflectors solve this by relaxing BGP's normal route-propagation rules, and covers confederations as an alternative approach that divides a single AS into smaller sub-autonomous systems.

ادامه

OSPF Area Types Deep Dive: Stub, Totally Stubby, and NSSA

Multi-area OSPF, covered earlier in this series, already reduces database size by separating a network into areas, but OSPF offers further specialized area types that reduce routing table size even more aggressively by filtering out unnecessary external routes entirely. This article explains the LSA types that must be suppressed to create each specialized area type, walks through configuring stub, totally stubby, and not-so-stubby areas, and covers the specific trade-offs each design choice involves.

ادامه