1
00:00:03,184 --> 00:00:06,934
(lightning crackling jingle)

2
00:00:09,067 --> 00:00:10,544
- In this video, I'm going to go into

3
00:00:10,544 --> 00:00:13,794
the OSPF designated route
and backup designated router

4
00:00:13,794 --> 00:00:15,684
in theory and in practice

5
00:00:15,684 --> 00:00:19,225
and talk about why these
things were developed for OSPF.

6
00:00:19,225 --> 00:00:20,517
So, to begin with, let's go ahead

7
00:00:20,517 --> 00:00:21,993
and go to the whiteboard first,

8
00:00:21,993 --> 00:00:25,621
before we go into our slides,
to talk about this concept.

9
00:00:25,621 --> 00:00:28,113
Like I frequently like
to do, I like to contrast

10
00:00:28,113 --> 00:00:32,295
OSPF and EIGRP so you can see
some of their similarities

11
00:00:32,295 --> 00:00:34,762
and some of their differences.

12
00:00:34,762 --> 00:00:36,375
Here, we have four routers,

13
00:00:36,375 --> 00:00:39,067
and all four routers are
connected to the same switch,

14
00:00:39,067 --> 00:00:41,034
and they're all in the
same broadcast domain,

15
00:00:41,034 --> 00:00:43,966
as you can see from their IP address.

16
00:00:43,966 --> 00:00:47,799
If we were talking about
EIGRP, as an example,

17
00:00:48,901 --> 00:00:51,318
router one would list R2, R3,

18
00:00:53,133 --> 00:00:54,800
and R4 as neighbors.

19
00:00:57,607 --> 00:01:01,453
Now, let's say that R1 had an EIGRP update

20
00:01:01,453 --> 00:01:03,314
that it needed to send.

21
00:01:03,314 --> 00:01:07,209
We know that EIGRP updates
go out as multicast packets.

22
00:01:07,209 --> 00:01:09,862
What do switches do with multicasts?

23
00:01:09,862 --> 00:01:12,426
They flood them, just like
they flood broadcasts,

24
00:01:12,426 --> 00:01:16,593
so that multicast packet would
be flooded to R2, R3, and R4.

25
00:01:19,426 --> 00:01:20,864
Now, because R1 is neighbors

26
00:01:20,864 --> 00:01:22,933
with all three of those routers,

27
00:01:22,933 --> 00:01:24,361
he would wait and he'd say,

28
00:01:24,361 --> 00:01:27,772
"Well, I need to get an
EIGRP acknowledgement

29
00:01:27,772 --> 00:01:30,258
"from R2, R3, and R4."

30
00:01:30,258 --> 00:01:35,136
All of a sudden, here's R2,
sends in EIGRP hello packet

31
00:01:35,136 --> 00:01:37,321
with the sequence number
saying, "I acknowledge."

32
00:01:37,321 --> 00:01:39,454
He says, "Okay, R2, you're good to go.

33
00:01:39,454 --> 00:01:41,407
"Thank you for acknowledging."

34
00:01:41,407 --> 00:01:45,230
Here comes R3 sending a hello packet,

35
00:01:45,230 --> 00:01:46,871
and we check that off.

36
00:01:46,871 --> 00:01:50,836
Hopefully, eventually, R4
would send his own hello packet

37
00:01:50,836 --> 00:01:53,122
with that same sequence number in it.

38
00:01:53,122 --> 00:01:55,708
R1 would say, "Okay, all
three of my neighbors

39
00:01:55,708 --> 00:01:58,735
"have acknowledged this update."

40
00:01:58,735 --> 00:02:01,171
In the event that something went wrong

41
00:02:01,171 --> 00:02:04,816
and one of these routers did
not send an acknowledgment,

42
00:02:04,816 --> 00:02:08,036
then R1 would resend his EIGRP update

43
00:02:08,036 --> 00:02:11,911
as a unicast packet
directly to that neighbor.

44
00:02:11,911 --> 00:02:15,371
What does that have to do with OSPF?

45
00:02:15,371 --> 00:02:17,428
Now, remember that with OSPF,

46
00:02:17,428 --> 00:02:19,137
we saw that when we were
talking about the process

47
00:02:19,137 --> 00:02:21,971
of building a neighbor
relationship that it was important

48
00:02:21,971 --> 00:02:24,166
that all the OSPF routers
who were neighbors

49
00:02:24,166 --> 00:02:28,351
had a common database, that
their LSAs were the same.

