Appendix B. Regular Expressions

A regular expression is a sequence of one or more characters that can be used for two general purposes. The first purpose is to reduce the output from various show commands. For example, if you wanted to view the routing protocols that are active on a router, you could use show running-config and scroll through the output until you came to the section of the configuration that contained the routing configurations. Or, you could use an output modifier with a regular expression to display only those lines containing a router configuration command:

rtrA#show running-config | include router
router eigrp 1
router bgp 2

This code uses the output modifier include and the regular expression router to reduce the amount ...

Get Cisco® BGP-4 Command and Configuration Handbook (CCIE Professional Development) now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.