Managing Files
You can manage the files system in USB or flash.
Copying Files
To copy a file from a source to a destination, use the copy source-url destination-url privileged EXEC command. For the source and destination URLs, you can use running-config and startup-config keyword shortcuts. For example, the copy running-config startup-config command saves the currently running configuration file to the NVRAM section of flash memory to be used as the configuration during system initialization.
Network file system URLs include ftp: and tftp: and have these syntaxes:
-
FTP—ftp: [[// username [: password ]@ location ]/ directory ]/ filename
-
TFTP—tftp: [[// location ]/ directory ]/ filename
Local writable file systems include flash:.
Some invalid combinations of source and destination exist. Specifically, you cannot copy these combinations:
-
From a running configuration to a running configuration
-
From a startup configuration to a startup configuration
-
From a device to the same device (for example, the copy flash: flash: command is invalid)
You can copy from remote to local, local to remote, and local to local. However, copying from remote to remote is not supported. During the copying process, one symbol ! printed on the screen indicates 100 blocks (512 bytes per block) transferred.
For specific examples of using the copy command with configuration files, see Working with Configuration Files.
To copy software images either by downloading a new version or by uploading the existing one, use the archive download-sw or the archive upload-sw privileged EXEC command. For more information, see Working with Software Images.
File Management Commands
You can use the commands in the following table to manage the file system.
Command |
Description |
||
---|---|---|---|
cd |
Change current directory. |
||
copy |
Copy from one file to another. |
||
delete |
Delete a file. |
||
dir |
List files on a filesystem. |
||
format |
Format a filesystem.
|
||
mkdir |
Create a new directory. |
||
more |
Display the contents of a file. |
||
pwd |
Display the current working directory. |
||
rename |
Rename a file. |