1
1

00:00:00,600  -->  00:00:02,270
<v ->The last topic we need to talk about</v>
2

2

00:00:02,270  -->  00:00:05,790
in this routing section is how multicast routing works.
3

3

00:00:05,790  -->  00:00:08,080
Now, multicast routing is when you send traffic
4

4

00:00:08,080  -->  00:00:12,020
to a class D IP address, known as the multicast group.
5

5

00:00:12,020  -->  00:00:15,050
Now, our goal here is for us only to send traffic out once
6

6

00:00:15,050  -->  00:00:16,240
and then have all of the devices
7

7

00:00:16,240  -->  00:00:18,320
who want to get that information,
8

8

00:00:18,320  -->  00:00:21,120
and anybody who doesn't want to get it, doesn't get it.
9

9

00:00:21,120  -->  00:00:23,520
Now, there are two primary ways of doing this.
10

10

00:00:23,520  -->  00:00:25,510
The first is known as IGMP,
11

11

00:00:25,510  -->  00:00:27,840
or the Internet Group Management Protocol.
12

12

00:00:27,840  -->  00:00:31,980
The second is PIM, or Protocol Independent Multicast.
13

13

00:00:31,980  -->  00:00:35,150
We'll cover both of those in detail in this lesson.
14

14

00:00:35,150  -->  00:00:38,310
Now, IGMP, or the Internet Group Management Protocol,
15

15

00:00:38,310  -->  00:00:39,930
is used by clients and routers
16

16

00:00:39,930  -->  00:00:41,730
so that the routers know which interfaces
17

17

00:00:41,730  -->  00:00:43,603
have multicast receivers on them.
18

18

00:00:43,603  -->  00:00:45,955
This allows a client to join a multicast group
19

19

00:00:45,955  -->  00:00:48,750
and then be able to receive messages that they wanted to get
20

20

00:00:48,750  -->  00:00:50,380
through this multicast group.
21

21

00:00:50,380  -->  00:00:52,900
Now, there are three variants of IGMP.
22

22

00:00:52,900  -->  00:00:55,540
The first one was IGMPv1.
23

23

00:00:55,540  -->  00:00:58,530
And then it was improved to version two and version three.
24

24

00:00:58,530  -->  00:00:59,650
Now in version one,
25

25

00:00:59,650  -->  00:01:01,310
clients could request joining the group
26

26

00:01:01,310  -->  00:01:04,510
and every 60 seconds, their router would go back and say,
27

27

00:01:04,510  -->  00:01:06,493
do you still want to be here? Do you still want to be here?
28

28

00:01:06,493  -->  00:01:07,697
Do you still want to be here?
29

29

00:01:07,697  -->  00:01:09,020
And you could see how that causes
30

30

00:01:09,020  -->  00:01:10,910
a lot of unnecessary traffic.
31

31

00:01:10,910  -->  00:01:12,910
In version two, clients had the ability
32

32

00:01:12,910  -->  00:01:16,070
to send leave messages to exit the group when they wanted.
33

33

00:01:16,070  -->  00:01:18,120
Essentially now, the router's just going to assume
34

34

00:01:18,120  -->  00:01:19,700
you want to be there until you told it
35

35

00:01:19,700  -->  00:01:21,290
that you didn't want to be there.
36

36

00:01:21,290  -->  00:01:22,870
Finally, in version three,
37

37

00:01:22,870  -->  00:01:24,560
the client could request a multicast
38

38

00:01:24,560  -->  00:01:27,040
from only a specific server and then choose,
39

39

00:01:27,040  -->  00:01:29,060
did I want to get my messages from one server
40

40

00:01:29,060  -->  00:01:30,500
and not from server two?
41

41

00:01:30,500  -->  00:01:31,610
That was allowed.
42

42

00:01:31,610  -->  00:01:34,130
It would also allow for source specific multicast,
43

43

00:01:34,130  -->  00:01:36,340
which is what this server request was called.
44

44

00:01:36,340  -->  00:01:38,610
Now, this allowed us to have multiple video streams
45

