Table Of Contents
stack
switch
switch console
switch fabric
sync
sysret
telnet
test snmp trap
traceroute
unalias
undelete
unset=varname
varname=
verify
wait
whichboot
write
write tech-support
stack
Use the stack command to dump a stack trace of frames.
stack [-d | -m] [num]
Syntax Description
-d
|
(Optional) Keyword to dump the ROM monitor stack.
|
-m
|
(Optional) Keyword to specify 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
Use the switch command to switch the clock from the supervisor clock to the internal clock or from the active supervisor engine to the standby supervisor engine.
switch {clock | supervisor}
Syntax Description
clock
|
Keyword to switch the clock from the supervisor clock to the internal clock.
|
supervisor
|
Keyword to switch 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
Use the switch console command to switch the console connection physically to the MSFC on the active supervisor engine.
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 standby supervisor engine consoles. Otherwise, you cannot use the switch console command to switch to the console of the MSFC placed in the standby 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
Use the switch fabric command to reset the active Switch Fabric Module and allow the standby Switch Fabric Module to take over.
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
Use the sync command to write the working in-core copy of environment variables and the aliases out to NVRAM so they are read on the next reset.
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
Use the sysret command to display the return information from the last booted system image.
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
Use the telnet command to start a Telnet connection to a remote host.
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 snmp trap
Use the test snmp trap command to send an SNMP trap message to the trap receivers.
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
Use the traceroute command to display a hop-by-hop path through an IP network from the Catalyst 6000 family switch to a specific destination host.
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 6000 family switches can participate as the source or destination of the traceroute command. However, because they are Layer 2 devices, Catalyst 6000 family 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 6000 family 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-102 describes the fields in the traceroute command output.
Table 2-102 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-103 instead of the round-trip time or an asterisk (*).
Table 2-103 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
Use the unalias command to remove the alias name and associated value from the alias list.
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
Use the undelete command to recover a deleted file on a Flash memory device. 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
Use the unset=varname command to remove a variable name from the variable list.
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=
Use the varname= command to set the variable VARNAME to varvalue. 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
Use the verify command to confirm the checksum of a file on a Flash device.
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
Use the wait command to cause the CLI to pause for a specified number of seconds before executing the next 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
Use the whichboot command to determine which file booted.
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
Use the write command set to upload the current configuration to the network or .
write network [all]
write terminal [all]
write {host file} [all] [rcp]
write memory
Syntax Description
network
|
Keyword to specify interactive prompting for the IP address or IP alias of the host and the filename to upload.
|
all
|
(Optional) Keyword to specify default and nondefault configuration settings.
|
terminal
|
Keyword to display the nondefault configuration file on the terminal.
|
host
|
IP address or IP alias of the host.
|
file
|
Name of the configuration file.
|
rcp
|
(Optional) Keyword to upload 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
set config mode
show config
copy
write tech-support
Use the write tech-support command set 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.
write tech-support host file [module mod] [vlan vlan] [memory] [config]
write tech-support host file [port mod/port] [vlan vlan] [memory] [config]
Syntax Description
host
|
IP address or IP alias of the host.
|
file
|
Name of the configuration file.
|
module mod
|
(Optional) Keyword and variable to specify the module number.
|
vlan vlan
|
(Optional) Keyword and variable to specify 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.
|
memory
|
(Optional) Keyword to specify memory and processor state information.
|
config
|
(Optional) Keyword to specify 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.
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
Note
If MISTP is running, the output from the show spantree mistp-instance active command is displayed instead of the output from the show spantree active command.
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.