50
00:02:28,351 --> 00:02:30,715
So, there were about six different steps

51
00:02:30,715 --> 00:02:33,112
we had to go through to get to that point.

52
00:02:33,112 --> 00:02:37,287
We had to go to init,
2-way, exstart, exchange,

53
00:02:37,287 --> 00:02:41,931
loading, and then finally
full to do all that.

54
00:02:41,931 --> 00:02:44,388
In this type of an environment,

55
00:02:44,388 --> 00:02:47,002
in this type of a network
where a router says,

56
00:02:47,002 --> 00:02:51,714
"Okay, there could be more than
one router on this network."

57
00:02:51,714 --> 00:02:53,449
For example, think about Ethernet.

58
00:02:53,449 --> 00:02:55,663
The nature of Ethernet is that

59
00:02:55,663 --> 00:02:57,699
you can put one frame on the wire,

60
00:02:57,699 --> 00:03:00,099
and you don't know how many
people are going to see that.

61
00:03:00,099 --> 00:03:01,831
You don't know how many people are on

62
00:03:01,831 --> 00:03:04,128
that same Ethernet cable as you.

63
00:03:04,128 --> 00:03:06,381
The nature of Ethernet
is that it could be two,

64
00:03:06,381 --> 00:03:09,048
three, four, 44, you don't know.

65
00:03:10,131 --> 00:03:14,031
Ethernet is what we call
a multi-access medium.

66
00:03:14,031 --> 00:03:15,534
The desires of OSPF, they said,

67
00:03:15,534 --> 00:03:19,701
"Well, we could, on a
multi-access medium like Ethernet,

68
00:03:20,865 --> 00:03:23,303
"where there's a potential
of lots of different routers

69
00:03:23,303 --> 00:03:25,739
"out there on this wire,

70
00:03:25,739 --> 00:03:28,009
"we could do like EIGRP does.

71
00:03:28,009 --> 00:03:29,322
"We could have all the routers go through

72
00:03:29,322 --> 00:03:32,280
"all five or six steps with each other.

73
00:03:32,280 --> 00:03:35,480
"All the routers become fully adjacent."

74
00:03:35,480 --> 00:03:38,421
They said, "Then, when an OSPF router

75
00:03:38,421 --> 00:03:41,004
"sends out a link-state update,

76
00:03:42,450 --> 00:03:44,325
"we could do like EIGRP does

77
00:03:44,325 --> 00:03:48,444
"and all the other routers
have to acknowledge it back."

78
00:03:48,444 --> 00:03:51,812
But the designers of OSPF
took a different approach.

79
00:03:51,812 --> 00:03:54,818
They said, "Here's what we're gonna do.

80
00:03:54,818 --> 00:03:59,016
"On a multi-access network
segment like Ethernet,

81
00:03:59,016 --> 00:04:02,230
"we're gonna have one router elected

82
00:04:02,230 --> 00:04:04,780
"as a very special position,
which is gonna be called

83
00:04:04,780 --> 00:04:06,595
"the designated router."

84
00:04:06,595 --> 00:04:10,308
Let's just say it's R4, as an example.

85
00:04:10,308 --> 00:04:12,396
During the exchange of hello packets

86
00:04:12,396 --> 00:04:14,298
is when this election takes process.

87
00:04:14,298 --> 00:04:16,368
As these four routers
are exchanging hellos,

88
00:04:16,368 --> 00:04:20,720
remember, their hellos are
going out as multicasts.

89
00:04:20,720 --> 00:04:24,887
What's the multicast address
that OSPF hellos go out to?

90
00:04:26,019 --> 00:04:26,852
224.0.0.5.

91
00:04:30,475 --> 00:04:32,698
Hellos always go to that address.

92
00:04:32,698 --> 00:04:37,553
Inside that multicast
hello, there are some fields

93
00:04:37,553 --> 00:04:39,826
that help these routers to figure out

94
00:04:39,826 --> 00:04:43,100
who this designated router is going to be.

95
00:04:43,100 --> 00:04:46,079
What's the significance
of the designated router?

96
00:04:46,079 --> 00:04:48,638
Well, once we know who
the designated router is,

97
00:04:48,638 --> 00:04:52,805
router one will go through all
six steps with router four.

98
00:04:54,226 --> 00:04:57,633
Init, 2-way, exstart,
exchange, loading, full.

99
00:04:57,633 --> 00:05:01,458
Router two will become fully
adjacent with router four,