45

00:01:38,610  -->  00:01:40,810
to a single multicast stream.
46

46

00:01:40,810  -->  00:01:42,810
Now, almost like you'd have with cable TV,
47

47

00:01:42,810  -->  00:01:44,790
where you could dial into the channel you wanted,
48

48

00:01:44,790  -->  00:01:46,760
that's kind of what we were doing here digitally,
49

49

00:01:46,760  -->  00:01:48,980
using the IGMP protocol.
50

50

00:01:48,980  -->  00:01:51,220
So how did IGMP work?
51

51

00:01:51,220  -->  00:01:53,010
Well, let's look at this diagram.
52

52

00:01:53,010  -->  00:01:55,420
If I have a server that wants to send out traffic,
53

53

00:01:55,420  -->  00:01:56,930
it's going to send it to the router
54

54

00:01:56,930  -->  00:01:59,480
and the IP address of the multicast group.
55

55

00:01:59,480  -->  00:02:03,600
In this case, 239.2.1.3.
56

56

00:02:03,600  -->  00:02:05,970
Right now, the router is not sending it anywhere,
57

57

00:02:05,970  -->  00:02:08,290
'cause nobody's requested that information.
58

58

00:02:08,290  -->  00:02:11,720
But if PC2 sends a request message to router one,
59

59

00:02:11,720  -->  00:02:13,945
now router one is going to remember that PC2
60

60

00:02:13,945  -->  00:02:16,094
wants to be a part of this multicast group,
61

61

00:02:16,094  -->  00:02:18,720
and anything it gets as part of this multicast group
62

62

00:02:18,720  -->  00:02:21,300
will now be sent over to PC2 as well.
63

63

00:02:21,300  -->  00:02:22,850
And only going to go to PC2,
64

64

00:02:22,850  -->  00:02:25,270
because remember, PC1 and PC3
65

65

00:02:25,270  -->  00:02:26,932
didn't ask to be a part of this group.
66

66

00:02:26,932  -->  00:02:29,430
So hopefully you can see the benefits of this now.
67

67

00:02:29,430  -->  00:02:30,550
In this example here,
68

68

00:02:30,550  -->  00:02:34,050
we have PC1 and PC3 that wanted to be in there
69

69

00:02:34,050  -->  00:02:35,730
and they could join the group as well.
70

70

00:02:35,730  -->  00:02:38,500
And then the server can send it out to all three people
71

71

00:02:38,500  -->  00:02:41,200
with only one copy of the message being sent in.
72

72

00:02:41,200  -->  00:02:42,636
That's the benefit of this.
73

73

00:02:42,636  -->  00:02:44,880
The second thing we want to look at is PIM,
74

74

00:02:44,880  -->  00:02:47,100
or the Protocol Independent Multicast.
75

75

00:02:47,100  -->  00:02:49,890
PIM is going to allow multicast traffic to be routed
76

76

00:02:49,890  -->  00:02:52,110
between multicast enabled routers.
77

77

00:02:52,110  -->  00:02:55,360
Multicast routing forms this multicast distribution tree,
78

78

00:02:55,360  -->  00:02:57,550
and it really works between all these different routers
79

79

00:02:57,550  -->  00:02:59,360
together because IGMP
80

80

00:02:59,360  -->  00:03:01,320
was more about clients and servers together,
81

81

00:03:01,320  -->  00:03:04,880
where PIM is much more focused on the routing part of this.
82

82

00:03:04,880  -->  00:03:07,180
Now, there are two different modes in PIM.
83

83

00:03:07,180  -->  00:03:09,500
There's a PIM-DM, which is the Dense Mode,
84

84

00:03:09,500  -->  00:03:12,010
or PIM-SM or Sparse Mode.
85

85

00:03:12,010  -->  00:03:14,950
In Dense Mode, we're going to use a periodic flood and prune
86

86

00:03:14,950  -->  00:03:17,520
behavior to form an optimal distribution tree
87

87

00:03:17,520  -->  00:03:19,070
across these routers.
88

