1
00:00:02,579 --> 00:00:07,242
(epic electronic music)

2
00:00:08,875 --> 00:00:12,444
- So we're gonna leave the
world of EIGRP behind us,

3
00:00:12,444 --> 00:00:14,053
and at this point we're
now gonna move into

4
00:00:14,053 --> 00:00:16,315
another Interior Gateway Routing Protocol,

5
00:00:16,315 --> 00:00:19,452
which is Open Shortest Path First,

6
00:00:19,452 --> 00:00:21,721
otherwise known as OSPF.

7
00:00:21,721 --> 00:00:24,597
So let's just do a quick
introduction to OSPF.

8
00:00:27,560 --> 00:00:31,364
First thing is, is that
OSPF is and always has been

9
00:00:31,364 --> 00:00:32,365
an open standard.

10
00:00:32,365 --> 00:00:35,201
There actually is an RFC
for it, if you wanna google

11
00:00:35,201 --> 00:00:37,303
the RFC for OSPF.

12
00:00:37,303 --> 00:00:40,106
But it's not owned by any
company, it's not proprietary.

13
00:00:40,106 --> 00:00:42,838
It's always been an open standard.

14
00:00:42,838 --> 00:00:44,878
It's actually very, very old as well.

15
00:00:44,878 --> 00:00:48,131
It's been around for several
decades at this point.

16
00:00:49,682 --> 00:00:51,117
So OSPF uses something called

17
00:00:51,117 --> 00:00:54,120
the shortest path first algorithm.

18
00:00:54,120 --> 00:00:55,121
What does that mean?

19
00:00:55,121 --> 00:00:59,225
Well, unlike EIGRP,
which is what we classify

20
00:00:59,225 --> 00:01:02,629
as an advanced distance vector protocol,

21
00:01:02,629 --> 00:01:06,232
OSPF falls into a different
category called a link state

22
00:01:06,232 --> 00:01:07,534
routing protocol.

23
00:01:07,534 --> 00:01:09,536
One of the big difference
between the two of them

24
00:01:09,536 --> 00:01:13,106
is that a distance vector or advanced

25
00:01:13,106 --> 00:01:15,875
distance vector protocol,
all it knows about as far as

26
00:01:15,875 --> 00:01:18,344
the topology is concerned is itself

27
00:01:18,344 --> 00:01:21,881
and its directly connected
neighbors and that's it.

28
00:01:21,881 --> 00:01:23,883
So if you and I are
running a distance vector

29
00:01:23,883 --> 00:01:26,286
routing protocol, I will
tell you about all the routes

30
00:01:26,286 --> 00:01:29,722
I know about so you know
that to get to those routes,

31
00:01:29,722 --> 00:01:31,357
you go through me.

32
00:01:31,357 --> 00:01:34,427
So you know those routes
live back here somewhere,

33
00:01:34,427 --> 00:01:37,597
but you don't know what the
topology looks like back here.

34
00:01:37,597 --> 00:01:40,233
You have no idea what
is connected to what,

35
00:01:40,233 --> 00:01:42,775
what the links look like, no idea.

36
00:01:42,775 --> 00:01:45,014
Whereas in a link state routing protocol,

37
00:01:45,014 --> 00:01:46,806
you actually know the entire topology,

38
00:01:46,806 --> 00:01:49,709
not just you and your
directly connected neighbors

39
00:01:49,709 --> 00:01:51,144
but everything.

40
00:01:51,144 --> 00:01:54,714
You can form like a map in
your own mind as to where

41
00:01:54,714 --> 00:01:57,383
all the routers are, where the subnets sit

42
00:01:57,383 --> 00:02:00,753
on each one of those routers
and you can piece it together.

43
00:02:00,753 --> 00:02:04,190
So the shortest path first
algorithm takes place

44
00:02:04,190 --> 00:02:06,426
after you've built that map in your mind.

45
00:02:06,426 --> 00:02:08,561
It's sort of like spanning
tree, where you're like

46
00:02:08,561 --> 00:02:11,030
the root of the tree and
everything branches out from you.

47
00:02:11,030 --> 00:02:13,500
In the shortest path first algorithm,

48
00:02:13,500 --> 00:02:15,502
you build this tree
and then you figure out

49
00:02:15,502 --> 00:02:18,438
from your perspective as you
at the center of the universe,

50
00:02:18,438 --> 00:02:21,674
what the shortest path is
to any given destination.

51
00:02:21,674 --> 00:02:23,243
That's the SPF algorithm.

52
00:02:25,133 --> 00:02:29,609
Like EIGRP, OSPF utilizes
hello packets to dynamically

53
00:02:29,609 --> 00:02:34,254
discover and build OSPF
neighbor relationships.

54
00:02:34,254 --> 00:02:37,323
In the case of OSPF, we
actually call them adjacencies,

55
00:02:37,323 --> 00:02:38,691
OSPF adjacencies.

56
00:02:38,691 --> 00:02:41,394
So I'll use those terms
interchangeably, neighborship,

57
00:02:41,394 --> 00:02:43,830
adjacency meaning
basically the same thing.

58
00:02:46,380 --> 00:02:49,269
Like EIGRP, where the vast
majority of EIGRP packets

59
00:02:49,269 --> 00:02:54,107
went to a multicast
address, most OSPF packets

60
00:02:54,107 --> 00:02:56,109
also go to multicast addresses.

61
00:02:56,109 --> 00:02:58,344
As a matter of fact,
OSPF has two addresses

62
00:02:58,344 --> 00:03:00,795
that are reserved just for itself,

63
00:03:00,795 --> 00:03:05,228
224.0.0.5 and 224.0.0.6.

64
00:03:06,269 --> 00:03:10,843
OSPF hello packets always go to 224.0.0.5.

65
00:03:11,803 --> 00:03:15,028
The other packets that we're
gonna talk about with OSPF

66
00:03:15,028 --> 00:03:18,031
may go to .5 or they may go to .6.

67
00:03:18,031 --> 00:03:19,776
When we get a little bit further into this

68
00:03:19,776 --> 00:03:21,676
and I talk about this
concept of something called

69
00:03:21,676 --> 00:03:25,556
designated routers and
backup designated routers,

70
00:03:25,556 --> 00:03:27,640
the idea between these
two different addresses