100
00:05:01,458 --> 00:05:03,909
and router three will
become fully adjacent

101
00:05:03,909 --> 00:05:05,466
with router four.

102
00:05:05,466 --> 00:05:06,383
Notice, R1,

103
00:05:07,468 --> 00:05:08,385
R2, and R3,

104
00:05:09,838 --> 00:05:13,230
they're not becoming fully
adjacent with each other.

105
00:05:13,230 --> 00:05:14,113
They see each other.

106
00:05:14,113 --> 00:05:15,911
They're still seeing each other's hellos,

107
00:05:15,911 --> 00:05:17,570
because those hello packets are multicast,

108
00:05:17,570 --> 00:05:19,667
so they're seeing that.

109
00:05:19,667 --> 00:05:22,190
But when R1 looks at R2 and says,

110
00:05:22,190 --> 00:05:25,599
"Oh, neither one of us
is a designated router,

111
00:05:25,599 --> 00:05:28,184
"we don't need to go
beyond the 2-way state.

112
00:05:28,184 --> 00:05:29,984
"I see you and you see me.

113
00:05:29,984 --> 00:05:32,012
"Good, we're in the 2-way state,

114
00:05:32,012 --> 00:05:33,795
"but that's as far as we need to go.

115
00:05:33,795 --> 00:05:35,550
"We can stop there."

116
00:05:35,550 --> 00:05:39,383
With the DR, everybody
becomes fully adjacent.

117
00:05:40,250 --> 00:05:42,038
What's the purpose of that?

118
00:05:42,038 --> 00:05:45,830
Well, now if R1, let's
just take R1 as an example.

119
00:05:45,830 --> 00:05:49,076
Let's say that R1 has a link-state update

120
00:05:49,076 --> 00:05:50,727
that it needs to send

121
00:05:50,727 --> 00:05:54,915
containing one or more
new LSAs inside of it.

122
00:05:54,915 --> 00:05:58,703
R1 is gonna say, "I can only
send my link-state updates

123
00:05:58,703 --> 00:06:02,121
"to OSPF neighbors that
I'm fully adjacent with,

124
00:06:02,121 --> 00:06:03,804
"that I'm in the full state,

125
00:06:03,804 --> 00:06:06,017
"I went through those
five or six steps with."

126
00:06:06,017 --> 00:06:08,373
Which, in this case, is
the designated router.

127
00:06:08,373 --> 00:06:10,547
He says, "Hm, I know there's other routers

128
00:06:10,547 --> 00:06:14,270
"here on this segment besides R4, the DR.

129
00:06:14,270 --> 00:06:17,558
"How do I get this link-state
update just to him?

130
00:06:17,558 --> 00:06:19,245
"Ah, here's what I know I'll do.

131
00:06:19,245 --> 00:06:21,044
"I'll send my link-state update

132
00:06:21,044 --> 00:06:25,211
"to a special, reserved
OSPF address of 224.0.0.6."

133
00:06:29,003 --> 00:06:33,141
Only the designated router
is listening to that address.

134
00:06:33,141 --> 00:06:35,882
So now, when this link-state
update packet goes in,

135
00:06:35,882 --> 00:06:38,832
it is a multicast, so it will be flooded.

136
00:06:38,832 --> 00:06:41,642
R2, R3, and R4 will see it,

137
00:06:41,642 --> 00:06:44,126
but R2 and R3 will discard it.

138
00:06:44,126 --> 00:06:46,574
They'll say, "Oh, I'm
not a designated router.

139
00:06:46,574 --> 00:06:48,278
"This is not for me."

140
00:06:48,278 --> 00:06:50,271
Now, that link-state update will only be

141
00:06:50,271 --> 00:06:52,354
seen and processed by R4.

142
00:06:54,279 --> 00:06:56,042
Now, R4 gets it.

143
00:06:56,042 --> 00:06:57,761
Here it comes in.

144
00:06:57,761 --> 00:06:59,998
Now, R4 says, "Great.

145
00:06:59,998 --> 00:07:03,526
"My link-state database
is synchronized with R1.

146
00:07:03,526 --> 00:07:05,190
"R1 and I are in sync.

147
00:07:05,190 --> 00:07:06,514
"I got his link state.

148
00:07:06,514 --> 00:07:08,656
"Oh, by the way, let me
acknowledge that back."

149
00:07:08,656 --> 00:07:09,690
So R4 will do that.

150
00:07:09,690 --> 00:07:12,268
He'll send a link-state
acknowledgement packet back.

