WEBVTT

0:00:03.180000 --> 0:00:07.940000
 Hello and welcome this video on a review
 of how to implement OSPF in Cisco

0:00:07.940000 --> 0:00:11.420000
 IOS. I'm going to show you the basic
 commands to turn it on and verify

0:00:11.420000 --> 0:00:13.220000
 that it's working.

0:00:13.220000 --> 0:00:20.120000
 All right, so step number one, there's
 actually a couple of ways you can

0:00:20.120000 --> 0:00:25.620000
 go about this for a couple of decades
 after OSPF first came out.

0:00:25.620000 --> 0:00:30.360000
 The way to do it which we now consider
 as a legacy method, was you first

0:00:30.360000 --> 0:00:35.740000
 went to your global configuration level
 and you started your OSPF process.

0:00:35.740000 --> 0:00:39.740000
 So you would say router OSPF and
 then type in a process ID.

0:00:39.740000 --> 0:00:44.620000
 Now this process ID, people typically
 start with number one, like router

0:00:44.620000 --> 0:00:48.300000
 OSPF one. It can be
 anything you want.

0:00:48.300000 --> 0:00:52.640000
 I mean within reason if you do router
 OSPF question mark, it'll show you

0:00:52.640000 --> 0:00:54.800000
 the range of numbers
 you can select from.

0:00:54.800000 --> 0:00:59.460000
 But the point is, whatever process ID
 you select, this is not something

0:00:59.460000 --> 0:01:01.540000
 you exchange with other routers.

0:01:01.540000 --> 0:01:05.340000
 This number is only something that
 your own local router knows about.

0:01:05.340000 --> 0:01:08.340000
 We call that a locally
 significant value.

0:01:08.340000 --> 0:01:12.160000
 So one router could be router OSPF
 one, another router could be router

0:01:12.160000 --> 0:01:16.260000
 OSPF seven. It doesn't matter, it's
 not going to influence how they do

0:01:16.260000 --> 0:01:21.040000
 OSPF. But from a practical standpoint,
 if you start doing that having

0:01:21.040000 --> 0:01:25.640000
 router OSPF one, router OSPF seven, router
 OSPF 32, if anybody else jumps

0:01:25.640000 --> 0:01:29.340000
 on your routers and they do a show run
 and they look at the show run output,

0:01:29.340000 --> 0:01:30.720000
 it might confuse them.

0:01:30.720000 --> 0:01:37.280000
 They might think, is there some reason
 why this one is one, 17, 32, 220?

0:01:37.280000 --> 0:01:39.180000
 So you don't want to confuse them.


0:01:39.180000 --> 0:01:42.100000
 You don't want to make them think that
 there's something more to that

0:01:42.100000 --> 0:01:44.100000
 number than there actually is.

0:01:44.100000 --> 0:01:47.400000
 So most people just usually pick a
 number, like I said, usually number

0:01:47.400000 --> 0:01:51.720000
 one and you just have all the routers
 configured as router OSPF one.

0:01:51.720000 --> 0:01:56.300000
 Once you do that, then it drops you
 down into config-router mode.

0:01:56.300000 --> 0:02:00.200000
 And now here is where you activate
 OSPF on your various interfaces.

0:02:00.200000 --> 0:02:04.760000
 So for example, if this was my router
 right here and you had two interfaces,

0:02:04.760000 --> 0:02:15.740000
 let's say this was the 2.2.2.2.2
.24 and this was 70.70.1.1.1.16.

0:02:15.740000 --> 0:02:22.980000
 Well, if I want to activate OSPF on
 the 2.2 interface right there, then

0:02:22.980000 --> 0:02:24.340000
 I would say network.

0:02:24.340000 --> 0:02:25.940000
 Now you have a couple
 of options here.

0:02:25.940000 --> 0:02:29.220000
 You could actually type in the network
 itself, like we know that with

0:02:29.220000 --> 0:02:33.900000
 this subnet mask, the
 network is 2.2.2.0.

0:02:33.900000 --> 0:02:34.860000
 You could do that.

0:02:34.860000 --> 0:02:39.420000
 And then if you want to do that, you
 would add a wildcard mask after that,

0:02:39.420000 --> 0:02:42.660000
 which would be 0.0.0.255.

