Table Of Contents
EXEC Commands in Configuration Mode
Supported Standards, MIBs, and RFCs
Executing an EXEC Command in Configuration Mode
Executing an EXEC Command in Configuration Mode Examples
EXEC Commands in Configuration Mode
Feature History
Release Modification12.1(11b)E, 12.2(7)B, 12.2(7)PB, 12.0(20)SP, 12.0(20)ST, 12.0(21)S, 12.2(8)T
This feature (the do command) was introduced.
This document describes the EXEC Commands in Configuration Mode feature and contains the following sections:
•
Supported Standards, MIBs, and RFCs
Feature Overview
You can now issue EXEC-level Cisco IOS commands (such as show, clear, and debug commands) from within any configuration mode (such as global configuration mode) by issuing the do command followed by the desired EXEC command.
Benefits
This feature provides the convenience of entering EXEC-level commands without needing to exit the current configuration mode.
Restrictions
You cannot use the do command to execute the configure terminal EXEC command because issuing the configure terminal command changes the mode to configuration mode.
Related Documents
•
Cisco IOS Configuration Fundamentals Configuration Guide
•
Cisco IOS Configuration Fundamentals Command Reference
Supported Platforms
•
This command is supported on all platforms running the software releases (and all derivative releases) listed in the Feature History at the beginning of this document.
Determining Platform Support Through Cisco Feature Navigator
Cisco IOS software is packaged in feature sets that support specific platforms. To get updated information regarding platform support for this feature, access Cisco Feature Navigator. Cisco Feature Navigator dynamically updates the list of supported platforms as new platform support is added for the feature.
Cisco Feature Navigator is a web-based tool that enables you to quickly determine which Cisco IOS software images support a specific set of features and which features are supported in a specific Cisco IOS image. You can search by feature or release. Under the release section, you can compare releases side by side to display both the features unique to each software release and the features in common.
Cisco Feature Navigator is updated regularly when major Cisco IOS software releases and technology releases occur. For the most current information, go to the Cisco Feature Navigator home page at the following URL:
Supported Standards, MIBs, and RFCs
Standards
No new or modified standards are supported by this feature.
MIBs
No new or modified MIBs are supported by this feature.
To obtain lists of supported MIBs by platform and Cisco IOS release, and to download MIB modules, go to the Cisco MIB website on Cisco.com at the following URL:
http://www.cisco.com/public/sw-center/netmgmt/cmtk/mibs.shtml
RFCs
No new or modified RFCs are supported by this feature.
Configuration Tasks
See the following section for the configuration task for the EXEC Commands in Configuration Mode feature:
•
Executing an EXEC Command in Configuration Mode (optional)
Executing an EXEC Command in Configuration Mode
To execute an EXEC-level command in any configuration mode (including configuration submodes), issue the following command in global configuration mode or the mode from which you want to issue the EXEC command:
Configuration Examples
This section provides the following configuration examples:
•
Executing an EXEC Command in Configuration Mode Examples
Executing an EXEC Command in Configuration Mode Examples
The following example shows how to execute the EXEC-level show interface command from within global configuration mode:
Router(config)# do show interfaces serial 3/0Serial3/0 is up, line protocol is upHardware is M8T-RS232MTU 1500 bytes, BW 1544 Kbit, DLY 20000 usec, rely 255/255, load 1/255Encapsulation HDLC, loopback not set, keepalive set (10 sec)Last input never, output 1d17h, output hang neverLast clearing of "show interface" counters never...Router(config)#The following example shows how to execute the EXEC-level clear vpdn tunnel command from within VPDN configuration mode:
Router(config-vpdn)# do clear vpdn tunnelRouter(config-vpdn)#Command Reference
This section documents the new command introduced by this feature. All other commands used with this feature are documented in the Cisco IOS Release 12.1 command reference publications.
•
do
do
To execute an EXEC-level command from global configuration mode or any configuration submode, use the do command in any configuration mode.
do command
Syntax Description
Defaults
No default behavior or values.
Command Modes
All Configuration Modes
Command History
Usage Guidelines
Use this command to execute EXEC commands (such as show, clear, and debug commands) while configuring your routing device. After the EXEC command is executed, the system will return to the last mode you were in.
Examples
In the following example, the show interfaces EXEC command is issued from within global configuration mode:
Router(config)# do show interfaces serial 3/0Serial3/0 is up, line protocol is upHardware is M8T-RS232MTU 1500 bytes, BW 1544 Kbit, DLY 20000 usec, rely 255/255, load 1/255Encapsulation HDLC, loopback not set, keepalive set (10 sec)Last input never, output 1d17h, output hang neverLast clearing of "show interface" counters never...Router(config)#In the following example, the clear vpdn tunnel EXEC command is issued from within VPDN configuration mode:
Router(config-vpdn)# do clear vpdn tunnelRouter(config-vpdn)#