151
00:07:12,268 --> 00:07:15,396
Now R4 will say, "But I
have two other neighbors

152
00:07:15,396 --> 00:07:17,563
"on this wire, R2 and R3."

153
00:07:19,297 --> 00:07:22,356
Now what R4 will do is he'll turn around

154
00:07:22,356 --> 00:07:25,189
and he'll send a link-state update

155
00:07:26,655 --> 00:07:29,715
to R2 and R3, link-state update.

156
00:07:29,715 --> 00:07:33,258
He'll reflect that
link-state update right back,

157
00:07:33,258 --> 00:07:34,841
going to 224.0.0.5.

158
00:07:40,156 --> 00:07:42,486
Now, you might be thinking wait a second,

159
00:07:42,486 --> 00:07:44,569
if R4 does that, isn't R1

160
00:07:45,600 --> 00:07:47,139
gonna see his very own

161
00:07:47,139 --> 00:07:49,891
link-state update packet
coming back to him?

162
00:07:49,891 --> 00:07:51,844
As a matter of fact, yes he will.

163
00:07:51,844 --> 00:07:56,822
Remember, that link-state
update has an LSA inside of it,

164
00:07:56,822 --> 00:07:59,095
maybe more than one LSA.

165
00:07:59,095 --> 00:08:01,490
Remember, every LSA has a field that says

166
00:08:01,490 --> 00:08:03,251
who does this LSA belong to?

167
00:08:03,251 --> 00:08:04,421
Who created it?

168
00:08:04,421 --> 00:08:06,917
Who's the originator of the LSA?

169
00:08:06,917 --> 00:08:08,048
In this particular case,

170
00:08:08,048 --> 00:08:10,130
when R1 gets that link-state update

171
00:08:10,130 --> 00:08:11,644
and he looks inside of it, he'll say,

172
00:08:11,644 --> 00:08:14,522
"Oh, here's an LSA that
was advertised by R1.

173
00:08:14,522 --> 00:08:16,118
"Oh, that's me.

174
00:08:16,118 --> 00:08:17,452
"Okay, I can ignore that.

175
00:08:17,452 --> 00:08:19,379
"Here's another one that
was advertised by R1.

176
00:08:19,379 --> 00:08:20,869
"Oh, okay, that's me.

177
00:08:20,869 --> 00:08:22,321
"I can ignore that."

178
00:08:22,321 --> 00:08:25,420
In this regard, all these routers

179
00:08:25,420 --> 00:08:27,427
will become fully synchronized.

180
00:08:27,427 --> 00:08:30,665
Once again, just to repeat the process,

181
00:08:30,665 --> 00:08:32,742
the DR is elected.

182
00:08:32,742 --> 00:08:35,054
All these routers exchange hello packets,

183
00:08:35,054 --> 00:08:37,317
and within the hello
packets are some fields,

184
00:08:37,317 --> 00:08:38,925
which I haven't talked about yet,

185
00:08:38,925 --> 00:08:40,496
which will help them to figure out

186
00:08:40,496 --> 00:08:43,152
who the designated router should be.

187
00:08:43,152 --> 00:08:45,801
Once that takes place, all of the routers

188
00:08:45,801 --> 00:08:49,169
become fully adjacent with
the designated router.

189
00:08:49,169 --> 00:08:52,971
They go through all five or
six of those steps with him.

190
00:08:52,971 --> 00:08:54,965
After that point,

191
00:08:54,965 --> 00:08:57,410
if anybody needs to send
a link-state update,

192
00:08:57,410 --> 00:08:59,883
they will send it to the DR,

193
00:08:59,883 --> 00:09:02,633
and they'll send it to 224.0.0.6.

194
00:09:04,995 --> 00:09:08,027
That is an address that
only the DR is listening to.

195
00:09:08,027 --> 00:09:10,827
The DR, in turn, will reflect
that link-state update

196
00:09:10,827 --> 00:09:12,160
right back again

197
00:09:13,136 --> 00:09:15,882
so that all the other routers can get it,

198
00:09:15,882 --> 00:09:18,974
including the originator,
who will say, "No."

199
00:09:18,974 --> 00:09:21,141
That will go to 224.0.0.5.

200
00:09:25,443 --> 00:09:28,058
The idea being here is that
if I have an Ethernet switch

201
00:09:28,058 --> 00:09:31,227
that, let's say, has 20 routers on it,

202
00:09:31,227 --> 00:09:33,729
they don't all have to
become fully adjacent

