What is the “do” command?
sVeryfication commands, such as the show command, are entered in user EXEC mode or privileged EXEC mode. After setting up something, if you try to verify it with the show command, you have to switch modes. It’s not easy to change the mode every time you try to do so.
So, the do command allows you to execute EXEC commands such as the show command from the configuration mode.
Example of the do command
As an example, let’s say you have configured an IP address for an interface and then you want to check the IP address. You can check the status of the interface by typing “do show ip interface brief” while you are in interface configuration mode.
R1(config)#interface loopback 0 R1(config-if)#ip address 192.168.0.1 255.255.255.255 R1(config-if)#do show ip interface brief Interface IP-Address OK? Method Status Protocol FastEthernet0/0 192.168.1.254 YES manual up up Loopback0 192.168.0.1 YES manual up up R1(config-if)#
Note that the completion by [TAB] is not effective after the do command. You can enter the command in an abbreviated form.
- Preparing for Cisco router configuration
- Configuration files for Cisco devices
- The configuration steps for Cisco devices
- Basic knowledge of the Cisco CLI: Command types and modes
- Cisco device’s interface
- CLI help and completion
- The main error messages in CLI
- Cisco Deleting a configuration command
- default interface command -Initialize the interface settings-
- Entering commands in batches
- do command – Execute EXEC command from configuration mode –
- interface range command -Batch configuration of multiple interfaces-
- Filtering the display of the show command – displaying only the information you want to see –
- debug command to check real-time operation
- IOS File System Operations
- Managing Cisco Catalyst Switches :What it means to set an IP address on a switch.
- terminal monitor command to display the log of Telnet/SSH login destination
- Set the minimum number of characters in the password [Cisco]
- Cisco Initial Configuration Example
- CDP – What are the connected devices? –
- Password recovery for Cisco routers
- Password Recovery for Catalyst Switches