Helpful Cisco Commands
Well, this is my first tech post so I’ll make it an easy one. I’ll put a few of the commands that I regularly utilize on Cisco routers and Switches to make my life easier.
| (Pipe) command output modifier –
Alrighty, this truly is a basic command. You issue a normal command at the privilege exec level and add the | (pipe) afterwards followed by an i (include) e (exclude) or b (begin). Begin is not available in all IOS versions.
Command Example:
show run | i ip route
would show something like this:
ip route 10.0.0.0 255.255.255.0 11.24.1.1 name default
ip route 10.1.255.0 255.255.255.0 11.24.1.2 name backup_net
If you were to replace the i with a b the output would begin at “ip route” and continue on with the rest of the config. This would be useful for those really long configs where you might be working on the dial-peers and don’t care to scroll through 500 lines of the config to get there. The e option would exclude anything that you have following it. This might come into handy when you want to skip ip address or access-lists. Hope this helps, I was lucky enough to learn these tricks early on and didn’t have to struggle for too aweful long. Good luck.
Comments ()