71
00:03:27,640 --> 00:03:30,445
will make a little bit more sense.

72
00:03:31,487 --> 00:03:34,564
OSPF also works based
on an area hierarchy,

73
00:03:34,564 --> 00:03:36,385
minimizing LSA flooding.

74
00:03:36,385 --> 00:03:37,821
What does that talk about?

75
00:03:37,821 --> 00:03:41,282
Because we haven't talked
about areas or LSAs yet.

76
00:03:41,282 --> 00:03:43,189
Let's hold off on that
bullet for just a minute.

77
00:03:43,189 --> 00:03:45,491
The very next slide is
gonna go into a little bit

78
00:03:45,491 --> 00:03:49,195
more detail of what that
acronym, LSA, means.

79
00:03:49,195 --> 00:03:52,432
And once I talk about LSAs,
then I'll be able to give you

80
00:03:52,432 --> 00:03:55,168
a better understanding
of what an OSPF area is

81
00:03:55,168 --> 00:03:59,278
and why you might want more than one area.

82
00:04:00,640 --> 00:04:02,642
And like pretty much all
the routing protocols

83
00:04:02,642 --> 00:04:06,846
that utilize neighbors, OSPF
has the optional capability

84
00:04:06,846 --> 00:04:09,849
of supporting authentication,
both clear-text

85
00:04:09,849 --> 00:04:12,919
and MD5 authentication.

86
00:04:12,919 --> 00:04:17,322
Okay, so the real heart and soul of OSPF

87
00:04:17,322 --> 00:04:20,726
are these things called
Link State Advertisements.

88
00:04:20,726 --> 00:04:21,728
What is that?

89
00:04:21,728 --> 00:04:24,297
Okay, first of all, remember that in OSPF,

90
00:04:24,297 --> 00:04:27,533
we call this a link
state routing protocol.

91
00:04:27,533 --> 00:04:30,470
In other words, if I'm a
router and this is what

92
00:04:30,470 --> 00:04:32,472
I would normally call an interface,

93
00:04:32,472 --> 00:04:36,909
interface fast Ethernet
00 or interface serial 00,

94
00:04:36,909 --> 00:04:41,909
OSPF calls that a link,
not an interface, a link.

95
00:04:41,981 --> 00:04:45,284
Technically speaking,
everything that has a subnet

96
00:04:45,284 --> 00:04:46,719
would be considered a link.

97
00:04:46,719 --> 00:04:50,890
So if I have a
sub-interface, that's a link.

98
00:04:50,890 --> 00:04:53,726
If I have a physical interface
that has two or three

99
00:04:53,726 --> 00:04:57,030
subnets on it, that would be
categorized as two or three

100
00:04:57,030 --> 00:05:00,967
separate links, even though
it's on one physical interface.

101
00:05:00,967 --> 00:05:03,236
So it's a link we're talking about.

102
00:05:03,236 --> 00:05:06,272
The next thing is, as an
OSPF router, if I'm directly

103
00:05:06,272 --> 00:05:08,274
connected to this interface right here,

104
00:05:08,274 --> 00:05:10,276
let's say it's fast Ethernet one,

105
00:05:10,276 --> 00:05:12,912
then it's my responsibility
to create a special type

106
00:05:12,912 --> 00:05:17,316
of a packet called a Link
State Update packet, an LSU.

107
00:05:17,316 --> 00:05:19,308
I'll go ahead and write that on here.

108
00:05:20,628 --> 00:05:25,097
LSU, which stands for Link State Update.

109
00:05:26,225 --> 00:05:28,695
And within that Link State Update packet,

110
00:05:28,695 --> 00:05:33,567
I will pack in there one or
more Link State Advertisements.

111
00:05:35,034 --> 00:05:37,970
So an LSU packet, think
of that as being like,

112
00:05:37,970 --> 00:05:40,973
in EIGRP terminology, an EIGRP update.

113
00:05:40,973 --> 00:05:45,011
An EIGRP update contains one
or more networks inside of it,

114
00:05:45,011 --> 00:05:48,314
one or more prefixes that,
that update is carrying.

115
00:05:48,314 --> 00:05:53,252
Similarly, an OSPF Link State
Update contains one or more

116
00:05:53,252 --> 00:05:55,188
LSAs inside of it.

117
00:05:55,188 --> 00:05:57,943
Now what exactly is an LSA?

118
00:05:57,943 --> 00:06:01,527
Okay, so let's say I need
to advertise information

119
00:06:01,527 --> 00:06:05,965
about this link to all of
the other OSPF routers.

120
00:06:05,965 --> 00:06:08,367
Well, I'm gonna create, inside my LSU,

121
00:06:08,367 --> 00:06:10,903
I'm gonna create a data structure called

122
00:06:10,903 --> 00:06:12,739
a Link State Advertisement.

123
00:06:12,739 --> 00:06:14,741
And that Link State
Advertisement is gonna give you

124
00:06:14,741 --> 00:06:18,344
everything you need to
know about this link.

125
00:06:18,344 --> 00:06:20,346
Now before I go into the details of that,

126
00:06:20,346 --> 00:06:22,348
here's the main thing I
want you to think about.

127
00:06:22,348 --> 00:06:26,986
Number one, the overall
goal or objective of OSPF

128
00:06:26,986 --> 00:06:30,723
is to build this topology map in its mind.

129
00:06:30,723 --> 00:06:34,393
It wants to build this tree
of what the entire topology

130
00:06:34,393 --> 00:06:36,629
looks like, who's connected to who,

131
00:06:36,629 --> 00:06:40,366
who they're connected to,
that's its overall objective.

132
00:06:40,366 --> 00:06:42,368
So imagine, just close
your eyes for a second,

133
00:06:42,368 --> 00:06:44,704
imagine a whole bunch of circles
and you're starting to draw

134
00:06:44,704 --> 00:06:46,806
lines between those
circles and you're building

135
00:06:46,806 --> 00:06:49,408
a tree-like structure,
interconnecting these circles,

136
00:06:49,408 --> 00:06:51,611
and the circles are representing routers

137
00:06:51,611 --> 00:06:53,780
and the lines are representing
links connecting them.

138
00:06:53,780 --> 00:06:55,815
So you're building that.

139
00:06:55,815 --> 00:06:58,918
And then as you build that,
imagine you start sort of