0:02:42.660000 --> 0:02:47.120000
 Remember that a wildcard mask is basically
 the inverse of a subnet mask.

0:02:47.120000 --> 0:02:50.780000
 Slash 24 means 255, 255, 255, 0.

0:02:50.780000 --> 0:02:52.780000
 Well, a wildcard mask is just
 the opposite of that.

0:02:52.780000 --> 0:02:54.040000
 You can absolutely do that.

0:02:54.040000 --> 0:02:59.060000
 Or another viable alternative that
 a lot of people do is they actually

0:02:59.060000 --> 0:03:03.280000
 put in the actual host IP address on
 their router and then they put in

0:03:03.280000 --> 0:03:05.900000
 a wildcard mask of all zeros.

0:03:05.900000 --> 0:03:08.040000
 That will work as well.

0:03:08.040000 --> 0:03:12.980000
 So you've got to put in something in
 a wildcard mask, but how specific

0:03:12.980000 --> 0:03:19.640000
 or how less specific that wildcard
 mask is is completely up to you.

0:03:19.640000 --> 0:03:23.900000
 The main point is the network statement
 is what OSPF uses to look around

0:03:23.900000 --> 0:03:28.300000
 and say, OK, do I have any interfaces
 that have that network?

0:03:28.300000 --> 0:03:32.960000
 If I do, I can activate OSPF on those
 interfaces, and I can include that

0:03:32.960000 --> 0:03:35.520000
 network in my LSA.

0:03:35.520000 --> 0:03:39.300000
 Now, like I said, that's more
 of the legacy method.

0:03:39.300000 --> 0:03:42.780000
 Typically, the newer and more current
 method is that you don't even have

0:03:42.780000 --> 0:03:44.400000
 to do this stuff at all.

0:03:44.400000 --> 0:03:48.780000
 You just go right to the interface,
 like interface gigabit 0 slash 1,

0:03:48.780000 --> 0:03:50.840000
 and you activate OSPF right there.


0:03:50.840000 --> 0:03:56.220000
 You say IP OSPF 1 area 0
 or something like that.

0:03:56.220000 --> 0:03:59.780000
 And if you don't already have a router
 OSPF process, this will dynamically

0:03:59.780000 --> 0:04:03.300000
 create one for you.

0:04:03.300000 --> 0:04:08.200000
 And this way, you don't have to worry
 about wildcard masks either, which

0:04:08.200000 --> 0:04:09.540000
 is kind of nice.

0:04:09.540000 --> 0:04:16.240000
 OK, now, like I mentioned, when you
 when you enable OSPF directly on an

0:04:16.240000 --> 0:04:21.320000
 interface or use the network command
 to reference an interface, that means

0:04:21.320000 --> 0:04:24.640000
 that OSPF is going to start sending
 out hello packets on that interface.

0:04:24.640000 --> 0:04:28.220000
 Now, sometimes you don't
 want OSPF to do that.

0:04:28.220000 --> 0:04:38.780000
 For example, let's say that you had
 two routers right here and they were

0:04:38.780000 --> 0:04:45.440000
 connected via a trunk.

0:04:45.440000 --> 0:04:50.160000
 So these routers are using multiple sub
 interfaces to talk to each other.

0:04:50.160000 --> 0:04:56.500000
 Maybe this line right here represents
 fast ethernet 0 slash 0 dot 1.

0:04:56.500000 --> 0:05:02.940000
 This line right here represents fast
 ethernet 0 slash 0 dot 2 and so on

0:05:02.940000 --> 0:05:08.360000
 and so forth. Fast ethernet
 0 slash 0 dot 3.

0:05:08.360000 --> 0:05:12.740000
 OK, now, let's just put a couple
 of networks on here.

0:05:12.740000 --> 0:05:17.860000
 Let's say that the the pink line is
 the 1 dot 1 dot 1 dot 0 network.

0:05:17.860000 --> 0:05:24.900000
 And let's say that the blue line was
 the 2 dot 2 dot 2 dot 0 network.

0:05:24.900000 --> 0:05:31.620000
 OK, if I went into each of these sub
 interfaces and I did IP OSPF 1 area

