Table Of Contents
stack
switch
switch console
switch fabric
sync
sysret
telnet
test cable-diagnostics
test snmp trap
traceroute
unalias
undelete
unset=varname
varname=
verify
wait
whichboot
write
write tech-support
22
stack
To dump a stack trace of frames, use the stack command.
stack [-d | -m] [num]
Syntax Description
-d
|
(Optional) Dumps the ROM monitor stack.
|
-m
|
(Optional) Specifies addresses to dump.
|
num
|
(Optional) Number of frames.
|
Defaults
The default for num is five frames.
Command Types
ROM monitor command.
Command Modes
Normal.
Usage Guidelines
The frames are dumped from the kernel stack and the process stack (if one is available) of a booted image. Use the frame command to display an individual stack frame.
The minus sign (-) is required with the -d and -m options.
Examples
This example shows how to use the stack command to dump a stack trace of eight frames:
Kernel Level Stack Trace:
Initial SP = 0x60276a98, Initial PC = 0x60033054, RA = 0x6006d380
Frame 0 : FP= 0x60276a98, PC= 0x60033054, 0 bytes
Frame 1 : FP= 0x60276a98, PC= 0x6006d380, 24 bytes
Frame 2 : FP= 0x60276ab0, PC= 0x600e5218, 40 bytes
Frame 3 : FP= 0x60276ad8, PC= 0x600dcd48, 32 bytes
Frame 4 : FP= 0x60276af8, PC= 0x60033fdc, 0 bytes
Process Level Stack Trace:
Initial SP = 0x80007ce8, Initial PC = 0x600dfd38, RA = 0x600dfd20
Frame 0 : FP= 0x80007ce8, PC= 0x600dfd38, 24 bytes
Frame 1 : FP= 0x80007d00, PC= 0x6005b260, 32 bytes
Frame 2 : FP= 0x80007d20, PC= 0x6005c05c, 192 bytes
Frame 3 : FP= 0x80007de0, PC= 0x6005b54c, 24 bytes
Frame 4 : FP= 0x80007df8, PC= 0x600e82e0, 56 bytes
Frame 5 : FP= 0x80007e30, PC= 0x600e9484, 40 bytes
Frame 6 : FP= 0x80007e58, PC= 0x600e8b28, 24 bytes
Frame 7 : FP= 0x80007e70, PC= 0x600de224, 72 bytes
Related Commands
frame
switch
To switch the clock from the supervisor clock to the internal clock or from the active supervisor engine to the standby supervisor engine, use the switch command.
switch {clock | supervisor}
Syntax Description
clock
|
Switches the clock from the supervisor clock to the internal clock.
|
supervisor
|
Switches from the active supervisor engine to the standby supervisor engine.
|
Defaults
This command has no default settings.
Command Types
Switch command.
Command Modes
Privileged.
Examples
This example shows how to switch the clock:
Console> (enable) switch clock
This command will reset system and force a clock switch-over.
Do you want to continue (y/n) [n]?
This example shows how to switch to the standby supervisor engine:
Console> (enable) switch supervisor
This command will force a switch-over to the standby Supervisor module.
Do you want to continue (y/n) [n]?
switch console
To switch the console connection physically to the MSFC on the active supervisor engine, use the switch console command.
switch console [mNo]
Syntax Description
mNo
|
(Optional) Module number.
|
Defaults
The default is supervisor engine console.
Command Types
Switch command.
Command Modes
Privileged.
Usage Guidelines
This command is not supported on Telnet sessions.
The switch console command allows you to change to the MSFC that shares the slot with the active supervisor engine. To use this command, it is necessary to have active and redundant supervisor engine consoles. Otherwise, you cannot use the switch console command to switch to the console of the MSFC placed in the redundant supervisor engine slot.
If you place the MSFC on a supervisor engine installed in slot 1, the MSFC is recognized as module 15. If you install the supervisor engine in slot 2, the MSFC is recognized as module 16. If the optional argument mNo is excluded, the console will switch to MSFC on the active supervisor engine.
To exit from the router CLI back to the switch CLI, press Ctrl-C three times at the Router> prompt.
Examples
This example shows how to switch the console connection to the MSFC on the active supervisor engine:
Console> (enable) switch console 15
Type ^C^C^C to switch back...
switch fabric
To reset the active Switch Fabric Module and allow the standby Switch Fabric Module to take over, use the switch fabric command.
switch fabric [mNo]
Syntax Description
mNo
|
(Optional) Switch Fabric Module number.
|
Defaults
This command has no default settings.
Command Types
Switch command.
Command Modes
Privileged.
Usage Guidelines
This command is not supported on Telnet sessions.
Examples
This example shows how to reset the active Switch Fabric Module:
Console> (enable) switch fabric
This command will force a switch-over to the standby fabric module.
Do you want to continue (y/n) [n]?
sync
To write the working in-core copy of environment variables and the aliases out to NVRAM so they are read on the next reset, use the sync command.
sync
Syntax Description
This command has no arguments or keywords.
Defaults
This command has no default settings.
Command Types
ROM monitor command.
Command Modes
Normal.
Examples
This example shows how to use the sync command:
sysret
To display the return information from the last booted system image, use the sysret command.
sysret
Syntax Description
This command has no arguments or keywords.
Defaults
This command has no default settings.
Command Types
ROM monitor command.
Command Modes
Normal.
Usage Guidelines
The stack dump information displayed has a maximum of eight frames.
Examples
This example shows how to use the sysret command to display the return information from the last booted system image:
count: 19, reason: user break
pc:0x60043754, error address: 0x0
FP: 0x80007e78, PC: 0x60043754
FP: 0x80007ed8, PC: 0x6001540c
FP: 0x80007ef8, PC: 0x600087f0
FP: 0x80007f18, PC: 0x80008734
telnet
To start a Telnet connection to a remote host, use the telnet command.
telnet host [port]
Syntax Description
host
|
Name or IP address of the remote host to which you want to connect.
|
port
|
(Optional) Specific port connection on the remote host.
|
Defaults
This command has no default settings.
Command Types
Switch command.
Command Modes
Privileged.
Examples
This example shows how to open and close a Telnet session with the host elvis:
Console> (enable) telnet elvis
Escape character is '^]'.
UNIX(r) System V Release 4.0 (elvis)
Last login: Thu Oct 15 09:25:01 from forster.cisc.rum
Sun Microsystems Inc. SunOS 5.4 Generic July 1994
Related Commands
disconnect
test cable-diagnostics
To test the condition of 10-Gigabit Ethernet links or copper cables on 48-port 10/100/1000 BASE-T modules, use the test cable-diagnostics command.
test cable-diagnostics prbs {start | stop} mod/port
test cable-diagnostics tdr mod/port
Syntax Description
prbs
|
Specifies the Pseudo Random Binary Sequence (PRBS) test on a 10-Gigabit Ethernet link.
|
start
|
Activates the test.
|
stop
|
Deactivates the test.
|
mod/port
|
Number of the module and the port on the module.
|
tdr
|
Activates the Time Domain Reflectometer (TDR) test for copper cables on 48-port 10/100/1000 BASE-T modules.
|
Defaults
This command has no default settings.
Command Types
Switch command.
Command Modes
Privileged.
Usage Guidelines
The PRBS test is currently available only on the 1-port 10GBASE-E serial 10-Gigabit Ethernet module (WS-X6502-10GE).
To run the PRBS test properly between two devices, you must start it on both ends of the cable. If the cable is looped back, a single end can generate the test sequence (on the Tx) as well as verify it and count the errors (on the Rx).
Before the PRBS test starts, the port is automatically put in errdisable state. The errdisable timeout is disabled for the port so that the port is not automatically reenabled after the timeout interval concludes. The errdisable timeout is automatically reenabled on the port after the PRBS test finishes.
When the PRBS test is running, the system will not you permit you to enter the set port enable and set port disable commands.
The TDR test is currently available only on the 48-port 10/100/1000 BASE-T modules (WS-X6148-GE-TX and WS-X6548-GE-TX).
Note
When you run the TDR test, we recommend that you do not make any configurations on the port that you are testing or enter the show port command for that port. If you make any port-related configurations or enter the show port command, the TDR test results might be inaccurate or the module might fail.
Examples
This example shows how to start the PRBS test on port 1 on module 5:
Console> (enable) test cable-diagnostics prbs start 5/1
PRBS cable-diagnostic test started on port 5/1.
This example shows how to stop the PRBS test on port 1 on module 5:
Console> (enable) test cable-diagnostics prbs stop 5/1
PRBS cable-diagnostic test stopped on port 5/1.
This example shows the message that displays when the PRBS test is not supported:
Console> (enable) test cable-diagnostics prbs start 6/1
Feature not supported on module 6.
This example shows how to start the TDR test on port 1 on module 8:
Console> (enable) test cable-diagnostics tdr 8/1
TDR test started on port 8/1. Use show port tdr <m/p> to see the results
Related Commands
show port prbs
show port tdr
test snmp trap
To send an SNMP trap message to the trap receivers, use the test snmp trap command.
test snmp trap trap_num [specific_num]
Syntax Description
trap_num
|
Number of the trap.
|
specific_num
|
(Optional) Number of a predefined trap.
|
Defaults
This command has no default settings.
Command Types
Switch command.
Command Modes
Privileged.
Examples
This example shows how to run trap 0:
Console> (enable) test snmp trap 0
SNMP trap message sent. (4)
Related Commands
set snmp trap
show snmp
traceroute
To display a hop-by-hop path through an IP network from the Catalyst 6500 series switch to a specific destination host, use the traceroute command.
traceroute [-n] [-w wait_time] [-i initial_ttl] [-m max_ttl] [-p dest_port] [-q nqueries] [-t tos]
host [data_size]
Syntax Description
-n
|
(Optional) Option that prevents traceroute from performing a DNS lookup for each hop on the path. Only numerical IP addresses are printed.
|
-w wait_time
|
(Optional) Option used to specify the amount of time (in seconds) that traceroute will wait for an ICMP response message. The allowed range for wait_time is from 1 to 300 seconds.
|
-i initial_ttl
|
(Optional) Option that causes traceroute to send ICMP datagrams with a TTL value equal to initial_ttl instead of the default TTL of 1. This causes traceroute to skip processing for hosts that are less than initial_ttl hops away.
|
-m max_ttl
|
(Optional) Option used to specify the maximum TTL value for outgoing ICMP datagrams. The allowed range for max_ttl is from 1 to 255.
|
-p dest_port
|
(Optional) Option used to specify the base UDP destination port number used in traceroute datagrams. This value is incremented each time a datagram is sent. The allowed range for dest_port is from 1 to 65535. Use this option in the unlikely event that the destination host is listening to a port in the default traceroute port range.
|
-q nqueries
|
(Optional) Option used to specify the number of datagrams to send for each TTL value. The allowed range for nqueries is from 1 to 1000.
|
-t tos
|
(Optional) Option used to specify the ToS to be set in the IP header of the outgoing datagrams. The allowed range for tos is from 0 to 255.
|
host
|
IP alias or IP address in dot notation (a.b.c.d) of the destination host.
|
data_size
|
(Optional) Number of bytes, in addition to the default of 40 bytes, of the outgoing datagrams. The allowed range is from 0 to 1420.
|
Defaults
Entering the traceroute host command without options sends three 40-byte ICMP datagrams with an initial TTL of 1, a maximum TTL of 30, a timeout period of 5 seconds, and a ToS specification of 0 to destination UDP port number 33434. For each host in the processed path, the initial TTL for each host and the destination UDP port number for each packet sent are incremented by one.
Command Types
Switch command.
Command Modes
Privileged.
Usage Guidelines
To interrupt traceroute after the command has been issued, press Ctrl-C.
The traceroute command uses the TTL field in the IP header to cause routers and servers to generate specific return messages. Traceroute starts by sending a UDP datagram to the destination host with the TTL field set to 1. If a router finds a TTL value of 1 or 0, it drops the datagram and sends back an ICMP "time-exceeded" message to the sender. The traceroute facility determines the address of the first hop by examining the source address field of the ICMP time-exceeded message.
To identify the next hop, traceroute again sends a UDP packet but this time with a TTL value of 2. The first router decrements the TTL field by 1 and sends the datagram to the next router. The second router sees a TTL value of 1, discards the datagram, and returns the time-exceeded message to the source. This process continues until the TTL is incremented to a value large enough for the datagram to reach the destination host (or until the maximum TTL is reached).
To determine when a datagram has reached its destination, traceroute sets the UDP destination port in the datagram to a very large value that the destination host is unlikely to be using. When a host receives a datagram with an unrecognized port number, it sends an ICMP "port unreachable" error to the source. This message indicates to the traceroute facility that it has reached the destination.
Catalyst 6500 series switches can participate as the source or destination of the traceroute command. However, because they are Layer 2 devices, Catalyst 6500 series switches do not examine the TTL field in the IP header and do not decrement the TTL field or send ICMP time-exceeded messages. Thus, a Catalyst 6500 series switch does not appear as a hop in the traceroute command output.
Use the tos option to see if different types of service cause routes to change.
Examples
This example shows how to use the traceroute command to determine the path from the source to the destination host server10:
Console> (enable) traceroute server10
traceroute to server10.company.com (172.16.22.7), 30 hops max, 40 byte packets
1 engineering-1.company.com (172.31.192.206) 2 ms 1 ms 1 ms
2 engineering-2.company.com (172.31.196.204) 2 ms 3 ms 2 ms
3 gateway_a.company.com (172.16.1.201) 6 ms 3 ms 3 ms
4 server10.company.com (172.16.22.7) 3 ms * 2 ms
Table 2-105 describes the fields in the traceroute command output.
Table 2-105 traceroute Command Output Fields
Field
|
Description
|
30 hops max, 40 byte packets
|
Maximum TTL value and the size of the ICMP datagrams being sent.
|
2 ms 1 ms 1 ms
|
Total time (in milliseconds) for each ICMP datagram to reach the router or host plus the time it took for the ICMP time-exceeded message to return to the host.
An exclamation point following any of these values (for example, 20 ms !) indicates that the port-unreachable message returned by the destination had a TTL of 0 or 1. Typically, this occurs when the destination uses the TTL value from the arriving datagram as the TTL in its ICMP reply. The reply does not arrive at the source until the destination receives a traceroute datagram with a TTL equal to the number of hops between the source and destination.
|
3 ms * 2 ms
|
"*" indicates that the timeout period (default of 5 seconds) expired before an ICMP time-exceeded message was received for the datagram.
|
If traceroute receives an ICMP error message other than a time-exceeded or port-unreachable message, it prints one of the error codes shown in Table 2-106 instead of the round-trip time or an asterisk (*).
Table 2-106 traceroute Error Messages
ICMP Error Code
|
Meaning
|
!N
|
No route to host. The network is unreachable.
|
!H
|
No route to host. The host is unreachable.
|
!P
|
Connection refused. The protocol is unreachable.
|
!F
|
Fragmentation needed but do not fragment (DF) bit was set.
|
!S
|
Source route failed.
|
!A
|
Communication administratively prohibited.
|
?
|
Unknown error occurred.
|
Related Commands
ping
unalias
To remove the alias name and associated value from the alias list, use the unalias command.
unalias name
Syntax Description
Defaults
This command has no default settings.
Command Types
ROM monitor command.
Command Modes
Normal.
Usage Guidelines
You must issue a sync command to save your change. Otherwise, the change is not saved and the reset—ROM monitor command removes your change.
Examples
This example shows how to use the unalias command to remove the s alias and then check to ensure it was removed:
monitor: command "s" not found
===========================================================================
Related Commands
alias
undelete
To recover a deleted file on a Flash memory device, use the undelete command. The deleted file can be recovered using its index (because there could be multiple deleted files with the same name).
undelete index [[m/]device:]
Syntax Description
index
|
Index number of the deleted file.
|
m/
|
(Optional) Module number of the supervisor engine containing the Flash device.
|
device:
|
(Optional) Device where the Flash resides.
|
Defaults
This command has no default settings.
Command Types
Switch command.
Command Modes
Privileged.
Usage Guidelines
A colon (:) is required after the specified device. See the dir—switch command to learn the index number of the file to be undeleted. A file cannot be undeleted if a valid file with the same name exists. You must delete the existing file before you can undelete the target file. A file can be deleted and undeleted up to 15 times. To delete all deleted files permanently on a device, use the squeeze command.
Examples
This example shows how to recover the deleted file with index 1 and use the show flash command to confirm:
Console> (enable) undelete 1 bootflash:
Console> (enable) show flash
-#- ED --type-- --crc--- -seek-- nlen -length- -----date/time------ name
1 .. ffffffff fec05d7a 4b3a4c 25 4667849 Mar 03 2000 08:52:09 cat6000-sup.
2 .. ffffffff 4e5efc31 c0fadc 30 7716879 May 19 2000 06:50:55 cat6000-sup-
3605796 bytes available (12384988 bytes used)
Related Commands
delete
show flash
squeeze
unset=varname
To remove a variable name from the variable list, use the unset=varname command.
unset=varname
Syntax Description
varname
|
Name of the variable.
|
Defaults
This command has no default settings.
Command Types
ROM monitor command.
Command Modes
Normal.
Usage Guidelines
You must enter the sync command to save your change to NVRAM. Otherwise, the change is not saved and a reset removes your change.
Examples
This example shows how to use the set command to display the variable list, remove a variable name from the variable list, and then display the variable list to verify:
Related Commands
varname=
varname=
To set the variable VARNAME to varvalue, use the varname= command. Note that the syntax varname= sets the variable to a NULL string.
varname=value
Syntax Description
varname=
|
Name of the variable.
|
value
|
Any ROM monitor command.
|
Defaults
This command has no default settings.
Command Types
ROM monitor command.
Command Modes
Normal.
Usage Guidelines
Do not put a space before or after the equal (=) sign. If there are spaces, you must place the value in quotes. Spell out variable names in uppercase letters to make them conspicuous.
Examples
This example shows how to assign a variable name to a value:
Related Commands
unset=varname
verify
To confirm the checksum of a file on a Flash device, use the verify command.
verify [[m/]device:] filename
Syntax Description
m/
|
(Optional) Module number of the supervisor engine containing the Flash device.
|
device:
|
(Optional) Device where the Flash resides.
|
filename
|
Name of the configuration file.
|
Defaults
This command has no default settings.
Command Types
Switch command.
Command Modes
Privileged.
Usage Guidelines
A colon (:) is required after the specified device.
Examples
This example shows how to use the verify command:
Console> verify cat6k_r47_1.cbi
..........................................................
File cat6k_r47_1.cbi verified OK.
wait
To cause the CLI to pause for a specified number of seconds before executing the next command, use the wait command. This command might be included in a configuration file.
wait seconds
Syntax Description
seconds
|
Number of seconds for the CLI to wait before executing the next command.
|
Defaults
This command has no default settings.
Command Types
Switch command.
Command Modes
Normal.
Examples
This example shows how to pause the CLI for 5 seconds:
whichboot
To determine which file booted, use the whichboot command.
whichboot
Syntax Description
This command has no arguments or keywords.
Defaults
This command has no default settings.
Command Types
Switch command.
Command Modes
Privileged.
Examples
This example shows how to use the whichboot command:
Boot image name is 'slot0:cat6000-sup.6-1-1.bin'.
write
To upload the current configuration to the network or , use the write command.
write network [all]
write terminal [all]
write {host file} [all] [rcp]
write memory
Syntax Description
network
|
Specifies interactive prompting for the IP address or IP alias of the host and the filename to upload.
|
all
|
(Optional) Specifies default and nondefault configuration settings.
|
terminal
|
Displays the nondefault configuration file on the terminal.
|
host
|
IP address or IP alias of the host.
|
file
|
Name of the configuration file.
|
rcp
|
(Optional) Uploads a software image to a host using rcp.
|
memory
|
Keyword that specifies to upload the current configuration to a specified location.
|
Defaults
This command has no default settings.
Command Types
Switch command.
Command Modes
Privileged.
Usage Guidelines
The write terminal command is exactly the same as the show config command. The write host file command is a shorthand version of the write network command.
You cannot use the write network command to upload software to the ATM module.
With the write network command, the file must already exist on the host (use the UNIX touch filename command to create it).
Before you can enter the write memory command, you must enter text configuration mode. Enter text configuration mode by entering the set config mode text command.
Examples
This example shows how to upload the system5.cfg file to the mercury host:
Console> (enable) write network
IP address or name of host? mercury
Name of configuration file to write? system5.cfg
Upload configuration to system5.cfg on mercury (y/n) [y]? y
Done. Finished Network Upload. (9003 bytes)
This example shows how to upload the system5.cfg file to the mercury host:
Console> (enable) write mercury system5.cfg
Upload configuration to system5.cfg on mercury (y/n) [y]? y
Done. Finished Network Upload. (9003 bytes)
This example shows how to display the configuration file on the terminal (partial display):
Console> (enable) write terminal
#version 4.2(0.24)VAI58 set password $1$FMFQ$HfZR5DUszVHIRhrz4h6V70
set enablepass $1$FMFQ$HfZR5DUszVHIRhrz4h6V70
set power redundancy enable
set snmp community read-only public
set snmp community read-write private
set snmp community read-write-all secret
set snmp trap disable module
<<<< output truncated >>>>
This example shows how to upload the running system configuration to a prespecified location:
Console> (enable) write memory
Upload configuration to bootflash:switch.cfg
7165844 bytes available on device bootflash, proceed (y/n) [n]? y
Related Commands
copy
set config mode
show config
write tech-support
To generate a report that contains status information about your switch or upload the output of the command to a TFTP server, where you can send it to the Technical Assistance Center, use the write tech-support command.
write tech-support host file [module mod] [vlan vlan] [mistp-instance instance] [mst instance]
[memory] [config]
write tech-support host file [port mod/port] [vlan vlan] [mistp-instance instance] [mst instance]
[memory] [config]
Syntax Description
host
|
IP address or IP alias of the host.
|
file
|
Name of the configuration file.
|
module mod
|
(Optional) Specifies the module number.
|
vlan vlan
|
(Optional) Specifies the VLAN; valid values are from 1 to 1001 and from 1025 to 4094.
|
port mod/port
|
(Optional) Keyword and variables to specify the module and port on the module.
|
mistp-instance instance
|
(Optional) Specifies the MISTP instance number; valid values are from 1 to 16.
|
mst instance
|
(Optional) Specifies the MST instance number; valid values are from 0 to 15.
|
memory
|
(Optional) Specifies memory and processor state information.
|
config
|
(Optional) Specifies switch configuration information.
|
Defaults
By default, this command displays the output for technical-support-related show commands. Use keywords to specify the type of information to be displayed. If you do not specify any parameters, the system displays all configuration, memory, module, port, instance, and VLAN data.
Command Types
Switch command.
Command Modes
Privileged.
Usage Guidelines
Caution 
Avoid running multiple write tech-support commands on a switch or multiple switches on the network segment. Doing so may cause spanning tree instability.
Note
If you press Ctrl-C while the write tech-support is outputting, the output file to the TFTP server might be incomplete.
Note
If you are uploading the information to a file, make sure the file already exists in the TFTP server, the file has appropriate permissions, and the network connections are good before you issue the write tech-support command.
If you specify the config keyword, the write tech-support command displays the output of these commands:
•
show config
•
show flash
•
show log
•
show microcode
•
show module
•
show port
•
show spantree active
•
show spantree summary
•
show system
•
show test
•
show trunk
•
show version
•
show vlan
Note
If MISTP is running, the output from the show spantree mistp-instance active and show spantree summary mistp-instance commands are displayed instead of the output from the show spantree active and show spantree summary commands.
Note
If MST is running, the output from the show spantree mst and show spantree summary mst commands are displayed instead of the output from the show spantree active and show spantree summary commands.
If you specify the memory keyword, the write tech-support command displays the output of these commands:
•
ps
•
ps -c
•
show cam static
•
show cam system
•
show flash
•
show memory buffers
•
show microcode
•
show module
•
show proc
•
show proc mem
•
show proc cpu
•
show system
•
show spantree active
•
show version
If you specify a module, port, or VLAN number, the system displays general system information and information for the component you specified.
Examples
This example shows how to upload the technical report:
Console> (enable) write tech-support 172.20.32.10 tech.txt
Upload tech-report to tech.txt on 172.20.32.10 (y/n) [n]? y
Finished network upload. (67784 bytes)
Related Commands
show tech-support
See the commands listed in the "Usage Guidelines" section.