140
00:06:58,918 --> 00:07:02,255
writing in the various
subnets where they live

141
00:07:02,255 --> 00:07:03,689
on top of the links.

142
00:07:03,689 --> 00:07:05,691
That's sort of your secondary objective,

143
00:07:05,691 --> 00:07:07,693
is to figure out where the subnets are.

144
00:07:07,693 --> 00:07:10,463
But your primary objective
is to build this tree,

145
00:07:10,463 --> 00:07:13,132
build this SPF tree.

146
00:07:13,132 --> 00:07:16,235
Okay, so the Link State Advertisement,

147
00:07:16,235 --> 00:07:18,805
that's its main job, is
to help you figure out

148
00:07:18,805 --> 00:07:19,806
this topology.

149
00:07:19,806 --> 00:07:22,775
So as such, when I create
this Link State Advertisement

150
00:07:22,775 --> 00:07:26,445
describing fast Ethernet
one, I'm gonna tell you

151
00:07:26,445 --> 00:07:30,183
a whole lot more than just
what subnet lives here.

152
00:07:30,183 --> 00:07:32,585
You see, if I was a distance
vector routing protocol,

153
00:07:32,585 --> 00:07:34,587
that's all you'd care
about, is what subnets

154
00:07:34,587 --> 00:07:35,588
I'm connected to.

155
00:07:35,588 --> 00:07:37,623
You could care less about anything else.

156
00:07:37,623 --> 00:07:40,059
In a Link State
Advertisement, I'm gonna say

157
00:07:40,059 --> 00:07:42,328
this is a broadcast link.

158
00:07:42,328 --> 00:07:45,565
This link has a certain bandwidth.

159
00:07:45,565 --> 00:07:48,401
Let me tell you about all the
neighbors I'm connected to

160
00:07:48,401 --> 00:07:49,602
on this link.

161
00:07:49,602 --> 00:07:52,004
Oh, let me also tell you about the subnet

162
00:07:52,004 --> 00:07:53,306
on this link as well.

163
00:07:53,306 --> 00:07:56,175
I'll actually tell you all
sorts of descriptive information

164
00:07:56,175 --> 00:07:58,978
about this link in my LSA.

165
00:07:59,828 --> 00:08:02,415
And now, here's another big difference.

166
00:08:02,415 --> 00:08:05,852
In the world EIGRP, let's
do some contrasting here.

167
00:08:05,852 --> 00:08:07,854
Let's say that you and I
are two routers connected

168
00:08:07,854 --> 00:08:11,724
via EIGRP, and behind you you have another

169
00:08:11,724 --> 00:08:14,460
EIGRP relationship with
someone behind you.

170
00:08:14,460 --> 00:08:17,129
So I send you an EIGRP update.

171
00:08:17,129 --> 00:08:20,266
In my EIGRP update, I say
hey, my name is Router Keith,

172
00:08:20,266 --> 00:08:22,935
that's my router ID, and
here's a bunch of networks

173
00:08:22,935 --> 00:08:25,771
you can get through me to reach.

174
00:08:25,771 --> 00:08:27,773
Okay, now what do you do?

175
00:08:27,773 --> 00:08:29,876
When you turn around
and send an EIGRP update

176
00:08:29,876 --> 00:08:33,846
to your neighbor, do you
tell your neighbor about me?

177
00:08:33,846 --> 00:08:36,616
About my router ID and that these networks

178
00:08:36,616 --> 00:08:38,784
you learned from me?

179
00:08:38,784 --> 00:08:40,486
No, you don't.

180
00:08:40,486 --> 00:08:42,221
Let's say your name is Sally.

181
00:08:42,221 --> 00:08:44,423
Well, when you turn around
and you send an EIGRP update

182
00:08:44,423 --> 00:08:47,159
to your neighbor, all you say
is you copy those networks

183
00:08:47,159 --> 00:08:50,663
I gave you and you say, hey,
my name's Sally, neighbor.

184
00:08:50,663 --> 00:08:53,833
And I'm Sally, and here's
the networks I know about.

185
00:08:53,833 --> 00:08:56,502
So your neighbor knows about
the networks are reachable

186
00:08:56,502 --> 00:08:59,872
through you, but your neighbor has no idea

187
00:08:59,872 --> 00:09:02,475
that I'm the one who actually
told you about those networks.

188
00:09:02,475 --> 00:09:06,879
And similarly, you have
no idea about who told me

189
00:09:06,879 --> 00:09:08,948
about those networks.

190
00:09:08,948 --> 00:09:11,550
Well, an OSPF is just the opposite.

191
00:09:11,550 --> 00:09:14,353
If I create a Link State
Advertisement and I package

192
00:09:14,353 --> 00:09:16,489
one or more of those inside an LSU,

193
00:09:16,489 --> 00:09:20,626
a Link State Update packet,
and I multicast it to you,

194
00:09:20,626 --> 00:09:24,030
you take that Link State
Advertisement and stick it

195
00:09:24,030 --> 00:09:27,166
in a database, you store
it, and then you keep

196
00:09:27,166 --> 00:09:28,634
right on flooding it.

197
00:09:28,634 --> 00:09:30,636
You don't change anything about it.

198
00:09:30,636 --> 00:09:33,940
So even if there's nine
or 10 routers behind you,

199
00:09:33,940 --> 00:09:36,475
they will all know about me.

200
00:09:36,475 --> 00:09:38,110
They will know about my name,

201
00:09:38,110 --> 00:09:40,646
they will know that I'm the
one that created this LSA,

202
00:09:40,646 --> 00:09:42,648
that I'm the one who owns this link.

203
00:09:42,648 --> 00:09:44,684
So they would be able to, in their mind,

204
00:09:44,684 --> 00:09:46,919
as they're putting their
jigsaw puzzle together,

205
00:09:46,919 --> 00:09:50,656
they will know that I
exist and where I sit,

206
00:09:50,656 --> 00:09:52,658
and they'll know that I'm connected to you

207
00:09:52,658 --> 00:09:54,157
and that you and I are
neighbors and I'm neighbors

208
00:09:54,157 --> 00:09:55,661
with some other people here.

209
00:09:55,661 --> 00:09:59,065
So the LSA gets flooded
to all these other routers

