Given the state of terminal support for the dedicated arrow keys, quite a few of the escape sequences just aren't needed anymore. Control (Ctrl)-N and Ctrl-P move up and down the history buffer, but not as well as the "up" and "down" arrow keys. Save your brain cells for more important things! Ctrl-F and Ctrl-B move forward and backward (respectively) on a line. You might see these on a test, but it's a lot easier to remember the right and left arrow keys.
Requires Free Membership to View
|
||||
Ctrl-L and Ctrl-R repeat the current command on a new line. This is useful when you're doing a lot of repetitive tasks, such as configuring access lists.
Ctrl-Z and Ctrl-C are probably common knowledge, but are included for completeness. Use Ctrl-Z to exit configuration mode, and Ctrl-C terminates a process, such as a continuous PING.
Ctrl-A can also be useful, particularly for things like setting temporary aliases. If you're doing something like troubleshooting, where you're typing the same command (debug... for instance) and you want to set it as an alias, just use the "up" arrow to get to the command in the history, and then use Ctrl-A to take you to the beginning of the line where you can insert your alias command (as opposed to holding down the left-arrow key to get to the beginning of the line.)
For further information, you can find a guide to using the terminal editing shortcuts on Cisco's Website.
Command shortcut quick reference
| Shortcut | Task |
| Ctrl-A | alias |
| Ctrl-B | move backward |
| Ctrl-C | terminate process |
| Ctrl-F | move forward |
| Ctrl-L | repeat current command on new line |
| Ctrl-N | move up the history buffer |
| Ctrl-P | move down the history buffer |
| Ctrl-R | repeat current command on new line |
| Ctrl-W | delete last word typed |
| Ctrl-Z | exit configuration mode |
This was first published in January 2006
Network Management Strategies for the CIO

Join the conversationComment
Share
Comments
Results
Contribute to the conversation