WEBVTT

0:00:08.400000 --> 0:00:11.580000
 Let's go into a little bit more detail
 now about OSPF by looking at the

0:00:11.580000 --> 0:00:18.080000
 different kinds of OSPF packets, what
 they're used for, and the purpose.

0:00:18.080000 --> 0:00:24.440000
 So like EIGRP, how EIGRP had specific
 packets do certain things like the

0:00:24.440000 --> 0:00:28.160000
 hello, the update, the
 query, and the reply.

0:00:28.160000 --> 0:00:30.840000
 OSPF also has specific
 packet types.

0:00:30.840000 --> 0:00:34.600000
 We have the OSPF hello, and just like
 you could guess, that's used to

0:00:34.600000 --> 0:00:40.280000
 dynamically discover OSPF neighbors and
 to maintain OSPF neighbor relationships,

0:00:40.280000 --> 0:00:42.100000
 what we call adjacencies.

0:00:42.100000 --> 0:00:45.240000
 Now we also have these other packets
 which are used in the process of

0:00:45.240000 --> 0:00:48.860000
 building a neighbor relationship, the
 database descriptor and the link

0:00:48.860000 --> 0:00:52.560000
 state request. So the database descriptor
 and the link state request,

0:00:52.560000 --> 0:00:57.500000
 you will only see those when a neighbor
 relationship is very first being

0:00:57.500000 --> 0:01:02.320000
 built. After that neighbor relationship
 is up and maintained, you won't

0:01:02.320000 --> 0:01:03.820000
 see those again.

0:01:03.820000 --> 0:01:07.360000
 And then you also have the link state update
 and the link state acknowledgement

0:01:07.360000 --> 0:01:12.620000
 packet. And the vast majority of
 those are sent as multicast.

0:01:12.620000 --> 0:01:15.560000
 So I'm going to come back to those
 in just a moment to talk about how

0:01:15.560000 --> 0:01:21.940000
 they're used and during what process
 they're used, we will get to that.

0:01:21.940000 --> 0:01:26.140000
 So just like with EIGRP, how there were
 certain things during the hello

0:01:26.140000 --> 0:01:30.620000
 packet exchange that had to match with
 EIGRP, here you can see there are

0:01:30.620000 --> 0:01:34.480000
 also certain things that need to match
 for an OSPF adjacency to fully

0:01:34.480000 --> 0:01:39.100000
 form. So number one, the timers, the
 hello and the dead interval, they

0:01:39.100000 --> 0:01:42.140000
 have to match. This is
 different than EIGRP.

0:01:42.140000 --> 0:01:48.240000
 In EIGRP, we could exchange hello packet
 to you might say, Hey, if you

0:01:48.240000 --> 0:01:52.100000
 don't hear from me within five
 minutes, declare me to be dead.

0:01:52.100000 --> 0:01:55.060000
 And your hello packet to me might be,
 Hey, Keith, if you don't hear from

0:01:55.060000 --> 0:01:57.940000
 me within 30 seconds,
 declare me to be dead.

0:01:57.940000 --> 0:01:58.700000
 That would be fine.

0:01:58.700000 --> 0:02:03.800000
 As long as we set our expectations appropriately,
 we be okay with OSPF,

0:02:03.800000 --> 0:02:06.840000
 those timers have to be the same.

0:02:06.840000 --> 0:02:10.940000
 Authentication, which as I mentioned
 in earlier video is optional.

0:02:10.940000 --> 0:02:14.980000
 But if you are doing authentication,
 the type of authentication has to

0:02:14.980000 --> 0:02:18.920000
 be the same. Because you and I could
 either exchange clear text passwords,

0:02:18.920000 --> 0:02:23.760000
 or it could exchange passwords are hashed
 with the message digest formula.

0:02:23.760000 --> 0:02:26.080000
 So the type has to be the same.

0:02:26.080000 --> 0:02:30.420000
 And clearly, whatever the password
 is has to be the same as well.

0:02:30.420000 --> 0:02:34.880000
 The area ID. So you and I share this
 common link, this common cable.

0:02:34.880000 --> 0:02:38.920000
 If in my network statement that covers
 this cable, I believe this is an