210
00:09:59,065 --> 00:10:02,182
and that's how they build
this topology diagram.

211
00:10:06,505 --> 00:10:09,976
So an LSA is carried within
a Link State Update packet,

212
00:10:09,976 --> 00:10:12,945
and different types of
LSAs carry different data.

213
00:10:12,945 --> 00:10:15,514
So this is another important ingredient.

214
00:10:15,514 --> 00:10:17,984
So at the CCNA level,

215
00:10:17,984 --> 00:10:20,419
they don't really expect
you to know the details

216
00:10:20,419 --> 00:10:24,757
of what exactly an LSA is and
that there's different kinds,

217
00:10:24,757 --> 00:10:27,793
and what the names of
those different kinds are

218
00:10:27,793 --> 00:10:30,329
and what different purposes they serve.

219
00:10:30,329 --> 00:10:33,566
But you sort of get the
idea here that there are

220
00:10:33,566 --> 00:10:36,502
different kinds of LSAs,
and they do different things

221
00:10:36,502 --> 00:10:40,581
depending on where a router
sits in the topology.

222
00:10:43,142 --> 00:10:46,145
And LSAs age out after
one hour and are refreshed

223
00:10:46,145 --> 00:10:47,680
every 30 minutes.

224
00:10:47,680 --> 00:10:50,750
So what that means is
that this LSA I created

225
00:10:50,750 --> 00:10:53,386
describing this link,
when I flooded it to you

226
00:10:53,386 --> 00:10:56,255
and then it got flooded to all
the other people out there,

227
00:10:56,255 --> 00:11:00,026
well, you and I are
exchanging hello packets

228
00:11:00,026 --> 00:11:01,660
just like in EIGRP.

229
00:11:01,660 --> 00:11:03,662
You and I are exchanging
hello packets and that's how

230
00:11:03,662 --> 00:11:06,899
you know I still exist, that
I'm still a valid neighbor,

231
00:11:06,899 --> 00:11:08,200
because every few seconds,

232
00:11:08,200 --> 00:11:10,236
you're getting a hello packet from me.

233
00:11:10,236 --> 00:11:13,806
Now if we were doing EIGRP,
once I sent you an EIGRP update

234
00:11:13,806 --> 00:11:17,410
with some networks in it,
you might never see an update

235
00:11:17,410 --> 00:11:18,778
form me ever again.

236
00:11:18,778 --> 00:11:21,213
I might never tell you about
those networks for an hour,

237
00:11:21,213 --> 00:11:22,648
a week, six months.

238
00:11:22,648 --> 00:11:25,084
Hey, as long as you and
I are still exchanging

239
00:11:25,084 --> 00:11:28,621
hello packets, you say
hey, Keith still exists.

240
00:11:28,621 --> 00:11:30,623
So that routing update that Keith sent me

241
00:11:30,623 --> 00:11:34,060
about the 75 75 network three months ago

242
00:11:34,060 --> 00:11:36,629
must still be there
because he hasn't told me

243
00:11:36,629 --> 00:11:38,164
it's not there.

244
00:11:38,164 --> 00:11:41,367
OSPF takes a different
approach because remember,

245
00:11:41,367 --> 00:11:44,804
that LSA that I flooded
to you also was flooded

246
00:11:44,804 --> 00:11:47,173
to all the people behind you.

247
00:11:47,173 --> 00:11:49,475
So yeah, it might be well
and good for you and I

248
00:11:49,475 --> 00:11:51,844
to exchange hellos and
you know that I'm here,

249
00:11:51,844 --> 00:11:54,947
but how do they know I'm here?

250
00:11:54,947 --> 00:11:58,017
I'm not sending hello packets
to the people behind you.

251
00:11:58,017 --> 00:12:00,319
I don't have a neighbor
relationship with them.

252
00:12:00,319 --> 00:12:01,854
I have it with you.

253
00:12:01,854 --> 00:12:04,390
So at some point in time,
the people behind you

254
00:12:04,390 --> 00:12:07,226
might be saying, uh, it's
been a while since we got

255
00:12:07,226 --> 00:12:10,329
some LSA from some guy
out there named Keith.

256
00:12:10,329 --> 00:12:11,730
Is he still alive?

257
00:12:11,730 --> 00:12:14,300
Is he actually still reachable?

258
00:12:14,300 --> 00:12:18,304
So in OSPF, we say
well, when LSA goes out,

259
00:12:18,304 --> 00:12:20,306
there's a timer associated with it.

260
00:12:20,306 --> 00:12:23,342
If you don't get that LSA
refreshed one hour later,

261
00:12:23,342 --> 00:12:25,478
it purges from your database.

262
00:12:25,478 --> 00:12:26,479
You delete it.

263
00:12:26,479 --> 00:12:28,481
You say okay, it's been an hour,

264
00:12:28,481 --> 00:12:30,483
haven't heard from that
guy, he must be gone.

265
00:12:30,483 --> 00:12:31,650
I'll delete the LSA.

266
00:12:31,650 --> 00:12:35,721
So as the owner of the LSAs,
the person who actually

267
00:12:35,721 --> 00:12:39,925
created it, it's my
responsibility every 30 minutes

268
00:12:39,925 --> 00:12:41,760
to refresh that LSA.

269
00:12:41,760 --> 00:12:44,363
So I will reflood it every 30 minutes.

270
00:12:46,103 --> 00:12:48,467
Okay, so now let's go
back to what we were just

271
00:12:48,467 --> 00:12:51,504
talking about, this slide right here,

272
00:12:51,504 --> 00:12:54,473
and I wanna pay some
special attention to works

273
00:12:54,473 --> 00:12:58,811
on an area hierarchy to
minimize LSA flooding.

274
00:12:58,811 --> 00:13:03,582
And this will hopefully make
a little bit more sense now.

275
00:13:03,582 --> 00:13:06,852
So let's look at this
topology diagram right here.

276
00:13:09,362 --> 00:13:12,759
There's a lot of rules
that go along with OSPF,

277
00:13:12,759 --> 00:13:15,457
and this is why some people
don't like OSPF because

278
00:13:15,457 --> 00:13:17,701
there's a lot of rules to
remember about what it can do

279
00:13:17,701 --> 00:13:21,030
and what it can't do and
what one router's job is