88

00:03:19,070  -->  00:03:21,400
And this can actually cause a negative performance impact
89

89

00:03:21,400  -->  00:03:24,000
on your network, and because of this, in modern networks,
90

90

00:03:24,000  -->  00:03:25,860
we really don't use it.
91

91

00:03:25,860  -->  00:03:28,160
Instead, we tend to use Sparse Mode.
92

92

00:03:28,160  -->  00:03:30,280
With PIM-SM, or Sparse Mode,
93

93

00:03:30,280  -->  00:03:32,960
this is going to use a shared distribution tree initially,
94

94

00:03:32,960  -->  00:03:36,380
and then it's going to, over time, find the best tree.
95

95

00:03:36,380  -->  00:03:37,490
Now, when we start out,
96

96

00:03:37,490  -->  00:03:40,980
that shared distribution tree is not optimal, but over time,
97

97

00:03:40,980  -->  00:03:42,720
we're going to learn where the best tree is,
98

98

00:03:42,720  -->  00:03:45,350
and then start switching over to the Shortest Path Tree,
99

99

00:03:45,350  -->  00:03:49,340
or SPT, once it determines what that actually is.
100

100

00:03:49,340  -->  00:03:50,900
Now, I know that's a lot of words.
101

101

00:03:50,900  -->  00:03:52,530
So let's take a look at some pictures
102

102

00:03:52,530  -->  00:03:55,020
to hopefully understand how this works a little better.
103

103

00:03:55,020  -->  00:03:58,090
Here you can see PIM-DM or Dense Mode.
104

104

00:03:58,090  -->  00:03:59,780
Now, what happens in Dense Mode is,
105

105

00:03:59,780  -->  00:04:02,260
to begin with, it has this flooding procedure
106

106

00:04:02,260  -->  00:04:03,640
where all of the routers,
107

107

00:04:03,640  -->  00:04:05,150
every router in this entire network,
108

108

00:04:05,150  -->  00:04:07,030
is getting all of the information.
109

109

00:04:07,030  -->  00:04:08,990
Now, as you can see, that's a lot of traffic,
110

110

00:04:08,990  -->  00:04:11,780
but we do already have the optimal way of getting there
111

111

00:04:11,780  -->  00:04:15,270
from that multicast source to the multicast destination,
112

112

00:04:15,270  -->  00:04:18,690
because it comes all at once with that big flood.
113

113

00:04:18,690  -->  00:04:21,040
So in this case, it would be going down the left side
114

114

00:04:21,040  -->  00:04:22,310
of that pyramid.
115

115

00:04:22,310  -->  00:04:23,380
Now, as we go through,
116

116

00:04:23,380  -->  00:04:26,010
it's going to then prune off all the non-optimal routes,
117

117

00:04:26,010  -->  00:04:28,690
which in this case is all the routers off to the right.
118

118

00:04:28,690  -->  00:04:30,270
It sends out this prune message saying,
119

119

00:04:30,270  -->  00:04:31,980
hey, I don't need this traffic.
120

120

00:04:31,980  -->  00:04:34,800
I'm not part of the optical route. Get me out of here.
121

121

00:04:34,800  -->  00:04:35,633
And that way,
122

122

00:04:35,633  -->  00:04:37,800
they can go ahead and drop those from the route.
123

123

00:04:37,800  -->  00:04:39,870
Now, after sending all these pruning messages,
124

124

00:04:39,870  -->  00:04:41,230
we now have the optimal path
125

125

00:04:41,230  -->  00:04:44,000
between the source router and the last hop router,
126

126

00:04:44,000  -->  00:04:46,690
giving us the quickest and easiest path.
127

127

00:04:46,690  -->  00:04:48,920
Now, this is the idea of flood and prune.
128

128

00:04:48,920  -->  00:04:50,800
And this happens every three minutes,
129

129

00:04:50,800  -->  00:04:52,570
trying to find a more optimal route,
130

130

00:04:52,570  -->  00:04:54,980
which again, can cause a really big performance hit
131

