cisco IOS — Copying a Configuration File from the Device to a TFTP Server

Examples In the following example, the device prompt name of the device is configured. The comment line, indicated by the exclamation mark (!), does not execute any command. The hostname command is used to change the device name from device to new_name. By pressing Ctrl-Z (^Z) or entering the end command, the user quits configuration mode. The copy system:running-config nvram:startup-config command saves the current configuration to the startup configuration. Device# configure terminal Device(config)# !The following command provides the switch host name.

Device(config)# hostname new_name new_name(config)# end new_name# copy system:running-config nvram:startup-config When the startup configuration is NVRAM, it stores the current configuration information in text format as configuration commands, recording only non-default settings. The memory is checksummed to guard against corrupted data. Note Some specific commands might not get saved to NVRAM. You need to enter these commands again if you reboot the machine. These commands are noted in the documentation. We recommend that you keep a list of these settings so that you can quickly reconfigure your device after rebooting.

Copying a Configuration File from the Device to a TFTP Server To copy configuration information on a TFTP network server, complete the tasks in this section: Managing Configuration Files Copying a Configuration File from the Device to a TFTP Server Command or Action Purpose Example: Device(config)# end When you press the Ctrl and Z keys simultaneously, ^Z is displayed to the screen. Step 5 copy system:running-config nvram:startup-config Example: Device# copy system:running-config nvram:startup-config Saves the running configuration file as the startup configuration file.

You may also use the copy running-config startup-config command alias, but you should be aware that this command is less precise. On most platforms, this command saves the configuration to NVRAM. On the Class A Flash file system platforms, this step saves the configuration to the location specified by the CONFIG FILE environment variable (the _ default CONFIG FILE variable specifies that _ the file should be saved to NVRAM). Managing Configuration Files 10