280
00:13:21,030 --> 00:13:22,859
versus what another router's job is.

281
00:13:22,859 --> 00:13:26,798
So I'm gonna give you one
of the rules right now.

282
00:13:26,798 --> 00:13:29,636
So one of the rules states that

283
00:13:31,638 --> 00:13:36,638
if you ever receive an LSA
describing that something

284
00:13:36,782 --> 00:13:39,485
in the tree has changed, right,

285
00:13:39,485 --> 00:13:42,488
so imagine for a moment
you're an OSPF router,

286
00:13:42,488 --> 00:13:44,490
you've had some neighbor
relationships going now

287
00:13:44,490 --> 00:13:47,226
for several hours or several
days, everything's been nice

288
00:13:47,226 --> 00:13:49,395
and steady, you're
exchanging hello packets

289
00:13:49,395 --> 00:13:52,331
every few seconds and
you've built this nice tree,

290
00:13:52,331 --> 00:13:54,466
you know where everybody is,
where everybody's sitting,

291
00:13:54,466 --> 00:13:56,468
and you've got this
nice tree in your mind.

292
00:13:56,468 --> 00:13:58,604
Now, all of a sudden,
boop, here comes in an LSA

293
00:13:58,604 --> 00:14:00,973
from some other router out there who says,

294
00:14:00,973 --> 00:14:03,075
there's a new link in the tree,

295
00:14:03,075 --> 00:14:07,646
or who says an existing link
has changed, has gone down.

296
00:14:07,646 --> 00:14:10,249
The rule of OSPF states
that when that happens,

297
00:14:10,249 --> 00:14:13,419
you have to take that nice
tree and rip it apart.

298
00:14:13,419 --> 00:14:16,188
It's like taking your jigsaw
puzzle and ripping it apart

299
00:14:16,188 --> 00:14:18,857
and then build it all back together again,

300
00:14:18,857 --> 00:14:21,496
accounting for that new LSA.

301
00:14:21,496 --> 00:14:22,962
Now that's an important point.

302
00:14:22,962 --> 00:14:24,797
Here's why.

303
00:14:24,797 --> 00:14:29,797
This process of building a
tree is very CPU intensive.

304
00:14:29,935 --> 00:14:32,471
It takes the brain of
the router a lot of power

305
00:14:32,471 --> 00:14:36,942
to put all these LSAs together
to see who connects with who

306
00:14:36,942 --> 00:14:39,712
and to eventually build
this map of that topology

307
00:14:39,712 --> 00:14:40,946
in its mind.

308
00:14:40,946 --> 00:14:43,415
So every time an LSA
come in and says oh, man

309
00:14:43,415 --> 00:14:45,985
I gotta rip apart my
tree and now rebuild it

310
00:14:45,985 --> 00:14:48,220
with this one new jigsaw puzzle;

311
00:14:48,220 --> 00:14:51,123
or if an LSA comes in and
says this branch is gone,

312
00:14:51,123 --> 00:14:52,391
this link is gone,

313
00:14:52,391 --> 00:14:54,793
oh, I gotta rip apart my
tree and I'll rebuild it

314
00:14:54,793 --> 00:14:56,595
and exclude that branch.

315
00:14:56,595 --> 00:14:58,664
That takes a lot of processing power

316
00:14:58,664 --> 00:15:00,515
for the router to do that.

317
00:15:00,515 --> 00:15:02,868
So imagine for a moment that we're looking

318
00:15:02,868 --> 00:15:05,771
at this topology right
here, and let's say that

319
00:15:05,771 --> 00:15:10,502
there's some link in this
topology that is not very stable.

320
00:15:11,577 --> 00:15:14,636
Maybe it's this link right here, okay?

321
00:15:15,547 --> 00:15:17,216
So that link is flapping.

322
00:15:17,216 --> 00:15:20,286
For whatever reason, it's
going down and it's coming up.

323
00:15:20,286 --> 00:15:22,221
Going down, coming up.

324
00:15:22,221 --> 00:15:24,757
Well, every time that happens,

325
00:15:24,757 --> 00:15:27,226
these two routers here,
router four and Switch 3,

326
00:15:27,226 --> 00:15:31,997
are creating new LSAs
about a link down condition

327
00:15:31,997 --> 00:15:34,033
or a new link coming up condition,

328
00:15:34,033 --> 00:15:39,033
which means those LSAs are being
flooded all over the place.

329
00:15:39,071 --> 00:15:41,607
And so every time that happens,

330
00:15:41,607 --> 00:15:44,476
all these devices are having
to tear down their tree,

331
00:15:44,476 --> 00:15:47,800
rebuild it, tear down
their tree, rebuild it.

332
00:15:49,515 --> 00:15:53,289
So in OSPF, when you configure OSPF,

333
00:15:54,353 --> 00:15:57,756
you're gonna start by doing router OSPF,

334
00:16:01,293 --> 00:16:03,329
and then you're gonna
give it some process ID.

335
00:16:03,329 --> 00:16:05,497
And I'll talk more about
the process ID coming up

336
00:16:05,497 --> 00:16:07,032
in another video.

337
00:16:07,032 --> 00:16:10,536
And then like EIGRP, you're
gonna have some sort of

338
00:16:10,536 --> 00:16:12,358
network command.

339
00:16:13,539 --> 00:16:16,375
And let's just take
Switch 3 as an example.

340
00:16:16,375 --> 00:16:18,677
I'll have a network command
to cover this network,

341
00:16:18,677 --> 00:16:20,679
this network and this network.

342
00:16:21,799 --> 00:16:26,352
But unlike EIGRP, every link in OSPF

343
00:16:26,352 --> 00:16:29,701
is considered to be part of an area.

344
00:16:30,956 --> 00:16:32,958
Let's start real quickly and just say that

345
00:16:32,958 --> 00:16:36,261
well, we're gonna have all
these links in this entire

346
00:16:36,261 --> 00:16:39,926
topology be in one giant area.

347
00:16:41,033 --> 00:16:44,169
Now an area like an
autonomous system number

348
00:16:44,169 --> 00:16:46,605
has a number, has a value.

349
00:16:46,605 --> 00:16:50,642
If I'm having my entire
topology in just one area,

350
00:16:50,642 --> 00:16:53,145
that area can be whatever I want.