0:05:31.620000 --> 0:05:37.060000
 0, the next sub interface, IP OSPF 1
 area 0, or I used a couple of network

0:05:37.060000 --> 0:05:41.460000
 statements. Network 1 dot 1 dot 1 dot
 0 and then my wild card network

0:05:41.460000 --> 0:05:46.660000
 2, 2, 2, 2, then that means that OSPF
 Hello's in this case, because I

0:05:46.660000 --> 0:05:47.520000
 have three sub interfaces.

0:05:47.520000 --> 0:05:52.260000
 If I did that on all three of them, that
 means OSPF Hello's would go across

0:05:52.260000 --> 0:05:55.180000
 that one physical
 link three times.

0:05:55.180000 --> 0:06:00.100000
 We'd have an OSPF adjacency formed across
 the 1, 1, 1 network across the

0:06:00.100000 --> 0:06:03.460000
 2, 2, 2 network and across
 the 3, 3, 3 network.

0:06:03.460000 --> 0:06:11.720000
 On the bottom. Well, certainly we want
 those routers to, you know, they're

0:06:11.720000 --> 0:06:13.280000
 directly connected, right?

0:06:13.280000 --> 0:06:16.360000
 They don't need to learn that, hey, I'm
 direct, that my neighbors connected

0:06:16.360000 --> 0:06:21.860000
 to this. We really just need one OSPF
 neighbor relationship between these

0:06:21.860000 --> 0:06:24.500000
 routers, because there's
 just one link here.

0:06:24.500000 --> 0:06:28.760000
 OK, as long as one set of Hello's is
 going back and forth, that's good

0:06:28.760000 --> 0:06:32.980000
 enough. If they form, for example, if they
 form just one neighbor relationship

0:06:32.980000 --> 0:06:37.540000
 across the pink sub interface, the 1,
 1, 1, 0 interface, once that neighbor

0:06:37.540000 --> 0:06:44.960000
 relationship is formed, and let's
 just say router 1 sends an LSA.

0:06:44.960000 --> 0:06:48.900000
 So let's just say right here, going
 across the pink sub interface, this

0:06:48.900000 --> 0:06:51.020000
 is a link state update.

0:06:51.020000 --> 0:06:59.780000
 And inside there, he's got his
 router LSA describing himself.

0:06:59.780000 --> 0:07:03.080000
 Well, if we assume that all these sub
 interfaces are in the exact same

0:07:03.080000 --> 0:07:08.100000
 area, which they probably are, that
 one router LSA will say, hey, router

0:07:08.100000 --> 0:07:10.520000
 2, let me tell you about myself.

0:07:10.520000 --> 0:07:15.220000
 My name is router 1, and I have these
 links I'm connected to, the 1, 1,

0:07:15.220000 --> 0:07:17.220000
 1, the 2, 2, 2, the 3, 3, 3.

0:07:17.220000 --> 0:07:20.820000
 Then router 2 will say, oh,
 hey, how funny is that?

0:07:20.820000 --> 0:07:22.300000
 I've got the same links.

0:07:22.300000 --> 0:07:25.620000
 So they will learn about each other,
 they will learn about what links

0:07:25.620000 --> 0:07:30.520000
 they have, and they did not need three
 simultaneous neighbor relationships

0:07:30.520000 --> 0:07:34.320000
 across one physical cable
 in order to do that.

0:07:34.320000 --> 0:07:37.340000
 So how do we suppress those
 neighbor relationships?

0:07:37.340000 --> 0:07:41.740000
 How do we tell OSPF, for example,
 on router 2 over here?

0:07:41.740000 --> 0:07:45.860000
 How do we tell him, hey, I want you
 to form a neighbor relationship on

0:07:45.860000 --> 0:07:55.620000
 fastEthernet 0 slash 0 dot 1, but don't
 send out hellos on 0 slash 0 dot

0:07:55.620000 --> 0:08:01.040000
 2 We use a feature that's common to all
 routing protocols, which is called

0:08:01.040000 --> 0:08:02.960000
 passive interface.

0:08:02.960000 --> 0:08:08.280000
 When you make an interface passive, it
 suppresses hellos from going across

0:08:08.280000 --> 0:08:13.680000
 that interface. Like in this example right
 here, on the router X is fastEthernet