0:02:38.920000 --> 0:02:48.480000
 area one. You indicated that you
 think this link is an area 50.

0:02:48.480000 --> 0:02:50.100000
 And I think it's an area one.

0:02:50.100000 --> 0:02:51.500000
 That's going to be a problem.

0:02:51.500000 --> 0:02:55.260000
 We will not form a neighbor
 relationship in that case.

0:02:55.260000 --> 0:02:56.920000
 The prefix length.

0:02:56.920000 --> 0:02:59.580000
 So this is also a little bit
 different than EI JRP.

0:02:59.580000 --> 0:03:03.940000
 So in EI JRP, let's say I sent
 you an EI JRP hello packet.

0:03:03.940000 --> 0:03:11.340000
 And let's say it was like this.

0:03:11.340000 --> 0:03:15.120000
 So here comes in an
 EI JRP hello packet.

0:03:15.120000 --> 0:03:35.580000
 EI JRP hello. And let's say the source
 of that packet was 1.1.1.1.

0:03:35.580000 --> 0:03:39.140000
 That was the source IP address.

0:03:39.140000 --> 0:03:55.100000
 And the router that's receiving
 that packet on this packet.

0:03:55.100000 --> 0:04:02.280000
 Would he say this source is in
 the same network as himself?

0:04:02.280000 --> 0:04:08.500000
 Hopefully your answer was
 no, because 1.1.1.9.

0:04:08.500000 --> 0:04:10.020000
 That's a host address.

0:04:10.020000 --> 0:04:13.980000
 Because if we're doing the slash 29,
 that means this is a host in the

0:04:13.980000 --> 0:04:16.980000
 1.1.1.8 network.

0:04:16.980000 --> 0:04:20.660000
 1.1.1.8 and 1.1.1.9 is the
 very first host address.

0:04:20.660000 --> 0:04:24.300000
 And 1.1.1.1.1. That's not
 in the same network.

0:04:24.300000 --> 0:04:30.500000
 So this router here, router X, would
 say neighbor not uncommon subnet.

0:04:30.500000 --> 0:04:33.800000
 I'm receiving EI JRP hello, but the neighbor
 is not on the common subnet.

0:04:33.800000 --> 0:04:35.280000
 But what about over here?

0:04:35.280000 --> 0:04:37.940000
 What about router Z?

0:04:37.940000 --> 0:04:50.540000
 What of his address was 1.1.1.1.

0:04:50.540000 --> 0:04:58.020000
 Hello packet sourced from 1.1.1.9.


0:04:58.020000 --> 0:05:03.020000
 Is router Z going to have
 a problem with that?

0:05:03.020000 --> 0:05:08.540000
 No. Router Z is going to say, oh,
 well, I'm in the 1.1.1 network.

0:05:08.540000 --> 0:05:11.560000
 This source is also in
 the 1.1.1 network.

0:05:11.560000 --> 0:05:13.620000
 So he looks good.

0:05:13.620000 --> 0:05:15.900000
 So now we're going to have a problem
 here because router Z is going to

0:05:15.900000 --> 0:05:17.540000
 say, hey, router X, you look good.


0:05:17.540000 --> 0:05:18.580000
 We're good to go.

0:05:18.580000 --> 0:05:21.340000
 Router X is going to say,
 I can't talk to you.

0:05:21.340000 --> 0:05:23.320000
 You're not on the
 same subnet as me.

0:05:23.320000 --> 0:05:27.440000
 So only router X was able to figure
 out this was a problem.

0:05:27.440000 --> 0:05:30.200000
 Router Z did not know
 this is a problem.

0:05:30.200000 --> 0:05:35.040000
 In OSPF, this would be a problem for
 both sides because in their hello

0:05:35.040000 --> 0:05:40.140000
 packets, they actually include
 what their subnet mask is.

0:05:40.140000 --> 0:05:44.300000
 And both sides would see that the other
 side had a different subnet mask.

0:05:44.300000 --> 0:05:45.920000
 Router Z would say, wait a second.


0:05:45.920000 --> 0:05:48.420000
 You're telling me your subnet
 mask is a slash 29.

0:05:48.420000 --> 0:05:49.720000
 That doesn't match me.