351
00:16:53,145 --> 00:16:55,715
Well, maybe we'll say Area 8.

352
00:16:58,117 --> 00:17:02,807
So in Switch 3 here,
I'd have network 2.3.2

353
00:17:02,807 --> 00:17:06,759
in Area 8; network 3.3.3 in Area 8;

354
00:17:06,759 --> 00:17:09,494
network 3.4.3 in Area 8.

355
00:17:09,494 --> 00:17:11,696
And I would be enabling
OSPF on these links

356
00:17:11,696 --> 00:17:14,199
so we could start speaking about it.

357
00:17:14,199 --> 00:17:15,601
So you can do that.

358
00:17:15,601 --> 00:17:18,170
You can have every link
in your entire topology

359
00:17:18,170 --> 00:17:20,105
in one giant area.

360
00:17:20,105 --> 00:17:22,107
Now Cisco recommends, there's actually

361
00:17:22,107 --> 00:17:24,108
a design recommendation that
says you should have no more

362
00:17:24,108 --> 00:17:28,561
than about 40 or 50 routers
total in any one given area.

363
00:17:29,815 --> 00:17:31,784
So right now, this is easy, right?

364
00:17:31,784 --> 00:17:33,786
So I've got one, two, three,
four, five, six, seven.

365
00:17:33,786 --> 00:17:36,757
I've got about seven devices, no problem.

366
00:17:37,656 --> 00:17:39,525
Here's the problem though,

367
00:17:39,525 --> 00:17:41,451
or the potential problem.

368
00:17:42,428 --> 00:17:47,428
Within an area, everybody has
to know the entire topology

369
00:17:47,566 --> 00:17:49,301
of that area.

370
00:17:49,301 --> 00:17:51,503
And everybody's database that's storing

371
00:17:51,503 --> 00:17:55,874
the Link State Advertisements
has to be the same.

372
00:17:55,874 --> 00:17:57,843
And this is another rule of OSPF.

373
00:17:57,843 --> 00:18:00,679
If you and I are OSPF neighbors

374
00:18:00,679 --> 00:18:03,582
and we are what's called fully adjacent,

375
00:18:03,582 --> 00:18:07,953
what that means is that all
the LSAs I have in my database,

376
00:18:07,953 --> 00:18:09,521
you have to have them.

377
00:18:09,521 --> 00:18:12,691
And whatever you have in your
database, I have to have them.

378
00:18:12,691 --> 00:18:14,893
Our databases have to be synchronized.

379
00:18:14,893 --> 00:18:16,962
They have to look identical.

380
00:18:16,962 --> 00:18:19,031
So in this particular topology here,

381
00:18:19,031 --> 00:18:21,900
all seven of these devices
would have their own LSAs

382
00:18:21,900 --> 00:18:24,536
that they've created, as well as the LSAs

383
00:18:24,536 --> 00:18:26,805
of all the other devices in here.

384
00:18:26,805 --> 00:18:29,074
So even in this small
topologies we see here,

385
00:18:29,074 --> 00:18:31,310
that'd be a fair amount of LSAs.

386
00:18:31,310 --> 00:18:34,112
We've got one, two, three,
four, five, six, seven.

387
00:18:34,112 --> 00:18:36,982
We've got about eight links.

388
00:18:36,982 --> 00:18:39,651
So we have several LSAs.

389
00:18:39,651 --> 00:18:41,787
So all seven of these
devices, if you looked in any

390
00:18:41,787 --> 00:18:44,923
one of them, their link state
database would be identical.

391
00:18:44,923 --> 00:18:46,925
They'd all have exactly the same LSAs.

392
00:18:46,925 --> 00:18:51,396
And this is the reason
why if a new LSA comes in,

393
00:18:51,396 --> 00:18:53,432
everybody's got to add
it to their database

394
00:18:53,432 --> 00:18:55,834
because they're synchronized,
and they have to tear apart

395
00:18:55,834 --> 00:18:58,136
their tree and rebuild it.

396
00:18:58,136 --> 00:19:00,138
And then if another LSA comes in,

397
00:19:00,138 --> 00:19:02,975
synchronizing it to the
database, tear apart their tree,

398
00:19:02,975 --> 00:19:05,296
rebuild it.

399
00:19:05,296 --> 00:19:08,280
Well, if my topology is fairly stable,

400
00:19:08,280 --> 00:19:10,449
I don't really have to worry about that.

401
00:19:10,449 --> 00:19:12,451
It's that environment
I talked about earlier

402
00:19:12,451 --> 00:19:14,753
where I said hey, a link is
flapping and now it's causing

403
00:19:14,753 --> 00:19:17,022
the CPUs of my routers to get pretty high

404
00:19:17,022 --> 00:19:19,024
because they have to keep having that

405
00:19:19,024 --> 00:19:20,452
tear apart their topology and rebuild it

406
00:19:20,452 --> 00:19:22,027
over and over again.

407
00:19:22,027 --> 00:19:25,964
So OSPF, the designer,
said we're gonna give you

408
00:19:25,964 --> 00:19:30,357
a way to avoid unnecessary
CPU computations

409
00:19:31,236 --> 00:19:33,205
in that type of topology.

410
00:19:33,205 --> 00:19:36,086
Here's what we're gonna do.

411
00:19:36,086 --> 00:19:39,550
What you can do is you
can take your topology,

412
00:19:39,550 --> 00:19:42,915
and instead of putting
all of it in one area,

413
00:19:42,915 --> 00:19:45,217
you can divide up into multiple areas.

414
00:19:45,217 --> 00:19:47,252
So for example,

415
00:19:47,252 --> 00:19:50,656
I could say that all of these links here

416
00:19:50,656 --> 00:19:52,753
are in Area 8,

417
00:19:53,625 --> 00:19:56,142
and all of these links

418
00:19:57,262 --> 00:19:59,197
are in another area.

419
00:19:59,197 --> 00:20:02,701
Now the rule of OSPF, here's
another rule, third rule,

420
00:20:02,701 --> 00:20:07,506
the rule of OSPF says if
you have two or more areas,

421
00:20:07,506 --> 00:20:10,837
one of them has to be the backbone area.

422
00:20:12,110 --> 00:20:13,978
The backbone area.

423
00:20:14,813 --> 00:20:18,717
And that has a special number reserved.

