Table Of Contents
2clear vtp statistics
Use the clear vtp statistics command to delete the VTP statistics.
clear vtp statistics
Syntax Description
This command has no arguments or keywords.
Defaults
This command has no default setting.
Command Types
Switch command.
Command Modes
Privileged.
Examples
This example shows how to clear the VTP statistics:
Console> (enable) clear vtp statisticsvtp statistics cleared.Console> (enable)Related Commands
configure
Use the configure command to download a configuration file from a host and execute each command in that file.
configure host file [rcp]
Syntax Description
host
IP address or IP alias of the host.
file
Name of the configuration file.
rcp
(Optional) Keyword that specifies rcp as file transfer method.
Defaults
The default file transfer method is TFTP.
Command Types
Switch command.
Command Modes
Privileged.
Usage Guidelines
Refer to the Software Configuration Guide for your switch for information on how to construct a configuration file to download using the configure command.
Examples
The following is an example configuration file. Each line contains a command, except for the lines that begin with ! or #. On some servers (NT), the TFTP directory might not be /tftpboot.
beginshow timeset ip alias conc7 198.133.219.207set ip alias montreux 198.133.119.42set ip alias cres 192.122.174.42set prompt system5>set password# empty string old passwordpingpongpingpongend#This example shows how to configure the switch using a configuration file downloaded from a TFTP server:
Console> (enable) configure 192.122.174.42 system5.cfgConfigure using system5.cfg from 192.122.174.42 (y/n) [n]? y/Done. Finished Network Download. (446 bytes)>> show timeWed Nov 11 1998, 17:42:50>> set ip alias conc7 198.133.219.207IP alias added.>> set ip alias montreux 198.133.219.40IP alias added.>> set ip alias cres 192.122.174.42IP alias added.>> set prompt system5>>> set passwordEnter old password:Enter new password: pingpongRetype new password: pingpongPassword changed.This example shows how to configure a Catalyst 5000 family switch with a Supervisor Engine II, II G, or III G using a configuration file downloaded from a rcp server:
Console> (enable) configure 172.20.52.3 dns-config.cfg rcpFinished network download. (134 bytes)>>>> set ip dns server 172.16.10.70 primary172.16.10.70 added to DNS server table as primary server.>> set ip dns server 172.16.10.140172.16.10.140 added to DNS server table as backup server.>> set ip dns enableDNS is enabled>> set ip dns domain corp.comDefault DNS domain name set to corp.comConsole> (enable)Related Commands
confreg
Use the confreg command to set the configuration register value or to modify the configuration register using the configuration register utility.
confreg [hexvalue]
Syntax Description
Defaults
This command has no defaults.
Command Types
ROM monitor command.
Command Modes
Normal.
Usage Guidelines
If you specify hexvalue, the confreg command changes the configuration register value to the hexadecimal value specified.
If you do not specify hexvalue, confreg shows the current configuration register values and prompts you to keep or change the current values.
The new configuration register value is written into NVRAM and does not take effect until you reset or power cycle the switch.
Examples
This example shows how to use the confreg command:
rommon 1 > confregConfiguration Summaryenabled are:console baud:9600boot:the ROM Monitordo you wish to change the configuration? y/n [n]: yenable "diagnostic mode"? y/n [n]:<Return>enable "use net in IP bcast address"? y/n [n]:<Return>enable "load rom after netboot fails"? y/n [n]:<Return>enable "use all zero broadcast"? y/n [n]:<Return>enable "break/abort has effect"? y/n [n]:<Return>enable "ignore system config info"? y/n [n]:<Return>change console baud rate? y/n [n]:<Return>change the boot characteristics? y/n [n]: yenter to boot:0 = ROM Monitor1 = the boot helper image2-15 = boot system[0]: 2Configuration Summaryenabled are:console baud:9600boot:image specified by the boot system commandsor default to:cisco2-Prestodo you wish to change the configuration? y/n [n]:<Return>You must reset or power cycle for new config to take effectrommon 2 >Related Commands
copy
Use the copy command to perform these tasks:
•
Download a system image or configuration file from a TFTP or rcp server to a Flash device
•
Upload a system image or configuration file from a Flash device to a TFTP or rcp server
•
Configure the switch using a configuration file on a Flash device or on a TFTP or rcp server
•
Copy the current configuration to a Flash device or to a TFTP or rcp server
copy file-id {file-id | tftp | rcp | flash | config}
copy cfg1 {tftp | rcp | flash | config | cfg2} [all]
copy cfg2 {tftp | rcp | flash | config | cfg1} [all]
copy config {file-id | flash | tftp | rcp} [all]
copy tftp {file-id | flash | config | cfg1 | cfg2}
copy rcp {file-id | flash | config | cfg1 | cfg2}
copy flash {file-id | tftp | rcp | config}
Syntax Description
Defaults
By default, the copy config, copy cfg1, and copy cfg2 commands will copy only non-default commands to the destination configuration file. Use the keyword all to copy both default and non-default configurations.
If a source or destination Flash device is not specified, the default Flash device (specified by the cd command) is used. Use the pwd command to display the current default Flash device. If the destination filename is omitted, the system uses the source filename.
The system stores image and configuration files in the sysname.cfg file when the user has defined a system name using the set system name command; otherwise, it uses the default myswitch.cfg file.
Command Types
Switch command.
Command Modes
Privileged.
Usage Guidelines
This command is not supported on Catalyst 5000 family Supervisor Engine II.
These switches support only the bootflash: Flash device:
•
Catalyst 5000 family Supervisor Engine III F
•
Catalyst 4000 family switches
•
Catalyst 2926G series switches
•
Catalyst 2948G switch
•
Catalyst 2980G switch
The cfg1 and cfg2 startup configuration files are present only on the Catalyst 5000 family Supervisor Engine II G and III G. These files are limited to 256 KB in size.
If you use the flash keyword as the copy source or destination, you are prompted for the Flash device name.
If you are copying a software image to multiple intelligent switching modules of the same type, use the flash keyword as the copy destination. The switch automatically determines which modules to copy the image to based on the header in the source image file. If you want to copy a software image to a single intelligent switching module in a switch with multiple modules of the same type, you must specify the destination file-id as m/bootflash: (do not specify a filename).
Examples
This example shows how to upload the non-default switch configuration to a file named cat.cfg on the slot0: Flash device:
Console> (enable) copy config slot0:cat.cfgUpload configuration to slot0:cat.cfg649324 bytes available on device slot0, proceed (y/n) [n]? y........../Configuration has been copied successfully. (10200 bytes)Console> (enable)This example shows how to upload both the default and non-default switch configuration to a file named lab2.cfg on a TFTP server:
Console> (enable) copy config tftp:lab2.cfg allIP address or name of remote host [172.20.22.7]? yUpload configuration to imgFile:lab2.cfg (y/n) [n]? y........../Configuration has been copied successfully. (10299 bytes).Console> (enable)This example shows how to upload the non-default switch configuration to the cat.cfg file on the slot1: Flash device:
Console> (enable) copy config flashFlash device [bootflash]? slot1:Name of file to copy to [configFile]? cat.cfgUpload configuration to slot1:cat.cfg749124 bytes available on device slot1, proceed (y/n) [n]? y........../Configuration has been copied successfully. (200345 bytes).Console> (enable)This example shows how to upload an image from a remote host into Flash using rcp:
Console> (enable) copy rcp flashIP address or name of remote host []? 172.20.52.3Name of file to copy from []? cat5000-sup3.4-2-1.binFlash device [bootflash]?Name of file to copy to [cat5000-sup3.4-2-1.bin]?4369664 bytes available on device bootflash, proceed (y/n) [n]? yCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCFile has been copied successfully.Console> (enable)This example shows how to upload the running configuration on a Catalyst 5000 family switch with a Supervisor Engine III or III F, or on a Catalyst 4000 family, 2926G series, 2948G, or 2980G switch, to an rcp server for storage:
Console> (enable) copy config rcpIP address or name of remote host []? 172.20.52.3Name of file to copy to []? cat5000_config.cfgUpload configuration to rcp:cat5000_config.cfg, (y/n) [n]? y............................................./Configuration has been copied successfully.Console> (enable)This example shows how to configure a Catalyst 5000 family switch with a Supervisor Engine III or III F, or a Catalyst 4000 family, 2926G series, or 2948G switch using a configuration file downloaded from an rcp server:
Console> (enable) copy rcp configIP address or name of remote host []? 172.20.52.3Name of file to copy from []? dns-config.cfgConfigure using rcp:dns-config.cfg (y/n) [n]? y/Finished network download. (134 bytes)>>>> set ip dns server 172.16.10.70 primary172.16.10.70 added to DNS server table as primary server.>> set ip dns server 172.16.10.140172.16.10.140 added to DNS server table as backup server.>> set ip dns enableDNS is enabled>> set ip dns domain corp.comDefault DNS domain name set to corp.comConsole> (enable)This example shows how to configure the switch using a configuration file on a Flash device:
Console> (enable) copy flash configFlash device [bootflash]?Name of configuration file? test.cfgConfigure using bootflash:test.cfg (y/n) [n]? y/Finished download. (10900 bytes)>> set password $1$FMFQ$HfZR5DUszVHIRhrz4h6V70Password changed.>> set enablepass $1$FMFQ$HfZR5DUszVHIRhrz4h6V70Password changed.>> set prompt Console>>> set length 24 defaultScreen length set to 24.>> set logout 20.....Console> (enable)This example shows how to copy a file from a TFTP server to a Flash device:
Console> (enable) copy tftp bootflash:Address or name of remote host [172.20.22.7]?Enter source file name [cat4000-sup.4-5-1.bin]?Enter destination file name [cat4000-sup.4-5-1.bin]?6942528 bytes available in flash, proceed (y/n) [n]?yConsole> (enable)This example shows how to download a configuration to the first startup configuration file (cfg1) on a Supervisor Engine II G or III G:
Console> (enable) copy tftp cfg1IP address or name of remote host [172.20.32.10]?Name of file to copy from [/tftpboot/my.cfg]?Download config file from /tftpboot/my.cfg to cfg1 (y/n) [n]?.........File has been copied to cfg1.Console> (enable)Related Commands
delete
Use the delete command to delete a file on a Flash device.
delete file-id
delete {cfg1 | cfg2}
Syntax Description
Defaults
This command has no default setting.
Command Types
Switch command.
Command Modes
Privileged.
Usage Guidelines
This command is not supported on Catalyst 5000 family Supervisor Engine II.
These switches support only the bootflash: Flash device:
•
Catalyst 5000 family Supervisor Engine III F
•
Catalyst 4000 family switches
•
Catalyst 2926G series switches
•
Catalyst 2948G switch
•
Catalyst 2980G switch
The cfg1 and cfg2 startup configuration files are present only on the Catalyst 5000 family Supervisor Engine II G and III G.
Use the undelete command to recover a deleted file.
A file cannot be undeleted if a valid file with the same name exists. Instead, you must delete the existing one first and then undelete the desired file. A file can be deleted or undeleted up to 15 times. To permanently remove all deleted files on a device, use the squeeze command.
Examples
This example shows how to delete a file from a Flash device:
Console> (enable) delete bootflash:switch_config.cfgConsole> (enable)This example shows how to delete the first startup configuration file (cfg1) on a Supervisor Engine II G or III G:
Console> (enable) delete cfg1Delete cfg1 from flash (y/n) [n]? ycfg1 has been deleted from flashConsole> (enable)Related Commands
dir—switch
undelete
show flash
squeezedev
Use the dev command to list the device IDs available on a switch.
dev
Syntax Description
This command has no arguments or keywords.
Defaults
This command has no defaults.
Command Types
ROM monitor command.
Command Modes
Normal.
Usage Guidelines
This command is supported by the Catalyst 5000 family switches and the Catalyst 2926G series switches.
Examples
This example shows how to use the dev command:
rommon 4 > devDevices in device table:id namebootflash: boot flashslot0: PCMCIA slot 0slot1: PCMCIA slot 1eprom: epromrommon 5 >dir—ROM monitor
Use the dir command to list the files on a Flash device.
dir device
Syntax Description
Defaults
This command has no defaults.
Command Types
ROM monitor command.
Command Modes
Normal.
Examples
This example shows how to list the files on a Flash device:
rommon 6 > dir bootflash:File size Checksum File name14086 bytes (0x3706) 0xa6a84c93 switch_config.cfg (deleted)5415 bytes (0x1527) 0x53bbccda 5509_config.cfg446464 bytes (0x6d000) 0x8503219d cat5000-sup3.5-1-1.bin (deleted)4231861 bytes (0x4092b5) 0x1d6092f4 cat5000-sup3.5-2-1.binrommon 7 >dir—switch
Use the dir command to display a list of files on a Flash device.
dir file-id [all | deleted | long]
Syntax Description
Defaults
This command has no default setting.
Command Types
Switch command.
Command Modes
Normal and privileged.
Usage Guidelines
This command is not supported on the Catalyst 5000 family Supervisor Engine II.
When you omit all keywords (all, deleted, or long), the system displays file information in short format. Short format output is explained in Table 2-1.
Table 2-1 Short Format File Information
Column Heading Description#
File index number
length
File length
date/time
Date and time the file was created
name
Filename
When you use one of the keywords, the system displays file information in long format. The long format is shown in Table 2-2.
Examples
This example shows how to display the file information in short format:
Console> (enable) dir-#- -length- -----date/time------ name2 3093399 Oct 18 1998 12:33:14 cat5000-sup3.4-5-1.bin1428272 bytes available (6173904 bytes used)Console> (enable)This example shows how to display the file information in long format:
Console> (enable) dir long-#- ED --type-- --crc--- -seek-- nlen -length- -----date/time------ name2 .. ffffffff 762950d6 6234d0 25 3093399 Oct 18 1998 12:33:14 cat5000-sup3.4-5-1.bin1428272 bytes available (6173904 bytes used)Console> (enable)This example shows the file with index number 1 deleted:
Console> (enable) dir all-#- ED --type-- --crc--- -seek-- nlen -length- -----date/time------ name1 .D ffffffff 5415406e 3300b8 25 3080247 Jun 12 1998 13:22:46 cat5000-sup3.4-5-1.bin2 .. ffffffff 762950d6 6234d0 25 3093399 Oct 18 1998 12:33:14 cat5000-sup3.4-5-1.bin1428272 bytes available (6173904 bytes used)Console> (enable)Related Commands
disable
Use the disable command to return to normal mode from privileged mode.
disable
Syntax Description
This command has no arguments or keywords.
Defaults
This command has no default setting.
Command Types
Switch command.
Command Modes
Privileged.
Examples
This example shows how to return to normal mode:
Console> (enable) disableConsole>Related Commands
disconnect
Use the disconnect command to close an active console port or Telnet session.
disconnect {ip_addr | console}
Syntax Description
ip_addr
Source IP address or IP alias of the session to disconnect; in dot notation, for example, 101.102.103.104.
console
Keyword that specifies to clear an active session on the console port.
Defaults
This command has no default setting.
Command Types
Switch command.
Command Modes
Privileged.
Usage Guidelines
If multiple sessions from the same IP address exist, the system checks if the current session originated from the specified IP address. If the session did not originate from the specified IP address, all Telnet sessions from the address are disconnected. If the session does originate from the specified address, all sessions, other than the current session, are disconnected. The system prompts whether to disconnect the current Telnet session. You can answer n and remain connected or answer y and be disconnected.
Examples
This example shows how to close a Telnet session to host 192.168.255.255 (the 1 in parenthesis indicates the number of active sessions disconnected):
Console> (enable) disconnect 192.168.255.255Telnet session from 192.168.255.255 disconnected. (1)Console> (enable)This example shows how to close the current console session:
Console> (enable) disconnect consoleConsole session disconnected.Console> (enable)Related Commands
download
Use the download command to copy a software image from a specified host to the Flash memory of the supervisor engine or a designated module.
download host file [mod_num] [rcp]
download serial [mod_num]
Syntax Description
Defaults
If a module number is not specified, the image is downloaded to all modules for which the image
is valid.Command Types
Switch command.
Command Modes
Privileged.
Usage Guidelines
This command is supported by the Catalyst 5000 family switches and the Catalyst 2926G series switches.
The Catalyst 5000 family and 2926G series switches support two ways to download software images to the switch:
•
TFTP network download through any network port
•
Kermit serial download through the EIA/TIA-232 console port
You can only download supervisor engine software using the Kermit method.
If you are performing a serial download, you can only download a software image to the supervisor engine. You cannot download a software image to a switching module using the serial download method.
If the module number is specified, the system attempts to download the file to the specified module. If the module is a different type from the type indicated by the download header, the download fails. If the module number is not specified, the file is downloaded to all modules of the type specified in the download header.
To download a software image to the Catalyst 5000 family RSM, you must session to the router and use the copy command to download the software.
You can download a software image to the Catalyst 5000 family RSFC by specifying the RSFC module number in the download command. However, when you download a system image to the RSFC from the switch CLI, the image is stored in RAM only. To permanently store the system image on the RSFC, you must session to the RSFC and use the copy command to copy the software.
In software release 5.2 and later, the download command performs the following actions automatically on switches that support the Flash file system:
•
If necessary, deletes the oldest image file on the bootflash: Flash device and performs a squeeze on the bootflash: device. The process is repeated until there is space sufficient for copying the new software image.
•
Copies the new software image to the bootflash: device.
•
Prepends the new image name to the BOOT variable.
Note
You can use the download command as part of a minimal downtime software upgrade. For complete information on performing a minimal downtime software upgrade, refer to the Software Configuration Guide for your switch.
The download serial command uses the Kermit protocol through the serial EIA/TIA-232 console port. The download serial command is not allowed from a console session (the console port must be available for the serial download).
CautionAfter starting the serial download using Kermit, do not attempt to abort the serial download by pressing Ctrl-C. Pressing Ctrl-C interrupts the download process and might leave the switch in a problematic state. If this occurs, reboot the switch.
Examples
This example shows how to download the c5000_spv11.bin file from the mercury host to the supervisor engine module (by default):
Console> (enable) download mercury c5000_spv11.binDownload image c5000_spv11.bin from mercury to module 1FLASH (y/n) [n]? y\Finished network single module download. (2418396 bytes)FLASH on Catalyst:Type Address LocationIntel 28F008 20000000 NMP (P3) 4MB SIMErasing flash sector...done.Programming flash sector...done.Erasing flash sector...done.Programming flash sector...done.The system needs to be reset to run the new image.Console> (enable)This example shows how to download the fddi_1113.cpi file from the mercury host to module 4:
Console> (enable) download mercury fddi_1113.cpi 4This command will reset Module 4.Download image fddi_1113.cbi from mercury to Module 4 FLASH (y/n) [n]? y|Finished network download. (1064876 bytes)...............................................................................nConsole> (enable)This example shows how to use the download command on a Catalyst 5000 family Supervisor Engine III to automatically delete files as necessary and squeeze bootflash:, copy a software image from a TFTP server, and prepend the new image filename to the BOOT variable:
Console> (enable) download 172.20.52.3 cat5000-sup3.5-2-1.binDownload image cat5000-sup3.5-2-1.bin from 172.20.52.3 to Module 1 FLASH(y/n) [n]? ySqueeze bootflash in progress....Erasing squeeze log CCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCFile has been copied successfully.Console> (enable)This example shows how to download the c5000_spv11.bin file from the mercury host to the supervisor engine module:
Console> (enable) download mercury c5000_spv11.bin rcpDownload image c5000_spv11.bin from mercury to module 1FLASH (y/n) [n]? y\Finished network single module download. (2418396 bytes)FLASH on Catalyst:Type Address LocationIntel 28F008 20000000 NMP (P3) 4MB SIMErasing flash sector...done.Programming flash sector...done.Erasing flash sector...done.Programming flash sector...done.The system needs to be reset to run the new image.Console> (enable)This sample session shows how to connect to a remote terminal from a Sun workstation and how to use the download serial command to copy a software image to the supervisor engine module:
[At local Sun workstation]host% kermitC-Kermit 5A(172) ALPHA, 30 Jun 95, SUNOS 4.0 (BSD)Type ? or 'help' for helpC-Kermit> set line /dev/ttybC-Kermit> cConnecting to /dev/ttyb, speed 9600.The escape character is ^ (ASCII 28).Type the escape character followed by C to get back,or followed by ? to see other options.Console> enableEnter Password:Console> (enable) set system baud 19200^\C[Back at local Sun workstation]C-Kermit> set speed 19200/dev/ttyb, 19200 bpsC-Kermit> cConnecting to /dev/ttyb, speed 19200.The escape character is ^ (ASCII 28).Type the escape character followed by C to get back,or followed by ? to see other options.Console> (enable) download serialDownload Supervisor image via console port (y/n) [n]? yConcentrator Boot ROM (Ver 1.00)Waiting for DOWNLOAD!!Return to your local Machine by typing its escape sequenceIssue Kermit send command from there[ Send `Filename`]^\C[Back at Local System]C-Kermit> send c5000_xx.binSFc5000_xx.bin => C5000_XX.BIN, Size: 1233266X to cancel file, CR to resend current packetZ to cancel group, A for status reportE to send Error packet, Ctrl-C to quit immediately:............................................................................................................................... [OK]ZBC-Kermit> quithost%Related Commands


