Managing Configuration Files

The process of managing configuration files is straightforward; however, it is increasingly difficult because of the different versions of Cisco software and the wide variety of architectures used in Cisco hardware. This section will bring light to these subjects; present an overview of the different types of configuration files and the commands used to move, display, and copy these files; and, finally, highlight some of the areas that can cause confusion when managing configuration files.

Types of Configuration Files

Cisco IOS software uses and requires a configuration file to determine how a router is to function. Typically, network administrators enter the commands necessary for their environment into a router configuration file. Only two types of configuration files exist for the context of the CCNA exam:

  • The running configuration file exists in RAM and contains the commands that Cisco IOS uses to drive the actions of the router.

    graphics/note_icon.gif

    RAM is erased during power cycles or software reloads . Therefore, the running configuration file is erased as well. Startup configuration files, which provide a backup for the running configuration files, reside in NVRAM and are not erased with a power down.


  • The startup configuration file exists in NVRAM and is the backup for the running configuration file.

The router will always use the running configuration file to execute. However, any time a router is restarted (cycling power or reloading the software), the running configuration file is erased and the startup configuration file is the only remaining configuration file. During the boot sequence of a router, the router copies the startup configuration file to the running configuration file (NVRAM to RAM). Therefore, it is paramount that any time a change is made to a running configuration, the change is also copied to the startup configuration. The many ways of preventing the loss of changes made are discussed in this chapter.

Displaying the Running and Startup Configuration Files

The purpose of displaying a running or startup configuration file is to determine the configuration commands being executed on a router. Use the show running-config and show startup-config commands to show the running configuration and startup configuration files, respectively. Displaying the running configuration file shows the commands being executed at the time that the show command is executed, as shown here:

 
 Router#show running-config Building configuration... Current configuration: Last configuration change at 03:25:38 UTC Sat Jan 1 2000 version 11.2 no service password-encryption no service udp-small-servers no service tcp-small-servers hostname Router enable secret 5 uUPI.L0xxD3wnX.7WDMHzb60 enable password cisco no ip domain-lookup interface Serial0  ip address 138.144.2.2 255.255.255.0  encapsulation frame-relay  bandwidth 2000  frame-relay lmi-type cisco interface Serial1  no ip address  shutdown ! interface TokenRing0  ip address 138.144.3.1 255.255.255.0  ring-speed 16 ! interface TokenRing1  ip address 138.144.4.1 255.255.255.0  ring-speed 16 ! router igrp 1  network 138.144.0.0 ! no ip classless ! snmp-server community public RO ! line con 0 line aux 0 line vty 0 4 password cisco login ! end 
graphics/note_icon.gif

The Router# prompt indicates that the command is initiated from the EXEC privileged ( enable ) command line. It is important to know in what mode a command should be executed.


Configuring the Running and Startup Configuration Files

The running configuration file often requires changes while the router is functioning. Cisco IOS is designed to accept changes to a running or startup configuration file without restarting (reloading) or cycling the power of the router. The following commands are used to manipulate the configuration files:

  • Router# configure terminal ” Allows a user to add, change, or delete commands in the running configuration file while the router is executing.

  • Router# configure memory ” Allows a user to add, change, or delete commands in the startup configuration file.

graphics/alert_icon.gif

Making changes to the running configuration file will immediately affect the behavior of a router.


Backing Up and Restoring Configuration Files

Configuration files are copied and moved constantly in most networks. One common method of copying files is with the use of a Trivial File Transfer Protocol (TFTP) server. Most Unix machines have built-in TFTP support. Also, TFTP server programs are available for Windows-based PCs. Cisco makes a TFTP server program that is available to registered users on its Web site at the following Web address: www.cisco.com/pcgi-bin/tablebuild.pl/tftp. Cisco routers use a TFTP server to load IOS and to copy software and configuration files. To copy a file using TFTP, one device needs to be executing TFTP server software and the other device needs to be executing the client software. Cisco routers are equipped with both functions. Network administrators often need to back up a running or startup configuration file on a central server. The following command sequence accomplishes this goal:

 
 Router# copy running-config TFTP Remote host []? 172.15.10.2 (IP Address of TFTP Server) Name of configuration file to write [router-confg]? <Return> Write file Router-confg on host 172.15.10.2? [confirm]  <  Return  >  Building configuration... Writing Router-confg !!!!!!!!!!!!!!!!![OK] 
graphics/alert_icon.gif

Pay attention to the order and syntax of commands during the test. The function of a command can completely change, depending on the syntax. Also be aware that Cisco networking devices accept the short form of commands, for example config t instead of configure terminal . We use the long forms exclusively in this book because they are easier to remember.


The reverse process occurs when a configuration file is copied from a central server to an executing router. This process is most often used when a router has gone dead or someone has accidentally deleted the configuration file on the router. If the running configuration was backed up on a TFTP server, it is really simple to restore the configuration file. The first step for restoring the configuration file on a router is to determine Internet Protocol (IP) connectivity from the central server to the router. This might require the use of a ping test and/or the configuration of an IP address on the router. The following command sequence is used for restoring a running configuration file:

 
 Router# copy TFTP running-config Host or network configuration file [host]?  <  Return  >  Address of remote host [255.255.255.255]? 172.15.10.2 (TFTP Server) Name of configuration file [Router-confg]?Router-confg  - (File name) Configure using Router-confg from 172.15.10.2? [confirm]  <  Return  >  Loading Router-confg from 172.15.10.2 (via serial 1): !!!!! [OK - 875/32723] Router# 
graphics/note_icon.gif

Exercise caution when performing configuration file changes across networks, especially to remote sites. Visit the Cisco Web site (www.cisco.com) and utilize the search engine to identify anything you might need to be aware of while performing configuration file backups or restores in your network. Always be sure to find hardware-specific features before changing configuration files or Cisco IOS software.


Another method of backing up a running configuration is to save it to NVRAM. You should complete this process after every change to the running configuration file, unless a good reason exists to keep the startup configuration different. By copying the running configuration to NVRAM, you are ensuring that if the router is reloaded or the power is cycled, it will boot with the same configuration you are currently executing. The following command sequence is required for this process:

 
 Router#copy running-config startup-config Building configuration... [OK] 

The startup configuration file can also be copied into RAM, thereby overwriting the running configuration file, by performing the following command:

 
 Router# Copy startup-config running-config 
graphics/alert_icon.gif

It is necessary to know all the backup and restore commands for the CCNA exam. Be sure to pay special attention to the syntax of these commands. It is easy to forget the sequence of words for the different commands.


Finally, the startup configuration file can be completely erased. When this occurs, the router boots into setup mode the next time it is reloaded:

 
 Router#erase startup-config 


CCNA Exam Cram[tm] 2 (Exams 640-821, 640-811, 640-801)
CCNA Exam Cram[tm] 2 (Exams 640-821, 640-811, 640-801)
ISBN: 789730197
EAN: N/A
Year: 2005
Pages: 155

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net