424
00:20:18,717 --> 00:20:21,219
Area 0.

425
00:20:21,219 --> 00:20:23,622
Now I could've made
the green area, Area 0,

426
00:20:23,622 --> 00:20:26,191
and I could've made the red area, Area 8.

427
00:20:26,191 --> 00:20:29,494
Doesn't really matter as long
as one of these two areas

428
00:20:29,494 --> 00:20:32,564
was Area 0, okay?

429
00:20:32,564 --> 00:20:35,233
So now why might I divide
this up into two areas?

430
00:20:35,233 --> 00:20:37,002
Here's why.

431
00:20:37,002 --> 00:20:40,305
A router only has to know the full map

432
00:20:40,305 --> 00:20:43,241
of what the topology
looks like of the areas

433
00:20:43,241 --> 00:20:45,611
that it is connected to.

434
00:20:45,611 --> 00:20:47,879
If there's other areas
out there that this router

435
00:20:47,879 --> 00:20:51,516
is not connected to, he has
no links in those other areas,

436
00:20:51,516 --> 00:20:53,518
he doesn't know what
those areas look like.

437
00:20:53,518 --> 00:20:54,921
They're just like a cloud to him.

438
00:20:54,921 --> 00:20:57,522
He'll know what subnets
live there, what networks

439
00:20:57,522 --> 00:20:59,116
are out there, but he won't know

440
00:20:59,116 --> 00:21:01,526
what that topology looks like.

441
00:21:01,526 --> 00:21:04,563
So for example, router four over here,

442
00:21:04,563 --> 00:21:08,701
router four knows exactly
what's inside this green area.

443
00:21:10,502 --> 00:21:11,970
He knows all of this.

444
00:21:11,970 --> 00:21:14,606
But as far as what's in this red area,

445
00:21:14,606 --> 00:21:16,675
just think of that as being like a cloud.

446
00:21:16,675 --> 00:21:20,379
Router four will know that
the 2.2.2 network exists,

447
00:21:20,379 --> 00:21:23,348
that the 1.2.1 network exists,
that the 1.1.1 network exists

448
00:21:23,348 --> 00:21:25,784
and that they're all
reachable via Switch 2.

449
00:21:25,784 --> 00:21:28,754
But he won't have any idea of
what the topology looks like

450
00:21:28,754 --> 00:21:30,822
behind Switch 2.

451
00:21:30,822 --> 00:21:32,824
That's sort of like a distance vector

452
00:21:32,824 --> 00:21:35,093
characteristic, actually.

453
00:21:35,093 --> 00:21:39,464
Now Switch 2, because he's
connected to both areas,

454
00:21:39,464 --> 00:21:42,200
he's actually gonna have two
trees that he has to build.

455
00:21:42,200 --> 00:21:45,570
He has to build a shortest
path tree for Area 8

456
00:21:45,570 --> 00:21:49,441
and a shortest path tree for Area 0.

457
00:21:49,441 --> 00:21:51,443
And he's actually gonna
have two databases,

458
00:21:51,443 --> 00:21:54,546
one database for all the
LSAs he's collected in Area 8

459
00:21:54,546 --> 00:21:58,116
and other database for all
the LSAs he's collected

460
00:21:58,116 --> 00:21:59,251
in Area 0.

461
00:21:59,251 --> 00:22:01,753
So he's gonna have to
work a little bit harder.

462
00:22:01,753 --> 00:22:05,157
As a matter of fact, when
a router such as Switch 2,

463
00:22:05,157 --> 00:22:07,225
I'm calling him Switch 2
but we're just treating him

464
00:22:07,225 --> 00:22:11,930
as a router, when a
router connects to Area 0

465
00:22:11,930 --> 00:22:15,701
and one other area, when
he's sitting as a border

466
00:22:15,701 --> 00:22:19,204
between the backbone area
and a non-backbone area,

467
00:22:19,204 --> 00:22:24,076
he actually goes by the name
of an area border router.

468
00:22:24,076 --> 00:22:25,765
An ABR.

469
00:22:26,745 --> 00:22:29,047
So why is that important?

470
00:22:29,047 --> 00:22:32,150
Well, let's go back to
this link right here.

471
00:22:32,150 --> 00:22:37,150
So when Switch 3 came
online and I activated OSPF

472
00:22:37,489 --> 00:22:40,826
on this link, he created an LSA

473
00:22:43,286 --> 00:22:45,063
that described that link.

474
00:22:45,063 --> 00:22:48,667
And that LSA got flooded to everybody.

475
00:22:50,669 --> 00:22:54,039
Now that LSA is, I'll just
give you a preview of it,

476
00:22:54,039 --> 00:22:56,274
I said there's different kinds of LSAs.

477
00:22:56,274 --> 00:22:58,443
This LSA here in green
I'm describing is called

478
00:22:58,443 --> 00:23:03,024
a Type-I, Type-I router LSA.

479
00:23:07,729 --> 00:23:11,461
The primary objective
of a Type-I router LSA

480
00:23:11,461 --> 00:23:15,026
is to help construct this tree,

481
00:23:15,026 --> 00:23:17,529
help build this SPF tree.

482
00:23:17,529 --> 00:23:21,233
A Type-I router LSA will
get flooded within an area,

483
00:23:21,233 --> 00:23:25,604
but it has to stop at
the area border router.

484
00:23:25,604 --> 00:23:28,073
In other words, all these devices in here,

485
00:23:28,073 --> 00:23:31,042
in the green area, Area
8, they need to see

486
00:23:31,042 --> 00:23:33,145
each other's Type-I router LSAs.

487
00:23:33,145 --> 00:23:35,113
That's what helps them
build this topology.

488
00:23:35,113 --> 00:23:39,117
But those Type-I router
LSAs will stop at Switch 2.

489
00:23:39,117 --> 00:23:41,920
They will not be allowed to
go into the backbone area,

490
00:23:41,920 --> 00:23:43,889
into Area 0.

491
00:23:43,889 --> 00:23:46,658
Similarly, there's gonna
be Type-I router LSAs

492
00:23:46,658 --> 00:23:50,195
that are generated here in
Area 0 so that all the devices

493
00:23:50,195 --> 00:23:52,330
in Area 0 can know what
their topology looks like,