203
00:09:33,729 --> 00:09:34,937
with each other.

204
00:09:34,937 --> 00:09:36,644
They only have to become fully adjacent

205
00:09:36,644 --> 00:09:38,214
with the designated router.

206
00:09:38,214 --> 00:09:40,278
They send their updates to him,

207
00:09:40,278 --> 00:09:41,787
and then they don't
have to worry about it.

208
00:09:41,787 --> 00:09:43,128
He's the one that's going to turn around

209
00:09:43,128 --> 00:09:45,131
and reflect it to everybody else.

210
00:09:45,131 --> 00:09:47,205
The designated router's
job is to make sure

211
00:09:47,205 --> 00:09:49,944
that everybody is synchronized
with everybody else.

212
00:09:49,944 --> 00:09:51,810
That is his job.

213
00:09:51,810 --> 00:09:54,253
By the way, there's one other router here

214
00:09:54,253 --> 00:09:56,086
who is also elected as

215
00:09:57,400 --> 00:10:00,483
a backup designated router, or a BDR.

216
00:10:03,460 --> 00:10:07,598
Just like the DR is
listening to 224.0.0.6,

217
00:10:07,598 --> 00:10:10,848
the BDR is also listening to 224.0.0.6.

218
00:10:14,374 --> 00:10:17,223
When R1 sent his initial link-state update

219
00:10:17,223 --> 00:10:18,306
to 224.0.0.6,

220
00:10:19,166 --> 00:10:20,999
both R3 and R4 got it.

221
00:10:22,575 --> 00:10:26,687
But it was only R4's job,
as the designated router,

222
00:10:26,687 --> 00:10:29,421
to turn around and
reflect that back so that,

223
00:10:29,421 --> 00:10:32,312
in this case, R2 could get it.

224
00:10:32,312 --> 00:10:34,319
R3 is sort of just sitting there silently.

225
00:10:34,319 --> 00:10:37,538
He is taking stuff in,
because he's listening to .6,

226
00:10:37,538 --> 00:10:40,769
but it's not his job to turn
around and reflect stuff back.

227
00:10:40,769 --> 00:10:45,650
Only if the designated router
fails will R3 take up the job

228
00:10:45,650 --> 00:10:48,067
as the new designated router.

229
00:10:49,373 --> 00:10:51,627
Now that we know that,

230
00:10:51,627 --> 00:10:54,381
let's go into these slides.

231
00:10:54,381 --> 00:10:57,614
A DR and a BDR are elected in broadcast

232
00:10:57,614 --> 00:11:00,807
and non-broadcast multi-access networks.

233
00:11:00,807 --> 00:11:02,049
Now, we haven't really talked about

234
00:11:02,049 --> 00:11:03,260
those two terms yet.

235
00:11:03,260 --> 00:11:05,951
That's coming up in a little
bit in a different video.

236
00:11:05,951 --> 00:11:08,184
Just think about it this way.

237
00:11:08,184 --> 00:11:10,644
We know that at layer 2,

238
00:11:10,644 --> 00:11:13,925
at the data link layer of the OSI model,

239
00:11:13,925 --> 00:11:16,509
there are several different
encapsulation types:

240
00:11:16,509 --> 00:11:17,676
Ethernet, PPP,

241
00:11:18,581 --> 00:11:20,784
HDLC, frame relay.

242
00:11:20,784 --> 00:11:23,436
You could probably think
of one or two or three more

243
00:11:23,436 --> 00:11:25,414
in addition to that.

244
00:11:25,414 --> 00:11:28,271
What's one thing that makes
them different from each other?

245
00:11:28,271 --> 00:11:30,452
Some of those encapsulation types

246
00:11:30,452 --> 00:11:32,395
were built around the assumption

247
00:11:32,395 --> 00:11:35,566
that I could put one frame on the wire

248
00:11:35,566 --> 00:11:39,035
and multiple devices
could see that one frame,

249
00:11:39,035 --> 00:11:40,079
like Ethernet.

250
00:11:40,079 --> 00:11:41,639
That's the nature of Ethernet.

251
00:11:41,639 --> 00:11:43,793
That's the nature of,

252
00:11:43,793 --> 00:11:45,202
well, let's just stick with Ethernet.

253
00:11:45,202 --> 00:11:46,685
That's Ethernet, you can
put one frame on there,

254
00:11:46,685 --> 00:11:48,671
and everybody will see it.

