All right, let's jump back into the lab here.
We're going to focus on this part of the lab topology.
It really is the full topology still.
We've got the root bridge in switch one and such.
But which ports are blocking here?
We left switch for blocking on this interface.
But let's go ahead and see what else we're blocking on
between those two ports that go to switch to.
And I did reset the configuration.
I got rid of all the cost configurations
on those links to switch to.
So if I do a show, spanning tree,
let's just do blocked ports, WEBVTT X-TIMESTAMP-MAP=LOCAL:00:00:00.000,MPEGTS:900000
let's just do blocked ports,
then we see that we're blocking on gig 02.
So is this the port that we were expecting?
Because it's really easy to look at this and say,
well, this is the lower numbered port.
I thought we were supposed to favor lowered number ports.
But notice how this is configured.
We actually have the higher number port
connected to the lower number port this way.
And so the fact is that we're going to pay attention
to the switch to configuration because the BPDUs
are flowing this direction.
And again, port priorities, that's an outbound concept. WEBVTT X-TIMESTAMP-MAP=LOCAL:00:00:00.000,MPEGTS:900000
And again, port priorities, that's an outbound concept.
So I look at the fact that gig 03 is the higher interface.
And importantly, gig 02 is the lower interface.
Therefore, I keep my local port on the right there,
gig 03 in an online forwarding state.
And I place gig 02 into the blocking state.
So that's exactly what we'd expect.
But how could I change this without changing
the configuration on switch 4?
I could use costs.
And we've demonstrated that in the last lab video here. WEBVTT X-TIMESTAMP-MAP=LOCAL:00:00:00.000,MPEGTS:900000
And we've demonstrated that in the last lab video here.
But I want to go to switch 2 now.
And I want to know more information
about what's going on on gig 02 and gig 03.
What we're going to do is we're going to do a show spanning
tree interface.
And I can compare gig 02 and gig 03.
So when I look at gig 02, I see that it's
using a priority of 128.
We said that's the default.
And then this internal number that we talk about is number 3.
If I look at interface gig 03, we'll WEBVTT X-TIMESTAMP-MAP=LOCAL:00:00:00.000,MPEGTS:900000
If I look at interface gig 03, we'll
see that it's using an internal number of 4.
And also, apparently, the other VLANs
aren't actually running on that link.
But that's fine.
We'll not worry too much about that here.
Focus is on VLAN 1.
So we have the priority value.
We have the number.
And we do see why gig 02 is favored
because gig 02 has a lower number, number 3, internally,
compared to gig 03, which is number 4.
And fortunately, we can look at gig 03 and gig 02 WEBVTT X-TIMESTAMP-MAP=LOCAL:00:00:00.000,MPEGTS:900000
And fortunately, we can look at gig 03 and gig 02
and tell which one is higher and which one is lower.
But if there's ever a question, this command
will tell us exactly what it's using.
We could also just do a normal show spanning tree command.
And that information shows up right here.
In fact, we can directly compare multiple interfaces
using this command to see the relative port numbers.
But now, let's say we want to flip it,
and we want to flip it without changing switch
4's configuration.
I have to change switch 2's configuration.
What do I do here? WEBVTT X-TIMESTAMP-MAP=LOCAL:00:00:00.000,MPEGTS:900000
What do I do here?
Well, in order to switch which port is being blocked,
I'm going to have to get on here.
And again, we have port priorities of 128 and 128.
And I want to make it so that this side gets blocked,
which means this has to have a higher number relative
to the other side.
So I could lower the priority on gig 03.
I could raise the priority on gig 02.
Either way is an option.
Let's just go ahead and we'll just raise it on gig 02. WEBVTT X-TIMESTAMP-MAP=LOCAL:00:00:00.000,MPEGTS:900000
Let's just go ahead and we'll just raise it on gig 02.
So I'm going to say config T here, interface gig 02,
and spanning tree.
Again, I can do a VLAN 1 here if I want to.
I could just do it for all the VLANs.
And then when I run a question mark,
we just ran cost in the previous lab video.
Now I'm going to change the port priority.
And I see that it's between 0 and 240.
And yes, technically we say it's between 0 and 255
because it's an 8-bit number.
But Cisco mandates increments of 16.
And so I can't call it all the way up to 256.
So 240 is the highest number I can go with. WEBVTT X-TIMESTAMP-MAP=LOCAL:00:00:00.000,MPEGTS:900000
So 240 is the highest number I can go with.
Let's just do something in the middle.
I'll say 160.
That's a multiple of 16.
And so I have now raised the number, which makes it worse
on gig 02.
So gig 02 should no longer be favored.
Now, switch 2 is not going to block either port.
If I do a show spanning tree for VLAN 1 here,
it's still forwarding.
But we do see now that gig 02 has a priority of 160.
And so if I go to switch 4 and I run the exact same command, WEBVTT X-TIMESTAMP-MAP=LOCAL:00:00:00.000,MPEGTS:900000
And so if I go to switch 4 and I run the exact same command,
show spanning tree blocked ports,
we do see that we have blocked gig 03, which
is exactly what we set out to do.
So as we keep saying, keep in mind that port priority
is for outbound changes to the blocked ports.
Cost is for inbound changes.
We can leverage either one in this scenario.
But if we're ever told, hey, this configuration
has to be done on one of these switches or the other,
we're going to have to pick the right method
and apply it correctly in order to change the blocked interface. WEBVTT X-TIMESTAMP-MAP=LOCAL:00:00:00.000,MPEGTS:900000
and apply it correctly in order to change the blocked interface.