494
00:23:52,330 --> 00:23:56,067
and they will stop at
the area border router.

495
00:23:56,067 --> 00:23:58,069
Now you might be thinking, wait a second,

496
00:23:58,069 --> 00:24:00,806
if those Type-I router
LSAs stop at the ABR

497
00:24:00,806 --> 00:24:05,744
and go no further, then how is
Area 0 ever gonna learn about

498
00:24:05,744 --> 00:24:08,113
the routes over here in Area 8?

499
00:24:08,113 --> 00:24:11,216
And how is Area 8 ever
gonna learn about the routes

500
00:24:11,216 --> 00:24:13,385
over here in Area 0?

501
00:24:13,385 --> 00:24:14,660
That's one of the special things

502
00:24:14,660 --> 00:24:16,354
the area border router does.

503
00:24:16,354 --> 00:24:19,825
He says well, I'm not
allowed to flood router LSAs

504
00:24:19,825 --> 00:24:22,294
from one area into another area.

505
00:24:22,294 --> 00:24:23,795
I can't do that.

506
00:24:23,795 --> 00:24:25,964
So hmmm, what shall I do?

507
00:24:25,964 --> 00:24:28,934
Why don't I create a
different kind of an LSA,

508
00:24:28,934 --> 00:24:31,903
an LSA whose purpose is
not to create a tree,

509
00:24:31,903 --> 00:24:34,639
not to create any kind
of topology information,

510
00:24:34,639 --> 00:24:38,543
an LSA whose sole purpose is
just to describe networks,

511
00:24:38,543 --> 00:24:41,913
just describes what subnets
live in various areas?

512
00:24:41,913 --> 00:24:43,915
And that's what the ABR will do.

513
00:24:43,915 --> 00:24:47,154
He will actually create
a special type of an LSA,

514
00:24:47,154 --> 00:24:50,021
actually several of them,
that will go out this way,

515
00:24:50,021 --> 00:24:54,159
and these LSAs will say hey,
I'm your ABR, I'm Switch 2,

516
00:24:54,159 --> 00:24:57,095
and you can use me to
get to the 2.3.2 network

517
00:24:57,095 --> 00:24:59,664
or the 3.2.3 or the 3.3.3 or the 3.4.3.

518
00:24:59,664 --> 00:25:01,433
You can get there through me.

519
00:25:01,433 --> 00:25:03,635
I'm not telling you what
the topology looks like,

520
00:25:03,635 --> 00:25:05,637
but with this special kind of LSA,

521
00:25:05,637 --> 00:25:07,639
I'm just saying there's
another area you guys

522
00:25:07,639 --> 00:25:10,108
don't know about, an Area of 0,

523
00:25:10,108 --> 00:25:13,022
and you can reach those
subnets through me.

524
00:25:14,112 --> 00:25:16,114
So that's why the ABR is very special.

525
00:25:16,114 --> 00:25:19,084
Once he realizes, oh, hey, I
connect to the backbone area

526
00:25:19,084 --> 00:25:23,188
and one or more non-backbone areas,

527
00:25:23,188 --> 00:25:24,456
he says okay.

528
00:25:24,456 --> 00:25:27,893
Router LSAs, stop with
me, and I have to generate

529
00:25:27,893 --> 00:25:30,795
a different kind of an LSA
so that these two areas

530
00:25:30,795 --> 00:25:34,199
can learn about the
routes that live there.

531
00:25:34,199 --> 00:25:37,636
So that's why we say that OSPF
works on an area hierarchy,

532
00:25:37,636 --> 00:25:39,537
an area hierarchy.

533
00:25:39,537 --> 00:25:42,440
So just to, once again,
put that into perspective,

534
00:25:42,440 --> 00:25:44,976
if I have one area

535
00:25:44,976 --> 00:25:47,379
that can be whatever I want.

536
00:25:47,379 --> 00:25:51,816
But if I have two or
more areas, like this,

537
00:25:52,786 --> 00:25:55,353
and maybe like this,

538
00:25:55,353 --> 00:25:59,691
then the area in the middle
is gonna be my backbone area,

539
00:25:59,691 --> 00:26:02,144
which is Area 0.

540
00:26:03,295 --> 00:26:06,998
The other areas can be
whatever I want them to be.

541
00:26:06,998 --> 00:26:09,701
Maybe this is Area 20.

542
00:26:09,701 --> 00:26:13,940
And maybe over here this is Area 77.

543
00:26:16,441 --> 00:26:19,473
But the main idea is that
everything has to flow

544
00:26:19,473 --> 00:26:22,640
through the backbone.

545
00:26:22,640 --> 00:26:25,383
So even theoretically, let's
say I had a router here

546
00:26:25,383 --> 00:26:27,852
who was like this,

547
00:26:27,852 --> 00:26:32,357
say this is router X, router
X has a link in Area 20,

548
00:26:32,357 --> 00:26:34,259
he has a link in Area 77.

549
00:26:34,259 --> 00:26:36,094
Is he an ABR?

550
00:26:36,094 --> 00:26:40,432
No, he is not because he
is not connected to Area 0.

551
00:26:40,432 --> 00:26:43,735
So as such, router X does
know what that topology

552
00:26:43,735 --> 00:26:46,271
looks like in area 20 and
what the topology looks like

553
00:26:46,271 --> 00:26:50,175
in Area 77, but he is not
allowed to send routes

554
00:26:50,175 --> 00:26:53,745
from Area 77 into Area 20 and vice versa.

555
00:26:53,745 --> 00:26:55,747
Anything he learns about in Area 20,

556
00:26:55,747 --> 00:26:58,516
he is not allowed to send
those routes into Area 77

557
00:26:58,516 --> 00:27:01,953
because he is not an ABR.

558
00:27:01,953 --> 00:27:04,022
So these other routers
right here that are between

559
00:27:04,022 --> 00:27:06,825
the backbone area and
the non-backbone areas,

560
00:27:06,825 --> 00:27:09,227
these are my ABRs.

561
00:27:09,227 --> 00:27:14,099
So routes will always be
learned from the backbone

562
00:27:14,099 --> 00:27:16,880
and then into non-backbone areas.

563
00:27:19,037 --> 00:27:21,403
That's the way routes will be learned.

564
00:27:21,403 --> 00:27:25,777
(epic electronic music)