0:08:13.680000 --> 0:08:18.400000
 0, 0, we do want that network advertised
 up to the cloud, the cloud needs

0:08:18.400000 --> 0:08:22.500000
 to know about that within an LSA, but
 router X doesn't really have any

0:08:22.500000 --> 0:08:26.460000
 need to send an OSPF
 hello down this way.

0:08:26.460000 --> 0:08:28.980000
 There's just PCs and
 laptops down there.

0:08:28.980000 --> 0:08:35.400000
 So when we make passive interface fastEthernet
 0, 0, now that says, okay,

0:08:35.400000 --> 0:08:37.120000
 you can still advertise that.

0:08:37.120000 --> 0:08:39.420000
 Right now we're assuming we had
 a network statement, right?

0:08:39.420000 --> 0:08:46.100000
 If this was the 3, 3, 3, 0 network,
 we're assuming that we did one of

0:08:46.100000 --> 0:08:51.380000
 two things. We either went interface
 fastEthernet 0 slash 0, and then

0:08:51.380000 --> 0:08:53.960000
 we enabled OSPF.

0:08:53.960000 --> 0:09:06.980000
 Area 0. Okay, we did that way, or we
 did router OSPF 1, and then we used

0:09:06.980000 --> 0:09:13.980000
 a network statement network
 3, 3, 3, 0, 0, 0, 0, 2, 55.

0:09:13.980000 --> 0:09:21.600000
 Area 0. We have to do one of those two
 things to tell OSPF, hey, include

0:09:21.600000 --> 0:09:25.600000
 this network in your LSA,
 in your link state update.

0:09:25.600000 --> 0:09:31.040000
 But by making it passive, we say, hey,
 just don't send hellos out there.

0:09:31.040000 --> 0:09:34.060000
 There's nobody to talk to, there's nobody
 to form a neighbor relationship

0:09:34.060000 --> 0:09:35.940000
 without there, just don't do it.

0:09:35.940000 --> 0:09:39.180000
 So just like in my previous whiteboarding
 example, we could do the same

0:09:39.180000 --> 0:09:40.660000
 thing on our subinterfaces.

0:09:40.660000 --> 0:09:45.640000
 I could say passive dash interface fastEthernet
 0 slash 0, 0 dot 2, passive

0:09:45.640000 --> 0:09:49.080000
 dash interface fastEthernet
 0 slash 0 dot 3.

0:09:49.080000 --> 0:09:54.280000
 And now we would not form multiple simultaneous
 OSPF adjacencies between

0:09:54.280000 --> 0:09:57.780000
 the same two routers across
 the same cable.

0:09:57.780000 --> 0:10:04.860000
 All right, we talked
 about the router ID.

0:10:04.860000 --> 0:10:09.820000
 So within your router OSPF process,
 here's how you can deterministically

0:10:09.820000 --> 0:10:12.020000
 set the router ID
 with the command.

0:10:12.020000 --> 0:10:17.660000
 You can also do the show IP OSPF command
 to see what your router ID is.

0:10:17.660000 --> 0:10:22.980000
 And that last bullet point
 is also important.

0:10:22.980000 --> 0:10:29.380000
 Once a router figures out his router
 ID, even if you try to reconfigure

0:10:29.380000 --> 0:10:31.600000
 it, he's not going to
 change it on the fly.

0:10:31.600000 --> 0:10:35.700000
 For example, let's just
 take a look right here.

0:10:35.700000 --> 0:10:43.800000
 Show IP OSPF. All right, so we can
 see this router has formed a router

0:10:43.800000 --> 0:10:47.740000
 ID of 122.122.2.

0:10:47.740000 --> 0:10:50.040000
 I say, oh, no, I don't want that.

0:10:50.040000 --> 0:10:52.680000
 I want you to be a 777.

0:10:52.680000 --> 0:11:04.400000
 So I say router OSPF1
 router dash ID 777.

0:11:04.400000 --> 0:11:09.300000
 Now, this is kind of interesting because
 usually what I see is the moment

0:11:09.300000 --> 0:11:16.400000
 I give it a router ID command, it'll
 give me a warning and say, you know,