255
00:11:48,671 --> 00:11:51,019
Other layer 2 encapsulation types say,

256
00:11:51,019 --> 00:11:52,785
"Well, if I put one frame on the wire,

257
00:11:52,785 --> 00:11:55,137
"it's only going to go one place,"

258
00:11:55,137 --> 00:11:59,017
like the point-to-point protocol or HDLC.

259
00:11:59,017 --> 00:12:00,559
Those are layer 2 protocols that say,

260
00:12:00,559 --> 00:12:03,409
"This was designed for a cable
that's just got two devices.

261
00:12:03,409 --> 00:12:06,013
"Put something on the cable,
it only goes over here.

262
00:12:06,013 --> 00:12:07,533
"This guy puts something on the cable,

263
00:12:07,533 --> 00:12:08,967
"it only goes over here."

264
00:12:08,967 --> 00:12:11,278
So, there's really no need for an address,

265
00:12:11,278 --> 00:12:13,075
because there's just the two of us.

266
00:12:13,075 --> 00:12:15,325
PPP and HDLC are like that.

267
00:12:16,159 --> 00:12:18,481
Then, there's other types
of encapsulation types,

268
00:12:18,481 --> 00:12:19,946
like frame relay, that say,

269
00:12:19,946 --> 00:12:23,729
"Well, this particular cable
could go multiple places."

270
00:12:23,729 --> 00:12:26,239
For example, think about your
connection to the Internet.

271
00:12:26,239 --> 00:12:27,409
You're sitting at home.

272
00:12:27,409 --> 00:12:28,837
You have a connection to the Internet.

273
00:12:28,837 --> 00:12:31,828
That one cable you have
leading out of your house

274
00:12:31,828 --> 00:12:35,716
can reach billions of remote destinations.

275
00:12:35,716 --> 00:12:37,673
It's sort of like Ethernet in that way.

276
00:12:37,673 --> 00:12:39,307
You could put one thing on there,

277
00:12:39,307 --> 00:12:41,881
one cable that gets you multiple places.

278
00:12:41,881 --> 00:12:45,722
But is it possible for you to
put something on that cable

279
00:12:45,722 --> 00:12:49,282
that all those remote
destinations are going to see?

280
00:12:49,282 --> 00:12:51,041
No, it's not.

281
00:12:51,041 --> 00:12:53,593
In the case of your Internet connection,

282
00:12:53,593 --> 00:12:56,038
you have to address everything
you put on that cable

283
00:12:56,038 --> 00:12:57,844
to who you want to send it to.

284
00:12:57,844 --> 00:12:59,605
It doesn't support broadcast.

285
00:12:59,605 --> 00:13:02,201
You can't put a broadcast
on your cable modem

286
00:13:02,201 --> 00:13:05,830
or your DSL connection to
Time Warner Cable or Comcast

287
00:13:05,830 --> 00:13:08,728
and expect that all the billions
of devices in the Internet

288
00:13:08,728 --> 00:13:10,205
are gonna see it.

289
00:13:10,205 --> 00:13:12,560
It doesn't work that way.

290
00:13:12,560 --> 00:13:13,664
That's what we consider

291
00:13:13,664 --> 00:13:16,783
a non-broadcast multi-access network.

292
00:13:16,783 --> 00:13:19,219
In all these networks where I
can out something on a cable

293
00:13:19,219 --> 00:13:20,386
and I can say to myself,

294
00:13:20,386 --> 00:13:23,564
"Well, there could be more than one device

295
00:13:23,564 --> 00:13:25,316
"reachable on this cable."

296
00:13:25,316 --> 00:13:27,263
In that particular case,
a designated router

297
00:13:27,263 --> 00:13:31,180
and a backup designated
router will be elected.

298
00:13:32,257 --> 00:13:35,753
We've talked about these last
two bullet points right here.

299
00:13:35,753 --> 00:13:40,072
How do we determine which
router that will be?

300
00:13:40,072 --> 00:13:43,201
Well, by default, the very first router

301
00:13:43,201 --> 00:13:46,907
that comes online on a cable
will be the designated router.

302
00:13:46,907 --> 00:13:48,454
That's pretty much it.

303
00:13:48,454 --> 00:13:50,870
Now, if two routers come
online at the same time,

304
00:13:50,870 --> 00:13:53,729
if they start exchanging
hellos at the same time,

305
00:13:53,729 --> 00:13:56,730
then the router with the
highest interface priority

306
00:13:56,730 --> 00:13:58,580
will become the designated router.