0:05:49.720000 --> 0:05:55.140000
 I'm a slash 24. And so in OSPF, that's
 why we say the prefix length has

0:05:55.140000 --> 0:06:00.560000
 to be the same. So it's a bit better at
 discovering these types of problems

0:06:00.560000 --> 0:06:06.280000
 than EIGRP is. And then the last thing
 that has to be the same is something

0:06:06.280000 --> 0:06:08.280000
 called a stub area flag.

0:06:08.280000 --> 0:06:12.700000
 You don't really get into
 that in the world of CCNA.

0:06:12.700000 --> 0:06:16.420000
 But a stub area is basically an area,
 a collection of routers where there's

0:06:16.420000 --> 0:06:19.260000
 only one way in and one way out.

0:06:19.260000 --> 0:06:22.520000
 There's this one area border router,
 and that's the only way out of the

0:06:22.520000 --> 0:06:24.700000
 area and the only
 way into the area.

0:06:24.700000 --> 0:06:28.800000
 In that particular case, you can take
 all the routers in that area and

0:06:28.800000 --> 0:06:32.080000
 configure a special command on their
 saying, you are all part of a stub

0:06:32.080000 --> 0:06:36.920000
 area. And the actual benefit of that
 is that area will not have to learn

0:06:36.920000 --> 0:06:38.220000
 about everything.

0:06:38.220000 --> 0:06:41.820000
 You can reduce the size of the OSPF
 tables when it's a stub area.

0:06:41.820000 --> 0:06:45.200000
 But if you do that, all the routers,
 when they're exchanging their halos,

0:06:45.200000 --> 0:06:47.160000
 have to have a little flag racing.


0:06:47.160000 --> 0:06:49.040000
 I believe this area
 is a stub area.

0:06:49.040000 --> 0:06:51.560000
 They have to agree on that.

0:06:51.560000 --> 0:06:57.760000
 Okay, so let's go back to these different
 types of OSPF packets and how

0:06:57.760000 --> 0:07:02.200000
 they're used. So the first thing step
 number one is we have to exchange

0:07:02.200000 --> 0:07:05.600000
 hello packets. And those things that
 we saw in the previous slide have

0:07:05.600000 --> 0:07:09.520000
 to match. So let's say
 that that is the case.

0:07:09.520000 --> 0:07:11.620000
 So you and I exchange
 hello packets.

0:07:11.620000 --> 0:07:18.000000
 So inside the hello packet, if I was
 actually to draw a hello packet,

0:07:18.000000 --> 0:07:22.920000
 so let's say here's a hello packet,
 there's a field in here where you

0:07:22.920000 --> 0:07:32.240000
 list neighbors. Which means when I send
 you a hello packet, I'm telling

0:07:32.240000 --> 0:07:36.260000
 you, here's all the neighbors I know
 about on this link, on this link

0:07:36.260000 --> 0:07:38.640000
 that you and I share, here's
 all the neighbors.

0:07:38.640000 --> 0:07:42.400000
 Now you might be saying, well, wait
 a second, just you and me, right?

0:07:42.400000 --> 0:07:45.380000
 Why do that? Well, because there
 might be more than one neighbor.

0:07:45.380000 --> 0:07:49.280000
 Imagine this link was connected to
 a switch or a hub in between us.

0:07:49.280000 --> 0:07:53.320000
 And there were five or six routers all
 on the same VLAN, all on the same

0:07:53.320000 --> 0:07:57.460000
 subnet. Well, my hello packet would list
 all the routers that I know about

0:07:57.460000 --> 0:08:00.140000
 that I'm neighbors
 with on this link.

0:08:00.140000 --> 0:08:02.280000
 So what does that have
 to do with this?

0:08:02.280000 --> 0:08:09.280000
 Well, when you type the command show IP
 OSPF neighbor, show IP OSPF neighbor,

0:08:09.280000 --> 0:08:13.680000
 you'll see if you've got any neighbors
 and what state you're in.

0:08:13.680000 --> 0:08:16.820000
 You see an EIGRP is pretty
 much all or nothing.

0:08:16.820000 --> 0:08:20.660000
 When you did show IP EIGRP neighbor,
 you either saw a neighbor or you