0:11:16.400000 --> 0:11:20.800000
 you must clear the OSPF process or
 restart in order for new router ID

0:11:20.800000 --> 0:11:23.900000
 to take effect. Here's what
 I think is happening.

0:11:23.900000 --> 0:11:27.580000
 This particular router doesn't
 have any neighbors.

0:11:27.580000 --> 0:11:31.460000
 See, no neighbors.

0:11:31.460000 --> 0:11:35.720000
 So as long as he doesn't have neighbors,
 I think I can change the router

0:11:35.720000 --> 0:11:38.120000
 ID. Yep, see right here?

0:11:38.120000 --> 0:11:40.640000
 I can change on the fly
 without a problem.

0:11:40.640000 --> 0:11:44.980000
 But the moment he forms a neighbor relationship
 with anybody else, then

0:11:44.980000 --> 0:11:48.580000
 he will not allow me to do that.

0:11:48.580000 --> 0:12:08.340000
 So let's just quickly form a neighbor
 relationship so we can do this here.

0:12:08.340000 --> 0:12:18.020000
 All right. Show IP
 interface brief.

0:12:18.020000 --> 0:12:44.480000
 Okay, I think I've got the wrong
 IP address on somebody.

0:12:44.480000 --> 0:12:47.480000
 So just to show you what
 I'm doing at this point.

0:12:47.480000 --> 0:12:50.000000
 Okay, neighbor relationship
 is built.

0:12:50.000000 --> 0:12:53.020000
 So we had router two.

0:12:53.020000 --> 0:12:59.980000
 And I had enabled OSPF on his
 gig zero slash one interface.

0:12:59.980000 --> 0:13:04.860000
 Which was configured for something
 like 122 dot something.

0:13:04.860000 --> 0:13:08.240000
 Well, he hadn't formed any
 neighbor relationship yet.

0:13:08.240000 --> 0:13:11.560000
 That's why he was allowing me to change
 the router ID without any warnings

0:13:11.560000 --> 0:13:15.620000
 or complaints. So I decided, oh, okay,
 well, I know on the other side

0:13:15.620000 --> 0:13:18.180000
 of this link is another router.

0:13:18.180000 --> 0:13:24.000000
 CSR one. Let's just form a neighbor
 relationship with him.

0:13:24.000000 --> 0:13:27.580000
 So I activated OSPF on
 this interface as well.

0:13:27.580000 --> 0:13:29.660000
 Neighbor relationship
 was not forming.

0:13:29.660000 --> 0:13:32.640000
 And the reason for that was their
 IP addresses were mismatched.

0:13:32.640000 --> 0:13:37.020000
 This guy was configured
 as 21 21 21 dot one.

0:13:37.020000 --> 0:13:39.080000
 Which was completely wrong
 with the other side.

0:13:39.080000 --> 0:13:43.060000
 So I had to go to this side
 and make him match.

0:13:43.060000 --> 0:13:48.020000
 And then the OSPF neighbor
 relationship came up.

0:13:48.020000 --> 0:13:53.180000
 Okay, right now we're having a network
 type mismatch because in a previous

0:13:53.180000 --> 0:13:58.600000
 video. I actually changed the
 network type on his interface.

0:13:58.600000 --> 0:14:03.640000
 The default is broadcast and I told
 him it should be point to point.

0:14:03.640000 --> 0:14:06.140000
 So they do need to match.

0:14:06.140000 --> 0:14:24.340000
 Okay. So now if you do
 show IP OSPF neighbor.

0:14:24.340000 --> 0:14:27.460000
 We see we do have a neighbor as it
 so happens the neighbor on the left

0:14:27.460000 --> 0:14:30.640000
 CSR one is our designated router.

0:14:30.640000 --> 0:14:37.400000
 And so now if I try to change the router
 ID router OSPF one router dash

0:14:37.400000 --> 0:14:40.240000
 ID, let's just make
 it two two two two.

0:14:40.240000 --> 0:14:42.440000
 Now I get that warning.

0:14:42.440000 --> 0:14:46.800000
 It says, Hey, everybody already knows
 me as seven seven seven seven.

0:14:46.800000 --> 0:14:49.000000
 Everybody's already got
 my LSA out there.