307
00:13:58,580 --> 00:14:00,989
This is the first time
I've talked about this.

308
00:14:00,989 --> 00:14:04,821
In OSPF, when you use the
network command under OSPF,

309
00:14:04,821 --> 00:14:07,560
and OSPF says, "Oh, here's
an interface right here

310
00:14:07,560 --> 00:14:09,582
"that falls in line with that network.

311
00:14:09,582 --> 00:14:12,605
"I'll start speaking, I'll start
sending out hello packets."

312
00:14:12,605 --> 00:14:16,232
On this interface, he gives
it an OSPF priority value.

313
00:14:16,232 --> 00:14:18,570
It's actually the value of one by default.

314
00:14:18,570 --> 00:14:20,903
In my hello packets I send out,

315
00:14:20,903 --> 00:14:22,871
that's one of the things I put in there is

316
00:14:22,871 --> 00:14:24,795
what my interface priority is.

317
00:14:24,795 --> 00:14:26,381
If I'm sending hello packets to you

318
00:14:26,381 --> 00:14:28,271
and you're sending hello packets to me,

319
00:14:28,271 --> 00:14:31,652
if one of us has a higher
interface priority than the other,

320
00:14:31,652 --> 00:14:32,688
we're done.

321
00:14:32,688 --> 00:14:34,571
The highest interface priority will win,

322
00:14:34,571 --> 00:14:38,492
and that will become
the designated router.

323
00:14:38,492 --> 00:14:41,975
When you do the command
show ip ospf neighbor

324
00:14:41,975 --> 00:14:43,559
to view your neighbors,

325
00:14:43,559 --> 00:14:45,620
you will see, on an Ethernet segment,

326
00:14:45,620 --> 00:14:48,308
you'll see at least one
neighbor shown as DR,

327
00:14:48,308 --> 00:14:51,980
for designated router, possibly
another one that says BDR,

328
00:14:51,980 --> 00:14:54,957
and then others that will say DROTHERS.

329
00:14:54,957 --> 00:14:58,436
DROTHERS mean routers that currently

330
00:14:58,436 --> 00:14:59,990
are not the DR,

331
00:14:59,990 --> 00:15:01,811
not the BDR,

332
00:15:01,811 --> 00:15:03,941
but they could be in the future.

333
00:15:03,941 --> 00:15:06,644
If the DR and BDR fail,
these other routers

334
00:15:06,644 --> 00:15:10,311
could potentially become
designated routers.

335
00:15:11,156 --> 00:15:13,453
Now, let's say that you have not

336
00:15:13,453 --> 00:15:16,375
manually configured
the interface priority.

337
00:15:16,375 --> 00:15:17,816
Remember, it's interface priority.

338
00:15:17,816 --> 00:15:18,994
It's not a global priority.

339
00:15:18,994 --> 00:15:21,704
On a router, if he's got five interfaces,

340
00:15:21,704 --> 00:15:23,986
if you wanted to, you
could have each interface

341
00:15:23,986 --> 00:15:26,050
have a different priority value.

342
00:15:26,050 --> 00:15:28,085
By default, they'll all be the same.

343
00:15:28,085 --> 00:15:29,740
They'll be the value of one.

344
00:15:29,740 --> 00:15:31,682
If you and I exchange OSPF hello packets

345
00:15:31,682 --> 00:15:33,001
over an Ethernet segment

346
00:15:33,001 --> 00:15:36,014
and we both have the exact
same interface priority,

347
00:15:36,014 --> 00:15:38,081
then we're going to
compare each other's names,

348
00:15:38,081 --> 00:15:41,268
our router-ids, our OSPF router-ids.

349
00:15:41,268 --> 00:15:45,790
Whoever has the highest
router-id will be the winner.

350
00:15:45,790 --> 00:15:48,262
That will become the designated router,

351
00:15:48,262 --> 00:15:50,044
and the second highest will become

352
00:15:50,044 --> 00:15:52,461
the backup designated router.

353
00:15:54,477 --> 00:15:57,942
A lot of times, people don't
really necessarily care

354
00:15:57,942 --> 00:16:00,363
which router will be the DR or the BDR.

355
00:16:00,363 --> 00:16:03,062
They just let OSPF take
care of that by itself.

356
00:16:03,062 --> 00:16:05,267
Let's say you wanted to
have some control over that.

357
00:16:05,267 --> 00:16:07,752
As the network administrator,
you wanted to be

