To copy any file from a source to a destination, use the copy command in the EXEC mode. The copy command in the Cisco CDA copies a configuration (running or startup).
The Cisco CDA active configuration stores itself in the Cisco CDA RAM. Every configuration command you enter resides in the running configuration. If you reboot your Cisco CDA server, you lose the running configuration. If you make changes that you want to save, you must copy the running configuration to a safe location, such as a network server, or save it as the Cisco CDA server startup configuration.
You cannot edit a startup configuration directly. All commands that you enter store themselves in the running configuration, which you can copy into the startup configuration.
In other words, when you boot a Cisco CDA server, the startup configuration becomes the initial running configuration. As you modify the configuration, the two diverge: the startup configuration remains the same; the running configuration reflects the changes that you have made. If you want to make your changes permanent, you must copy the running configuration to the startup configuration.
The following command lines show some of the copy command scenarios available:
copy running-config startup-config—Copies the running configuration to the startup configuration.
copy run start—Replaces the startup configuration with the running configuration.
Note If you do not save the running configuration, you will lose all your configuration changes during the next reboot of the Cisco CDA server. When you are satisfied that the current configuration is correct, copy your configuration to the startup configuration with the copy run start command.
copy startup-config running-config—Copies the startup configuration to the running configuration.
copy start run—Merges the startup configuration on top of the running configuration.
copy [protocol://hostname/location] startup-config—Copies but does not merge a remote file to the startup configuration.
copy [protocol://hostname/location] running-config—Copies and merges a remote file to the running configuration.
copy startup-config [protocol://hostname/location]—Copies the startup configuration to a remote system.
copy running-config [protocol://hostname/location]—Copies the running configuration to a remote system.
copy logs [protocol://hostname/location]—Copies log files from the system to another location.
Note The copy command is supported only for the local disk and not for a repository.
Represents the configuration file used during initialization (startup). |
|
See Table 4-2 for protocol keyword options. |
|
Copies all Cisco CDA log files from the system to another location. All logs are packaged as cdalogs.tar.gz and transferred to the specified directory on the remote host. |
|
Allows you to copy a single Cisco CDA log file and transfer it to the specified directory on the remote host, with its original name. |
|
Name of the Cisco CDA log file, as displayed by the show logs command (up to 255 characters). |
|
Copies the Cisco CDA management debug logs and Tomcat logs from the system, bundles them as mgmtlogs.tar.gz, and transfers them to the specified directory on the remote host. |
|
Copies the Cisco CDA runtime debug logs from the system, bundles them as runtimelogs.tar.gz, and transfers them to the specified directory on the remote host. |
No default behavior or values.
The fundamental function of the copy command allows you to copy a file (such as a system image or configuration file) from one location to another location. The source and destination for the file specified uses the Cisco CDA file system, through which you can specify any supported local or remote file location. The file system being used (a local memory source or a remote system) dictates the syntax used in the command.
You can enter on the command line all the necessary source and destination information and the username and password to use; or, you can enter the copy command and have the server prompt you for any missing information.
Timesaver Aliases reduce the amount of typing that you need to do. For example, type copy run start (the abbreviated form of the copy running-config startup-config command).
The entire copying process might take several minutes and differs from protocol to protocol and from network to network.
Use the filename relative to the directory for file transfers.
Possible errors are standard FTP or SCP error messages.
/admin# copy running-config
startup-config
/admin# copy startup-config
running-config
/admin# copy disk://mybackup-100805-1910.tar.gz
ftp://myftpserver/mydir