0:08:20.660000 --> 0:08:24.100000
 didn't. There was like
 no intermediate steps.

0:08:24.100000 --> 0:08:28.000000
 But in OSPF, there are, and you need to
 know what those steps are in building

0:08:28.000000 --> 0:08:30.060000
 a neighbor relationship.

0:08:30.060000 --> 0:08:40.600000
 So step number one, here comes in a hello,
 and router one is getting that

0:08:40.600000 --> 0:08:44.560000
 hello, and the hello says it's
 coming from router two.

0:08:44.560000 --> 0:08:49.860000
 But in the hello packet itself, router
 one says, huh, okay, I see there's

0:08:49.860000 --> 0:08:51.620000
 a router two here on this link.

0:08:51.620000 --> 0:08:56.360000
 He and I match everything looks good,
 but he doesn't recognize me.

0:08:56.360000 --> 0:09:00.460000
 In other words, in his hello packet,
 I don't see my own name.

0:09:00.460000 --> 0:09:03.180000
 So I don't even know if he's
 gotten my hello yet.

0:09:03.180000 --> 0:09:05.320000
 All I know is that he exists.

0:09:05.320000 --> 0:09:10.580000
 So in this way, router two would be
 in what's called the two ways in the

0:09:10.580000 --> 0:09:19.040000
 init state. In it or the initial,
 it's called the initial state.

0:09:19.040000 --> 0:09:22.660000
 So right, if you did show IP OSPF neighbor
 on router one, you'd see a

0:09:22.660000 --> 0:09:26.360000
 neighbor of R2 and the state would
 be init, meaning initial.

0:09:26.360000 --> 0:09:30.500000
 I received his initial hello, but I
 don't know if he even is aware of

0:09:30.500000 --> 0:09:42.740000
 me yet. Now let's say hello comes in
 from router two, and it says I see

0:09:42.740000 --> 0:09:53.160000
 R1. So now my neighbor relationship
 would change to what's called the

0:09:53.160000 --> 0:10:00.760000
 two-way state. Router one would say,
 okay, I see him, and he sees me.

0:10:00.760000 --> 0:10:04.520000
 He's actually got my name, my router
 ID, inside of his hello packet.

0:10:04.520000 --> 0:10:07.040000
 So that means he must have
 received my hello packet.

0:10:07.040000 --> 0:10:08.300000
 We see each other.

0:10:08.300000 --> 0:10:10.540000
 Now we're at the two-way state.

0:10:10.540000 --> 0:10:14.900000
 So at this point, now the routers recognize
 each other, and things have

0:10:14.900000 --> 0:10:18.380000
 matched. Now time were progressed
 to the next level.

0:10:18.380000 --> 0:10:23.020000
 Now the next step is you and I, router
 one and router two, we have to

0:10:23.020000 --> 0:10:26.180000
 say, what's your LSA
 database look like?

0:10:26.180000 --> 0:10:28.020000
 Do you have the same LSA as me?

0:10:28.020000 --> 0:10:30.860000
 Because if you don't, we
 need to synchronize.

0:10:30.860000 --> 0:10:32.600000
 So that's going to
 be the next step.

0:10:32.600000 --> 0:10:37.420000
 So you might want to, I'm going to
 about to erase these right here.

0:10:37.420000 --> 0:10:40.620000
 So you might want to write
 these down before I do.

0:10:40.620000 --> 0:10:48.860000
 Let's see here, maybe I can fit a little
 bit more on this screen before

0:10:48.860000 --> 0:10:56.960000
 I erase it. Okay, so the next thing
 is router one and router two will

0:10:56.960000 --> 0:10:58.480000
 both send each other.

0:10:58.480000 --> 0:11:03.540000
 Another type of OSPF packet that we looked
 at real briefly called a database

0:11:03.540000 --> 0:11:16.860000
 descriptor. So the primary purpose of
 exchanging these database descriptors

0:11:16.860000 --> 0:11:21.640000
 is to determine, does your LSA
 database look like mine?

0:11:21.640000 --> 0:11:23.200000
 And these are going to be
 exchanged back and forth.

0:11:23.200000 --> 0:11:26.800000
 They give sort of like a view of what
 my database looks like, what your

