the next topic of discussion. It concerns routing Is router on a stick? Cisco likes to call this topic router on a stick. Much better term, in my opinion, is interval and routing.
So we're gonna do our interview and routing between router to here
and switch eight over hair. So between router to and switch eight. So this kind of looks like a round or sitting on a stick. That's why Cisco likes to call it rather on a stick
interview and routing is what we're actually doing.
So I'm going to put PC one and pc to in Network 10 10 10 0
slashed 24. I'm gonna assign PC one an I P. Address off 10 10 10 1 and pc to an I P address off. 10. 10 10 to pc one and two are going to be in villain 10
then pc three and P C. Four. I'm gonna put in Villa and 20
in the network. 2020 20 0 with PC three being 2020 23 PC for being 2020. 24 slash 24. The 10 network is also gonna have a slash 24 mask,
so let's go ahead and assign these species
their respective I p addresses.
So I go into the PC. By the way, guys, you guys can download a copy of packet tracer from the Internet. Just do a quick Google search for it. And then if you go to YouTube and watch a packet tracer tutorial, you guys can create their own this lab exactly as is at home,
and then do all these labs along with the video, which I highly recommend.
So I'm gonna go into PC one, do I pee configuration And the I P address is going to be 10 10 dot and, uh, one. My sub net master is going to be 255.255 dot through 55.0
same deal, but with an i p address off 10 dot Tenn dot turned up too
true. 55255255.0 Being the seven. That mask
PC three is going to be
$20.20 dollars, 20.3.
Again with the sub net master slashed 24
on the last P C P. C. Four
gonna sign it and the dress off $20.20 dollars 20.4 with the mass being 2552552550
I'm gonna go to switch eight
and create well, and 10 and 20
need to maximize this. So I'm inside. I'll switch eight.
I'm going to create a villain,
we can call it a name
And I'm gonna create villain 20
so I can do the command villain 20 from the conflict villain mode and we'll just pop me into Bill and 20
and I'm going to call this name.
Let's call it the sales of the land
exit out of here and check to see if my villains are there. So do show villain grief
and 20 are have been created and they are active.
when I say I'm gonna put PC one and PC to in villain 10
as if we remember, that actually means
that the ports on which these P Cesaire connected the ports on the switch are going to be added to Dilantin.
So that's what puts PC one and PC to in Milan 10.
So it's hard difficult to see over here the ports, but I'm gonna tell you PC one is connected to port one and PC to is connected to zero slash to being poor, too.
So I'm gonna log into my switch again,
and I need to go to port one and poor to an Advil and 10 to port one and 42
Now, I could do this individually, or I haven't shown you this command previously.
You can do an interface Range Command
and do PC one and PC to simultaneously,
so I'm going to say interface range
zero slash 1-2 So the range is
port one and port to I could have said 1-24 then the range would have been port one to port 24. But at this time, I just need to configure port one and poor too,
and put them in, be land 10.
So first I tell Port one and poor, too,
that they're gonna be access ports
since they're connected to end devices and they're gonna be carrying only one villain and access port carries only one villain at a time. And then I'm going to say switch port
Now I'm going to go over to Port three and Port four,
where PC three and P C. Four are connected.
So I'm going to say interface range. Fascinating that zeroes. Last 3-4 and Advil and 22 Port three and four. Now can I say this from while being inside of conflict if range
or while being under this prompt? Of course I can. If I hit enter hair, it just pops me into port three and four.
Once again, I say switch port mode
making port three and four access ports and then switch port access Villain
I exit out of my range command and check my work. Do show villain brief. Make sure
Port one and two have been added to be Land 10
and poor three in Port four have been added to Villain 20
PC one and PC to should be able to talk to each other and PC three and P C four should be able to talk to each other, so let's make sure that works.
I need to make these ports go up
So for all these ports, I'm going to say in the face rings you know, slash 1-4
in the face range. Fast Internet zero slash 1-4 and I'm gonna execute the spanning tree
court Fast command. Remember, guys, The Spanish report Fast command or the port fast peep feature
pops the port directly into fording without going through the 52nd spanning three convergence process from
blocking, which is 20 seconds to learning, which which is 2015 seconds to listening, which is 15 seconds. And then to fording the port goes directly to forging.
and now I'm gonna test connectivity between PC one and PC to.
So I go to my command, prompt. And I say paying 10 don't attend, attend to.
And you see that I'm getting a reply from
to do host to which is PC to So I got a reply from 10 9 10 9 10 dot too.
And then I go to p C three, go to his command, prompt
and then I paying $20. $20.20.4 which is P C four and I get a reply from p C four
now we'll pc one be able to ping p c three since PC one is in broadcast domain bill and 10 or a network. 10 10 10 0 slash 24 PC three is a network $20.20 dollars $20.0 slash 24 p. C. One is not going to be able to ping p C three or reach PC three
before I do that. If PC one can ping pc to Ken PC to ping p C. One off course it can.
Well, let's test it anyways
being 10 dot Tenn dot Tenn 10.0.0.1. So I'm on PC to and I'm pinging PC one and it works.
The reason it works is because remember, ICMP has two parts and echo and echo reply. So if PC one can Ping P C to B, C two has to send an echo reply, which means PC to camping PC one Also.
Now let's test out a ping between PC one and PC three,
so paying $20.2020 dollars. Three
and it is not going to work because
PC one and PC three are in two different broadcast domains. As you see it is timing out.
So now we need to set up interview and routing for this to function for PC one to be able to paying PC three or P C four or PC to to be able to paying PC three or P C four
Port 24 FAA zeros last 24 router to interface F zero slash one, or F ace Fast Internet zero slash one is going to be a trunk.
So we already know how to configure a trunk
So I'm gonna go into my port 24
Fast Lieutenant zero slash 24
and I'm going to say switch port
encapsulation. Remember, we have to pick between 0.1 Q and I sl. Hence. This command exists, however, on switches. Nowadays, the only option that exists is not one cues on the real switch. If it's a new newer device, it's not going to contain this command.
However, since Packet tracer is a learning to and this command this part off your CCN exam, it still exists on packet tracer.
So I'm going to say switchboard trunk and consolation 0.1 Q.
Then I'm gonna make this a trunk switch, port mode,
and then I'm going to turn off DTP. Remember the automatic negotiation protocol
which automatically negotiates drunk ing between switches? Well, the other end off port 24
for switch a port 24. The other end is router to routers. Do not understand DTP anyways, so I might as well turn it off.
Switch port? No. Negotiate.
So if I look, do you show interface
fast it in a zero slash 24
switch ports? It should say that my negotiation of trunk ing is off. If I had not done the transport no negotiate command, this would have said on.
So the sweet side is done.
Now I go to the router end. Well,
Let me go into port. Fast. Internet zero slash 24. Remember, guys, by default,
all villains are allowed over the port.
If you see it's a strong king. Villains enabled all
I need to modify this list to just be land 10 and 20. Could I leave it like this? Yes. Is it best practice? No, that's too loose.
It's a security risk. So I'm going to say switch port
10 comma 20 just to allow villain 10 and 20 or that trump.
So if I look at my douceur interface faceted at zero slash 24 switch for command again.
villains enabled just
Okay, now we're just sending villains.
So before it says villains enabled all.
And now it says we lands enabled
Okay, I'm done with the switch, and I will save my work.
Moving on to the router this is you see is interface facet in at zero slash one.
going to config mode or global conflict Moved by saying configure terminal and I enter my fast Ethernet port zero slash one
by saying interface faceted at zero slash one.
And then I do a new shutdown on this port.
And then I said new I p address because there is not going to be an i p. Address
Then I can put a description
on this port and say, trunk
Now, how come I didn't put an I P address on that interface?
The reason being that I'm going to be creating sub interfaces. Little baby interfaces underneath the main interface.
So how do I can create a sub interface. I simply say interface
fast, Lieutenant, you know, slash one dot
And if I execute the help feature here by a pressing question mark,
I can pick any number between zero and this large number
for 294967295 actually, 4294967296 is two to the power 32. So 0 to 49 4967295 is actually 429496 79 6 Little tidbit for you Since this some interface is going to be carrying
I'm just going to call it something to face 10.
Now, could I have called it something to face 9945? Of course I could have.
But as I said, since this sub interface is going to be carrying villain 10
make it 0.10. I usually like matching my sub interface. I d.
In this case, it's not 10 with the villain is going to be carrying.
So at this point, if I say do show i p inter face brief,
you see that I have created the sub interface.
Next. If I trying to sign it an i p Address i p. Address
Tenn dot Tenn dot tend not to
2 54.2 54 being the last address in the $10.10 dollars $10.0 slash 24 range because the valid addresses go from 240.12 dot to 54
Let's see what happens if I try to assign it in a dress. Shouldn't let me.
basically well, let's read what it says configuring I p routing on a lance up interface is only allowed if that it's having two faces already configured as part of an IEEE it or two dot
or thio 2.10 or IEEE. It'll do that one. Q
or I sl villain. Basically, it's saying that unless this sub interface has already been made into a trunk
or has an encapsulation type off 82 dot
10 or it'll do 100.1 q r. I s l I'm not allowed to give it an I P address, so let's fix that
press in consolation
0.1 Q. 10. At this point, this sub interface is carrying Villain Tent.
I used my up arrow key
and bring up the I P. Address again, and at this point, it accepted that I p address.
So I simply picked the last possible I p address in the $10.10 dollars $10.0 slash 24 range and assigned it to this interface or sub interface. Next, I'm going to create a sub interface for villain 20.
So I simply used up Arrow Key to bring up the command interface fast. Internet zero slash 1.10
turned the 10 into a 20
and at this point, you even see the logging message on my console. Say that something to face fast Internet zero slash wound up 20 has been created.
Next, I'm gonna make this sub interface carry villain 20
by saying encapsulation
0.1 Q 20. Next, I'm going to assign it an I P address out of the $20.20 dollars $20.0 slash 24 range,
which was villain 20.
So I'm going to say $20.20 dollars, $20 to 54 again, the last possible address in that range
and your slash 24 mask or 2552552550
and check to see if the sub interfaces have been created. So show
I p interface brief.
and I see that my two sub interfaces have been created faceted at zero slash 1.10 and 20
and they have their respective eyepiece assigned.
Let me make sure the trunk has gone up
since I did a no *** on the main interface on router to the faceted zero slash one interface. This trunk on the switch should have gone up,
so let's make sure it has
sure interface trunk.
And you see that asked. Zito's last 24 is a trunk. The mode is on the encapsulation, is it? Oh, to that one. Q. And it is trunk ing and carrying Milan 10 and 20
Now. At this point will I be able to ping between PC one and PC three?
Ping, I'm on PC one and PC threes. I p addresses $20. 20 doc 20.3 And for some reason, it is not pinging still.
Well, we have one little bit of information missing from our PCs.
So let's go into PC one
and look at our I p configuration.
As you see that I left the default gateway
portion of this, I'd be configuration black. Now the default gateway off a device is your door out off your network, So PC one is a network. 10 10 10 zeroes Last 24. To go out, I need to go through a door to get to other networks.
That door we created on Router to
this sub interface Faceted at zero slash 1.10 that is the Door PC one and PC to Orville and 10 or network. $10.10 dollars $10.0 slash 24 will use to get out to other networks. So I need to assign
PC one and PC to a default gateway of 10 10 10
So let's go to P C. One again.
Go to the I P configuration and type in 10 dot Tenn dot Tenn dot to 54
Tenn dot Tenn dot Tenn dot to 54
Now PC three and P C four also need a default Gateway and their default Gateway on Router to is going to be
the sub interface that is carrying Villain
which is your 2020 $20.00
network or specifically, the $20.20 dollars 20.254 address
on sub interface Facet, innit? Judo slash one about 20.
So let's go and assign PC three and PC for a default. Gateway of $20.20 dollars, $20 to 54
and p c four A default gateway
pc one should be able to ping p C. Three
since our interview and routing should be working
now. First, let's go to Router to and make sure so we check the trunk
switch eight. Now let's see
if router to has both Network 10 and Network 20 in its i p routing table.
So we execute the command show I P route
to look at our I p routing table. And remember, guys, the i p routing table. It's simply a table with a listing of destinations that are available to the router
I hit. Enter and you see the network 10 not 10 not 10 0
is directly connected on fast Internet zero slash 1.10
and Network 20 is directly connected on fast Internet zero slash 1.20
This network 1 51 01 45.0 is directly connected to facet in a 00 That's our landside, the 1 51 1 45 0 network, the network between router one router to router to Ian right before with those four switches. So we're not paying attention to this right now.
We're only concerned with these two entries.
The sea at the very left hand corner simply means these are connected networks
at this point. Since we have both destinations in the i p routing table, the router knows how to route between them. If a destination is not available on the rowdy I P routing table, the router would simply drop the packet.
So let's find out if PC one can ping P C. Three.
Well, a good rule of thumb is before you paying
across your network from your network to another network. You should pin your your default gateway to find out that locally you have connectivity,
so let's paying 10 that tend tend to 54 which is the fast Internet zero slash one dot
10 interface on router to
So I'm going to attempt to paying across now to PC three, which is $20.20 dollars, $20 3
So the first pain failed
because of the our process. PC one wanted to ping p C. Three so Pc one created a packet with a source address off 10 dot Tenn dot Tenn 10.0.0.1 and a destination address off 2020 20 that three,
then PC one send out in our broadcast requesting the Mac address of PC three.
However, since routers run proxy are on all that fast Internet interfaces or Ethan that interfaces period
sent back its own Mac address to P C. One.
The Mac address reciting on f zero slash one.
Let's find out if that really happened.
So if I look at my our cash on this PC with command are minus a.
I see the physical address or the Mac address off. 10. Not 10 not 10 not 254 which is the Mac address reciting on F zero slash one.
So let's go find out if that is actually true.
So the address is 00 d zero d three b six
Let's go to Ratter to
interface F zero slash one dot
and you see this Mac address right here. This is going to be the same Mac address that's gonna be on f zero slash one. These these interfaces and sub interface is the main interface and its constituent. Some interfaces share a Mac address,
if I just simply say sure interface F zero slash one.
The Mac address here is 00 d zero d three b six
and on f zero slash one
sure interfaces of zero slash one. The main interface. You see the Mac address is the same 00 d zero
on the sub interface. Also, it was 00 d zero. Then it says d three b six b three b six
four B 0 to 4 B zero to and that is the same Mac address that was resolved on PC. One
00 d zero d. Three b 64 b 02
because router to send its own Mac address back to PC one because router to f zero slash one is running proxy art,
between the odd request and out replied between PC one and router to
this first ping timed out.
Now that the our cash has been created already, if I try the ping again, I should get 100% success rate.
between PC one and PC three,
that I go through. If I maximize this, I see that I go through peace router to F zero slash 1.10 and then I get to PC three.
So at this point, I should be able to ping from any PC to any PC. So let's try that.
if I tried to ping from P C. Four to PC one, it should also ping. So if I'm paying
Tenn dot Tenn dot Tenn 0.0.0.1 from p C. Four with the source address 20.2020 dot for this should also work
now. What is happening in this case?
A detailed explanation is
PC one needs to ping PC Tree
PC one Creates and ICMP Echo Packet with source address. $10.10 dollars, 10.1 and destination at this 2022. 23
pc one that needs the Mac address for PC three to create
anything that frame for transmitting on the local data link between PC one and router to
so PC one ARPs for the Mac address off PC three and sends an art request, which is a broadcast.
The art frame receives, I mean, is received by the switch and forward it. Since it is a broadcast to out off all ports, the infinite frame
is received by the switch and ford it out off all ports in Villain 10. Since now, we have two virtual switches inside off the main physical device.
the odd request reaches Router to
which is also part of villain 10 on facet in at zero slash 1.10 and router to. Since it's running proxy out replies to PC one with its own Mac.
BC One receives router twos at zero slash one. Mac creates the Internet frame and sends it over to switch eight
Switch. It seems that this
frame belongs to Villain 10 inserts a 100.1 q Tag off villain 10 Inside of the frame and Fords it out off of zeros last 24 towards round or two
router to receives this frame on f zero slash 1.10.
Why? Because if you look at our running config, sure running config.
That 10 interface has encapsulation 100.1 Q. So this sub interface is going to receive frames from villain 10
so the frame goes inbound into outer two on fast Internet zero slash 1.10
rotter to receives the frame compares the destination Mac address in the frame with the Mac address on f zero slash one
and then, since it matches router router to discards the frame d encapsulate sit and extracts the original packet
next router to doesn't I? P. Routing table? Look up. So if we look at our round table with the show I p Route Command router to discovers the network 2020 $20.0 is directly connected on fast Internet zero slash 1.20
So rather too knows that it has to send
the packet out fast, Lieutenant
Now, then router to needs to create
a frame and Internet frame for transmitting on the local data link between router to and PC three
router to, at this point sends out an art request requesting the Mac address that belongs to $20.20 dollars, $20 3
sends out our request. Host three replies back with its own Mac. So let's look at router. Choose
with the show I P R. Command
and you see 29 29 20. That three has already been resolved. 000 B b E 85 754 This should be the Mac address sitting on PC three since PC three sent back and our reply
uni casted back to router to
router to has resolved PC threes i p. Address to its Mac address.
Let's check the Mac address on PC three
with the R minus a command
Actually, with the i p. Config.
I think there's a space here
and you see PC three's Mac address is 000 b
be 85 754 the same address that exists on Router two's Our Cash
So at this point router to knows that it's going to be sending
this frame out off fast, sitting at zero slash 1.20
So router to builds the Internet frame with its own source. Mack with the Mack Address residing on F zero slash 1.20 and the destination Mac off PC three
router to also adds villain 20 tag into the frame and sends it over
Switch eight receives
this frame on the trunk link between router to and router and switch eight, which is zero slash
as heroes last 24. Here we go zero slash 24 switch aid, then removes the tag and looks up at the Mac address in its Mac address table, which it should contain on Port three
and poor trees Not showing up yet. Let's paying ones so that the switch bills it's Mac address table. So paying
the Mac address should be in switch eight. Mac address table
switch. It knows that Mac Ada's you know 00 b b e 85 754 is sitting on poor tree.
Switch eight. Removes the villain 20 tag and sends the frame over to PC three. P. C. Three Compares the destination Mac in the frame with its own Mac and finds that this frame is meant for itself.
Switch a PC three, then discards the frame. Dean Caps, relates it and extracts the original packet.
PC three, then compares the destination. I'd be in the packet with its own i p and since it matches
BC three cents back in the corps. Reply.
This concludes the router on a stick or interview and routing lecture.