You know I've been in this industry for a long time and over the years you learn many tips and tricks
but there's a much quicker way of learning a bunch of stuff than just many years of experience and the
way to do that is to find someone who knows something or has learned something and can teach you.
So in other words find mentors.
Now I'm gonna be creating a series of videos where I want to help you become a better network engineer.
Don't spend 15 years like I have having to learn all these tips and tricks the hard way.
Just learn from these videos.
So hopefully the tips and tricks that I'm going to show you in this video and subsequent videos will
make you the so-called 10x metric engineer.
In other words you'll become a network engineer.
That's set apart from others.
You're going to learn some commands in this video that I wish I had known many years ago.
Use these commands to set you apart from others in the industry.
When you go for an interview or when you have a senior network engineer or someone else watching what
you're doing.
Use these commands and amaze them with what you can do.
In this video I'm going to show you how you can leverage Linux commands on classic Cisco AOS.
Now I'm not talking about dropping into a Linux shell.
I'm not talking about enabling a Linux VM or Linux shell separately from the Cisco.
IOW these commands run directly within Cisco ISIS.
This is classic Cisco.
IOW in other words the Iaw that's been running on network devices for many many years.
I've tested this on multiple devices.
I'm going to use Janus 3 in this example but I'll also show you that these commands work on older devices
like nineteen hundred rowdies.
So use these commands to get ahead to show others that you know stuff like many others in the industry
don't know.
Hopefully you'll enjoy this video if you do please like it.
And please consider subscribing to my YouTube channel that really does help me.
Okay you're ready to learn some really cool Cisco IOW commands.
Let me show you what's possible and show you how you can set yourself apart from others in the industry.
Okay.
Glasses on because I'm old.
Okay so here I've got a Cisco Irish Rod running in genius 3.
Show version shows me that this is v ISIS.
Here's the version of operating system on this rider.
Now some of you may already know some of these commands.
As an example show IP interface brief shows me interfaces on this router but notice here I have got
many many loop back interfaces so I've got my physical interfaces so gigabit 00 0 0 1 0 2 0 3.
But notice a whole bunch of loop back interfaces.
Now there are plenty of these.
I'm going to use force slash now that command is available in Linux.
You'll find it in VII.
As an example.
So he has a Linux device you name dash a notice I'm running Linux here.
This is a boon to Linux.
P.S. It's actually a docker container running in genius 3 but what I'll do here is start the AI and
I've got a file here which is actually a show run of a switch configuration.
Notice that when I use 4D slash I can filter.
As an example for face I can filter again for line and that just scrolls through the configuration to
that point I'll quit out of the eye here.
So this forward slash allows me to filter.
As an example for one ninety it's going to take the show IP interface brief command and filter it.
Notice filtering up to that point.
Notice loop back 192.
I'll filter again because what I'm actually looking for is this loop back 300 interface.
Starting with 1 9 2 1 6 8 100 dot 1 as the IP addresses and there's a whole bunch of these I'll filter
again for let's say the U.N. as in tunnel.
And notice it filters all the way down to tunnel.
Now I have shown this forward slash come on in other videos but that's not what I want to show you.
Yeah I'm going to show you a really cool command.
Notice I'm going to go into global configuration mode and type shell processing.
Full so I've enabled full shell processing.
That's the only command that you need.
And notice what I can do now.
So rather than doing it that way it's like show IP interface brief and then having to filter through
the configuration looking for interfaces.
I'm going to type show IP interface brief and notice what I'm going to use here.
Grep grep is a Linux command that allows me to filter or search for stuff.
Now some of you may already know include I could include let's say one thing too and that shows me all
lines that include 1 9 2 but that includes statement is quite limiting.
I can only do one include I can only search for one thing but notice what I can do here.
I can do a grep for let's say up.
So I'm looking for all interfaces that are up.
Now that's a bit boring because it's just going to show me every interface.
That's what I'm going to do now is do pipe grep and let's not show interfaces that include 1 7 2.
And let's also not show 1 9 2.
This is a three tier grep I'm doing a search for something and then I'm excluding something and I'm
excluding something else so I'm doing a three type include as an example.
You can't do that with a standard include commands.
Notice this shows me interfaces that have up in the list so these interfaces are up but I'm not seeing
1 7 2 and 1 9 2.
I've just faulted a whole range of interfaces and all I'm seeing are the gigabit interfaces and then
these tunnel interfaces and I've got to loop back interfaces here in the 10 100 range so that's really
powerful.
I could do another one here.
So let's remove those.
So let's say grep minus V.
And I could just do it this way where I could say remove loop.
I don't want to loop and noticed that just shows me gigabit interfaces and tunnel interfaces.
Now some of you may say well you could just do that once and that's true.
Just play around with the commands and see what works for you.
So I could just do grep up grep hyphen v loop so show me interfaces that have up in them but don't show
me loop back interfaces.
So that's a positive and negative grep of output.
You try and do that with just include commands.
Now you may be able to do some of that but let's show you an example of a switch that may really help
you show IP interface brief.
This will show me interfaces on the switch.
I can see gigabit interfaces.
I can see a V Line interfaces some of the interfaces are up.
Some of them are down.
But what I could do is say show me interfaces that are up but don't show me interfaces that don't have
an IP address assigned on them.
That can be really useful if you've got a large configuration and you only want to see interfaces that
have an IP address on them.
And that are up okay so how about show run grep one dot one now that dot is actually a regular expression.
Notice we've got a matching character there.
We've got a matching character here here and here.
What I could do however is say grep again for let's say 10.
So show me everything that has one dot one.
In other words one something one in it but filter that to only show me the lines that have 10 in it.
So something like this.
You might say well I could have just done include 10 as an example.
And that's true.
But don't use these examples to limit what you're thinking.
Use these examples just to show you what's possible and then think out of the box.
How can you use this.
Try different things and see if you can think of ideas of how you can use these commands and add them
below this video tell me examples that you've found useful.
Now notice I can't do an include but I can't do and exclude here.
So with grep i can do that.
So the include exclude option is kind of limiting.
But with grep i could say show me that.
But let's do hyphen V or dash v let's exclude G.I. G and that's probably because I didn't use.
Correct.
So grep dash v take notice.
Same kind of result as I had over there.
This is a double include if you like or double grep show me something that matches twice you have got
to show me a matching line but don't show me this line that matches.
So we've got to include exclude.
You can't do that with the traditional show run pipe include show run pipe exclude how I'm doing include
exclude at the same time.
OK.
So let's look at some of the Linux commands.
Here's my Linux P.C. once again so you named dash a.
Shows me that I'm using Linux hyphen hyphen help gives me help options with this command but on a Cisco
device as an example I can type you name that she this shows me that I'm using Iowa's V as an example
just like in Linux I can use man.
So look at the manuals.
So give me details of you name notice.
Lots of options available with your name.
So you name dash a.
Shows me all the information about this.
S just gives me the version of Iowa's V and gives me the name of the router but lets try.
Ah that's the version of operating system.
So if you just want to get the version of operating system that you go that could be useful in the script
as an example or V gives me details of the version very similar to the output over here with Dash.
Now again Linux does something very similar.
I could say you name dash a gives me all the output s tells me that this is Linux this shell option
has many commands.
Now you may be wondering you know what commands are supported.
I don't want to make this video too long.
I'll show you some more complex stuff in a separate video but if you want to start investigating what
options are available.
We have this show shell functions command that will show us which functions are supported by this command.
So notice a very basic one cat.
We've got cut.
We've got echo we've got grep which I've been showing you at the moment so search for regular expressions
in piped output of files.
We've got heads more.
Plenty of Linux commands available here so let's use head and tails so show run head will show me the
first 10 lines of the running configuration so there you go.
So first few lines of the running configuration.
I could also say tail which will show me the last few lines of the running configuration.
That's very basic stuff.
Cat allows me to read a file if I type D.R..
Notice there's some files and flash let's do this.
Show run.
And this is a.
This is very much a Linux command.
I'm going to pipe the show running configuration to show run the TFG so I'm going to top show run pipe
that configuration or push that configuration to the to a file in Flash.
So D.R. shows me that that file exists in flesh and what I can do here is talk more show run see if
G and notice there's the file that I'm reading from flash.
But how about this.
It's to show IP wrote
and actually let's push that to show IP right.
Doctor 60 so that file once again exists in the flash of the router.
So what I'll do here is use cat.
So Cat IP right.
T 60 cat just shows you the whole file in one go notices a lot of Roth's here.
So I'm may have preferred to use more more shows me one line at a time rather than show me the whole
output in one go.
So while we're waiting for that let's go back onto Linux so clear.
Alice shows me the file here.
Catch show run those shows me the running configuration in one go.
So that was a bit quick.
So you know this cat show run whole configuration in one go.
I could use more notice that shows me one page of configuration at a time.
Same here.
Rather than using CAT I may prefer to use more so I'm reading that file from flash but what it allows
me to do here is press Q to quit.
So rather than seeing all that output I can just see one page at a time and then quit.
Okay so I could go on for a long time here.
Notice we are using classic IOW here and I was able to use these commands by just running the shell
processing full command.
Now in other videos I'm going to show you even more powerful ways of leveraging this to make you stand
out from the competition as a network engineer.
So learn this stuff and hopefully it will save you a lot of time in the real world.
It will help you become a net better network engineer and it'll help you differentiate yourself from
others in the industry.
Now hopefully this is gonna change the way that you work.
Hopefully it's going to separate you from others that you work with or others in interviews.
Hopefully it will show people that you work with that you serious and that you an excellent network
engineer.
Once again if you don't mind please subscribe to my YouTube channel and please like this video.
I'm David bumble on I wish you all the very best.