0:14:49.000000 --> 0:14:53.300000
 If I change my router ID, that means
 I'm going to have to tell them that

0:14:53.300000 --> 0:14:56.280000
 old LSA is bad in what's
 called poisoning it.

0:14:56.280000 --> 0:14:58.240000
 I'm going to poison the old LSA.

0:14:58.240000 --> 0:15:01.160000
 Now I'm going to have to resend
 a new LSA with my new name.

0:15:01.160000 --> 0:15:04.720000
 That's going to be very intrusive
 for me and everybody else.

0:15:04.720000 --> 0:15:08.640000
 If you want me to do that, you really
 got to be sure and you have to clear

0:15:08.640000 --> 0:15:09.840000
 the OSPF process.

0:15:09.840000 --> 0:15:12.160000
 You have to restart everything
 from scratch.

0:15:12.160000 --> 0:15:16.160000
 I say, Okay, see right
 now do show IP OSPF.

0:15:16.160000 --> 0:15:20.880000
 He's still using seven seven seven seven
 seven even though I configured

0:15:20.880000 --> 0:15:25.300000
 this. Yes. So in order for him to take
 that over, I have to type in clear

0:15:25.300000 --> 0:15:27.460000
 IP OSPF process.

0:15:27.460000 --> 0:15:30.160000
 Well, I got to get out
 of config mode first.

0:15:30.160000 --> 0:15:37.940000
 Yes. So now he's going to tear down
 his relationship with CSR one.

0:15:37.940000 --> 0:15:41.420000
 There it goes. He'll
 rebuild it again.

0:15:41.420000 --> 0:15:45.340000
 And while he's doing that.

0:15:45.340000 --> 0:15:48.960000
 Oh, that's not what I want.

0:15:48.960000 --> 0:15:54.800000
 All right, let's just do it.

0:15:54.800000 --> 0:15:57.440000
 So show IP OSPF.

0:15:57.440000 --> 0:16:02.280000
 Now we can see that because
 I restart the process.

0:16:02.280000 --> 0:16:13.420000
 Now he was able to take on that new router
 ID that we were talking about.

0:16:13.420000 --> 0:16:17.200000
 Who talked about using the
 IP OSPF priority command.

0:16:17.200000 --> 0:16:20.580000
 But like I said, that
 is not preemptive.

0:16:20.580000 --> 0:16:28.060000
 What do I mean by that show
 show IP OSPF neighbor.

0:16:28.060000 --> 0:16:31.440000
 Notice that my neighbor
 on gig zero one.

0:16:31.440000 --> 0:16:33.280000
 He is the designated router.

0:16:33.280000 --> 0:16:37.080000
 I say, well, I'll show you interface
 gigabit zero slash one.

0:16:37.080000 --> 0:16:39.440000
 Okay. So he's got
 a priority of one.

0:16:39.440000 --> 0:16:43.080000
 All right. IP OSPF priority.

0:16:43.080000 --> 0:16:51.940000
 About 200. That should make me
 the designated router, right?

0:16:51.940000 --> 0:16:57.120000
 Nope, it does not.

0:16:57.120000 --> 0:17:00.680000
 And if we go over to the other guy, you
 say, well, hey, Keith, maybe he's

0:17:00.680000 --> 0:17:02.380000
 not seeing you as 200.

0:17:02.380000 --> 0:17:05.140000
 Right? Maybe he maybe he
 didn't take that command.

0:17:05.140000 --> 0:17:08.720000
 Yeah, he took the command.

0:17:08.720000 --> 0:17:13.480000
 Right on this guy says, Hey, all the
 router, you're the backup Disney

0:17:13.480000 --> 0:17:16.960000
 router. Hey, even though you got a higher
 priority than me, I beat you.

0:17:16.960000 --> 0:17:18.920000
 I became the Disney
 router before you.

0:17:18.920000 --> 0:17:23.320000
 So you can't take it over for me.

0:17:23.320000 --> 0:17:28.840000
 And we've just looked
 at those commands.

0:17:28.840000 --> 0:17:33.380000
 So thank you for watching this video
 that concludes this video on the

0:17:33.380000 --> 0:17:37.440000
 initial implementation
 of OSPF in Cisco iOS.

