Operating notes for multiple configuration files

Multiple configuration storage in the switch. The switch uses three memory "slots", with identity (id) numbers of 1, 2, and 3, as shown by the following output of the show config files command.

switch(config)# show config files
Configuration files:

id | act pri sec | name
---+-------------+-----------------------------------------------
 1 |             | oldConfig 
 2 |  *   *   *  | workingConfig 
 3 |             | 

A startup-config file stored in a memory slot has a unique, changeable file name. The switches covered in this guide can use the startup-config in any of the memory slots (if the software version supports the configured features). In the default configuration, if the switch was shipped from the factory with software installed in both the primary and secondary boot paths, then one startup-config file named “config1” is used for both paths and is stored in memory slot 1. Memory slots 2 and 3 are empty in this default configuration.

An asterisk ( * ) in the act, pri, or sec column has the following meaning:

  • act column: The corresponding startup-config file is currently in use.
  • pri column: The corresponding startup-config file is currently assigned to the primary boot path.
  • sec column: The corresponding startup-config file is currently assigned to the secondary boot path.

Reboot policy. With multiple startup-config files in the switch you can specify a policy for the switch to use upon reboot. The options include:

  • Use the designated startup-config file with either or both reboot paths (primary or secondary flash)

  • Override the current reboot policy for one reboot instance by specifying a boot path (primary or secondary flash) and the startup-config file to use.

For a given reboot, the switch automatically reboots from the startup-config file assigned to the flash location (primary or secondary) being used for the current reboot. For example, when you first download a software version that supports multiple configuration files and boot from the flash location of this version, the switch copies the existing startup-config file (named oldConfig) into memory slot 2, renames this file to workingConfig, and assigns workingConfig as:

  • The active configuration file

  • The configuration file to use when booting from either primary or secondary flash

In this case, the switch is configured to automatically use the workingConfig file in memory slot 2 for all reboots.

Changes to the startup-config file. When the switch reboots, the startupconfig file supplies the configuration for the running-config file the switch uses to operate. Changes to the running-config file are written back to the startup-config file that was used at the last reboot. The changes are written when the write-mem command (or, in the Menu interface, the Save command) is executed. For example, suppose that a system administrator performs the following on a switch that has two startup-config files (workingconfig and backupconfig):

  1. Reboot the switch through the Primary boot path using the startup-config file named backupconfig.

  2. Use the CLI to make configuration changes in the running-config file, and then execute write-mem.

The result is that the startup-config file used to reboot the switch is modified by the actions in step 2.

Figure 47: Reboot process and making changes to the startup-config file

An alternate startup-config file. A new configuration file can be created for an alternate startup-config file. There are two methods for creating a new configuration file:

  • Copy an existing startup-config file to a new filename, then reboot the switch, make the desired changes to the running-config file, then execute write memory.

  • Erase the active startup-config file. This generates a new, default startupconfig file that always results when the switch automatically reboots after deletion of the currently active startup-config file.

The transition to multiple configuration files. At the first reboot with a software release supporting multiple configuration, the switch:

  • Assigns the filename oldConfig to the existing startup-config file (which is stored in memory slot 1).

  • Saves a copy of the existing startup-config file in memory slot 2 with the filename workingConfig.

  • Assigns the workingConfig file as the active configuration and the default configuration for all subsequent reboots using either primary or secondary flash.

The following output of the show config files command shows the switch memory assignments after the first reboot from software that supports multiple configuration. In this state, the switch always uses the workingConfig file to reboot.


switch(config)# show config files
Configuration files:

id | act pri sec | name
---+-------------+-----------------------------------------------
 1 |             | oldConfig 
 2 |  *   *   *  | workingConfig 
 3 |             |