0:11:26.800000 --> 0:11:28.240000
 database looks like.

0:11:28.240000 --> 0:11:32.040000
 And so now as we're exchanging database
 descriptors, we're going to move

0:11:32.040000 --> 0:11:34.000000
 through two additional states.

0:11:34.000000 --> 0:11:48.200000
 We're going to move through the EX
-START state and the exchange state.

0:11:48.200000 --> 0:11:51.840000
 Exchange, sorry for my sloppy
 handwriting here.

0:11:51.840000 --> 0:12:01.740000
 So we start out at init, then we went
 into two way and remember if I'm

0:12:01.740000 --> 0:12:07.500000
 doing show IPOSPF data, show IPOSPF neighbor,
 I'm going to see these various

0:12:07.500000 --> 0:12:11.160000
 states in the output if I keep doing
 that command over and over again.

0:12:11.160000 --> 0:12:16.080000
 So EX-START and EX-CHANGE means we're
 exchanging these database descriptors,

0:12:16.080000 --> 0:12:19.320000
 trying to discover if our databases
 are the same or not.

0:12:19.320000 --> 0:12:22.280000
 And they probably will
 not be the same.

0:12:22.280000 --> 0:12:25.000000
 So now I have to erase some
 stuff to make some room.

0:12:25.000000 --> 0:12:31.420000
 So after the database descriptors are
 exchanged and we discover that we're

0:12:31.420000 --> 0:12:38.720000
 missing some stuff, that your database
 is not the same as mine, then at

0:12:38.720000 --> 0:12:45.020000
 that point I'm going to say, okay, you've
 got some hello packets, you've

0:12:45.020000 --> 0:12:48.140000
 got some link state advertisements
 that I don't have.

0:12:48.140000 --> 0:12:50.760000
 I would like to have them.

0:12:50.760000 --> 0:13:00.620000
 And so each router might send each other
 link state request packets, saying,

0:13:00.620000 --> 0:13:03.480000
 hey, you've got a link state advertisement
 I don't have, please give it

0:13:03.480000 --> 0:13:08.720000
 to me. And that will be followed
 by a link state update packet.

0:13:08.720000 --> 0:13:15.440000
 So now they're in the process of actually
 making their databases in sync,

0:13:15.440000 --> 0:13:19.060000
 synchronized by you send me some requests
 of what you don't have, I send

0:13:19.060000 --> 0:13:21.100000
 you back some updates.

0:13:21.100000 --> 0:13:25.380000
 I send you some requests of what I don't
 have, you send me back some updates.

0:13:25.380000 --> 0:13:29.600000
 So now we're going to move into a different
 state, which is the loading

0:13:29.600000 --> 0:13:37.340000
 state. So if you issue the command show
 IPOSPF neighbor and it says loading,

0:13:37.340000 --> 0:13:38.700000
 that's what's going on.

0:13:38.700000 --> 0:13:45.680000
 They're and then finally we're going
 to eventually reach a point where

0:13:45.680000 --> 0:13:48.060000
 we realize, hey, we're the same.

0:13:48.060000 --> 0:13:51.360000
 My database has exactly the
 same stuff as your database.

0:13:51.360000 --> 0:13:55.200000
 Now all we have to do is go back to
 exchanging periodic hello packets.

0:13:55.200000 --> 0:14:00.560000
 And that's it. And now you'll finally
 be in what's called the full state,

0:14:00.560000 --> 0:14:04.020000
 which means we are fully adjacent.


0:14:04.020000 --> 0:14:05.340000
 We are fully loaded.

0:14:05.340000 --> 0:14:06.880000
 Everything is fully synchronized.

0:14:06.880000 --> 0:14:12.260000
 So that's the series of steps that two
 routers or two OSPF devices will

0:14:12.260000 --> 0:14:18.700000
 move through to finally become fully
 adjacent and knit two way EX-start

0:14:18.700000 --> 0:14:23.560000
 exchange loading and full.

0:14:23.560000 --> 0:14:27.480000
 And so now we've talked about where
 those various packet types are used

0:14:27.480000 --> 0:14:32.340000
 in the process of building
 an OSPF relationship.