358
00:16:07,752 --> 00:16:10,458
in control over which router
was going to become the DR

359
00:16:10,458 --> 00:16:12,084
and the BDR.

360
00:16:12,084 --> 00:16:15,210
The easiest way to do that
would be to go the interface

361
00:16:15,210 --> 00:16:17,892
and change the OSPF interface priority.

362
00:16:17,892 --> 00:16:18,861
In a video coming up

363
00:16:18,861 --> 00:16:21,405
where we actually go over
the configuration commands,

364
00:16:21,405 --> 00:16:23,136
I'll show you how to do that.

365
00:16:23,136 --> 00:16:24,516
The second way you could do it

366
00:16:24,516 --> 00:16:28,266
is by manipulating the
OSPF router-id itself.

367
00:16:30,036 --> 00:16:31,166
As soon as you type

368
00:16:31,166 --> 00:16:35,567
router OSPF and then some
process ID and hit enter,

369
00:16:35,567 --> 00:16:37,494
it elects a router-id for itself.

370
00:16:37,494 --> 00:16:39,532
It looks at all of its
interfaces and says,

371
00:16:39,532 --> 00:16:41,578
"I need to pull an IP address here

372
00:16:41,578 --> 00:16:45,161
"and use that as my
name, as my router-id."

373
00:16:46,024 --> 00:16:47,121
What's the order?

374
00:16:47,121 --> 00:16:48,061
How's it going to do that?

375
00:16:48,061 --> 00:16:50,362
Number one, first thing
OSPF is going to say is,

376
00:16:50,362 --> 00:16:51,901
"All right, under my configuration,

377
00:16:51,901 --> 00:16:54,535
"under my router OSPF configuration,

378
00:16:54,535 --> 00:16:58,702
"did some human being actually
type the router-id command?

379
00:17:00,239 --> 00:17:04,738
"If they did, that's what
I'll use as my router-id."

380
00:17:04,738 --> 00:17:07,927
What if you did not type
the router-id command?

381
00:17:07,927 --> 00:17:09,676
Well, then the router will look to see

382
00:17:09,676 --> 00:17:11,956
if you have any loopback interfaces.

383
00:17:11,956 --> 00:17:14,482
If you do, whatever the
highest IP address is

384
00:17:14,482 --> 00:17:16,864
of all of your loopbacks,

385
00:17:16,864 --> 00:17:18,883
that will be your router-id.

386
00:17:18,883 --> 00:17:21,787
Lastly, if there are no loopbacks

387
00:17:21,787 --> 00:17:25,286
and there's no OSPF router-id
that was manually configured,

388
00:17:25,286 --> 00:17:27,439
it'll just look around at your interfaces

389
00:17:27,439 --> 00:17:29,848
and select an IP address
from your interface,

390
00:17:29,848 --> 00:17:32,987
the highest IP address from
among your physical interfaces,

391
00:17:32,987 --> 00:17:36,140
and use that as its router-id.

392
00:17:36,140 --> 00:17:38,462
Now, interesting little factoid here.

393
00:17:38,462 --> 00:17:41,053
A lot of times, people
think only interfaces

394
00:17:41,053 --> 00:17:45,247
that are actually up/up are candidates

395
00:17:45,247 --> 00:17:46,511
for the router-id.

396
00:17:46,511 --> 00:17:48,287
That's not actually true.

397
00:17:48,287 --> 00:17:51,511
Even an interface that
is up/down or down/down

398
00:17:51,511 --> 00:17:53,383
is a candidate for router-id.

399
00:17:53,383 --> 00:17:56,249
The only time there's an
IP address on an interface

400
00:17:56,249 --> 00:17:57,863
and OSPF says, "I can't use that.

401
00:17:57,863 --> 00:17:59,654
"I can't even consider that,"

402
00:17:59,654 --> 00:18:03,754
is if the interface is
administratively disabled,

403
00:18:03,754 --> 00:18:05,672
if it is shut down.

404
00:18:05,672 --> 00:18:09,485
Other than that, the IP address
could potentially be used

405
00:18:09,485 --> 00:18:13,925
as the router-id depending
on if it's not a loopback

406
00:18:13,925 --> 00:18:17,121
and if it's the highest
IP address on the box.

407
00:18:17,121 --> 00:18:21,501
So, that ends this video on
the OSPF designated router

408
00:18:21,501 --> 00:18:24,584
and backup designated router process.

409
00:18:34,346 --> 00:18:38,096
(lightning crackling jingle)