131

00:04:54,980  -->  00:04:56,790
to your network, because we're flooding it
132

132

00:04:56,790  -->  00:04:58,200
every three minutes.
133

133

00:04:58,200  -->  00:05:00,640
And this is why we don't really use it much anymore.
134

134

00:05:00,640  -->  00:05:02,940
Instead we use Sparse Mode.
135

135

00:05:02,940  -->  00:05:05,340
Now Sparse Mode, or PIM-SM,
136

136

00:05:05,340  -->  00:05:07,710
is going to use a shared distribution tree.
137

137

00:05:07,710  -->  00:05:10,360
Essentially, when the server sends out the first message,
138

138

00:05:10,360  -->  00:05:12,610
the router's going to send it over any way it can
139

139

00:05:12,610  -->  00:05:15,700
to get it from the first router down to the last hop.
140

140

00:05:15,700  -->  00:05:17,260
In this case, it's going to be sending it
141

141

00:05:17,260  -->  00:05:19,010
to this rendezvous point first,
142

142

00:05:19,010  -->  00:05:21,230
and then down to last router hop.
143

143

00:05:21,230  -->  00:05:22,910
Now, this isn't the optimal path,
144

144

00:05:22,910  -->  00:05:25,340
but it is a path and that's okay and it works.
145

145

00:05:25,340  -->  00:05:27,840
And so this information is going to start to flow.
146

146

00:05:27,840  -->  00:05:28,800
As you can see,
147

147

00:05:28,800  -->  00:05:31,780
there are four of the six routers that got the information.
148

148

00:05:31,780  -->  00:05:34,130
Two of them weren't even bothered to get the information,
149

149

00:05:34,130  -->  00:05:35,900
and so they saved all that resources,
150

150

00:05:35,900  -->  00:05:37,580
because they weren't being flooded.
151

151

00:05:37,580  -->  00:05:40,630
Now, over time, we figured out this was a sub optimal path,
152

152

00:05:40,630  -->  00:05:42,260
and instead, it would be a lot quicker
153

153

00:05:42,260  -->  00:05:44,380
to go down the left-hand side of the diagram.
154

154

00:05:44,380  -->  00:05:46,370
So, we're going to start switching over to that,
155

155

00:05:46,370  -->  00:05:48,250
getting rid of all these unused branches
156

156

00:05:48,250  -->  00:05:51,340
and then going to the Shortest Path Tree, the SPT,
157

157

00:05:51,340  -->  00:05:53,160
and that now gives us the optimal tree
158

158

00:05:53,160  -->  00:05:54,860
in this shared distribution tree,
159

159

00:05:54,860  -->  00:05:56,890
just like we had before in Dense Mode.
160

160

00:05:56,890  -->  00:05:59,160
Now you can see how this uses a lot less resources
161

161

00:05:59,160  -->  00:06:00,390
than Dense Mode did,
162

162

00:06:00,390  -->  00:06:02,420
but it did take us a little bit more time
163

163

00:06:02,420  -->  00:06:04,210
to find that optimal way.
164

164

00:06:04,210  -->  00:06:05,700
That's the trade off here.
165

165

00:06:05,700  -->  00:06:07,700
Do you want to get optimal right from the start,
166

166

00:06:07,700  -->  00:06:09,090
but flood your network?
167

167

00:06:09,090  -->  00:06:10,490
Or can you wait for optimal
168

168

00:06:10,490  -->  00:06:12,220
and use a lot less resources?
169

169

00:06:12,220  -->  00:06:13,630
In most modern networks,
170

170

00:06:13,630  -->  00:06:16,170
we choose PIM-SM, or Sparse Mode,
171

171

00:06:16,170  -->  00:06:17,890
because it works better on our networks
172

172

00:06:17,890  -->  00:06:19,650
and uses less resources upfront,
173

173

00:06:19,650  -->  00:06:21,760
and eventually gets that optimal distribution
174

174

00:06:21,760  -->  00:06:22,910
that we're looking for.
