web analytics

Storing Switch Configuration Files

When you configure a switch, it needs to use the configuration. It also needs to be
able to retain the configuration in case the switch loses power. Cisco switches contain
random-access memory (RAM) to store data while Cisco IOS is using it, but RAM loses
its contents when the switch loses power or is reloaded. To store information that must be
retained when the switch loses power or is reloaded, Cisco switches use several types of
more permanent memory, none of which has any moving parts. By avoiding components
with moving parts (such as traditional disk drives), switches can maintain better uptime
and availability.

The following list details the four main types of memory found in Cisco switches, as well as
the most common use of each type:
■ RAM: Sometimes called DRAM, for dynamic random-access memory, RAM is used by
the switch just as it is used by any other computer: for working storage. The running
(active) configuration file is stored here.
■ Flash memory: Either a chip inside the switch or a removable memory card, flash memory
stores fully functional Cisco IOS images and is the default location where the switch
gets its Cisco IOS at boot time. Flash memory also can be used to store any other files,
including backup copies of configuration files.
■ ROM: Read-only memory (ROM) stores a bootstrap (or boothelper) program that is
loaded when the switch first powers on. This bootstrap program then finds the full Cisco
IOS image and manages the process of loading Cisco IOS into RAM, at which point
Cisco IOS takes over operation of the switch.
■ NVRAM: Nonvolatile RAM (NVRAM) stores the initial or startup configuration file that
is used when the switch is first powered on and when the switch is reloaded.

Figure 6-9 summarizes this same information in a briefer and more convenient form for
memorization and study.
Free CISCO CCNA Routing and Switching ICND1 Study Guide
Figure 6-9 Cisco Switch Memory Types

Cisco IOS stores the collection of configuration commands in a configuration file. In fact,
switches use multiple configuration files—one file for the initial configuration used when
powering on, and another configuration file for the active, currently used running configuration
as stored in RAM. Table 6-5 lists the names of these two files, their purpose, and
their storage location.

Table 6-5 Names and Purposes of the Two Main Cisco IOS Configuration Files
Free CISCO CCNA Routing and Switching ICND1 Study Guide

Essentially, when you use configuration mode, you change only the running-config file.
This means that the configuration example earlier in this chapter (Example 6-4) updates only
the running-config file. However, if the switch lost power right after that example, all that
configuration would be lost. If you want to keep that configuration, you have to copy the
running-config file into NVRAM, overwriting the old startup-config file.

Example 6-5 demonstrates that commands used in configuration mode change only the running
configuration in RAM. The example shows the following concepts and steps:
Step 1. The example begins with both the running and startup-config having the same
hostname, per the hostname hannah command.
Step 2. The hostname is changed in configuration mode using the hostname jessie
Step 3. The show running-config and show startup-config commands show the fact
that the hostnames are now different, with the hostname jessie command
found only in the running-config.

Example 6-5 How Configuration Mode Commands Change the Running-Config File,
Not the Startup-Config File
Free CISCO CCNA Routing and Switching ICND1 Study Guide
Free CISCO CCNA Routing and Switching ICND1 Study Guide

Subscribe To Get

Latest IT certification News 

Help You Pass Any IT Exam