1
00:00:00,750 --> 00:00:02,160
Now at this point of the course,

2
00:00:02,160 --> 00:00:03,810
we're about to jump into the area

3
00:00:03,810 --> 00:00:06,360
that most students dread when it comes to networking,

4
00:00:06,360 --> 00:00:08,250
and this is known as subnetting.

5
00:00:08,250 --> 00:00:10,380
Now, don't worry, I'm going to get you through it,

6
00:00:10,380 --> 00:00:11,970
but this is probably one of the hardest

7
00:00:11,970 --> 00:00:13,590
concepts on the exam.

8
00:00:13,590 --> 00:00:15,090
You may need to go through this section

9
00:00:15,090 --> 00:00:17,430
a couple of times to make sure you grasp it.

10
00:00:17,430 --> 00:00:19,530
Now, what we're going to do is I'm going to go through

11
00:00:19,530 --> 00:00:21,630
and we're going to do the hard way first,

12
00:00:21,630 --> 00:00:24,240
so you understand the theory and how it all works.

13
00:00:24,240 --> 00:00:26,460
Then, I'm going to show you a shortcut

14
00:00:26,460 --> 00:00:28,830
and how to get through it for the exam a lot easier.

15
00:00:28,830 --> 00:00:31,260
But please, don't skip the next couple of lessons

16
00:00:31,260 --> 00:00:32,910
of going through the hard way first

17
00:00:32,910 --> 00:00:34,590
'cause if you don't understand the hard way,

18
00:00:34,590 --> 00:00:36,733
the easy way will make zero sense to you.

19
00:00:36,733 --> 00:00:39,210
Subnetting is where we can take a large network

20
00:00:39,210 --> 00:00:41,580
and we split it up into smaller networks.

21
00:00:41,580 --> 00:00:45,090
When we do this, this is all about logical IP addressing.

22
00:00:45,090 --> 00:00:46,950
The default class full subnet mask

23
00:00:46,950 --> 00:00:51,030
is rarely going to be the optimal subnet for our subnet size.

24
00:00:51,030 --> 00:00:54,510
So, instead, we use subnet masks to modify the subnets

25
00:00:54,510 --> 00:00:57,330
and create networks that are much better in scope.

26
00:00:57,330 --> 00:00:59,190
For instance, let's say I gave you a network

27
00:00:59,190 --> 00:01:01,770
of 10.something.something.something.

28
00:01:01,770 --> 00:01:03,600
This is a Class A address.

29
00:01:03,600 --> 00:01:06,150
That means there are 16.7 million

30
00:01:06,150 --> 00:01:07,950
IP addresses in that range.

31
00:01:07,950 --> 00:01:09,450
You may have a large network,

32
00:01:09,450 --> 00:01:13,170
but your network is probably not 16.7 million clients.

33
00:01:13,170 --> 00:01:15,540
So, we would want to create subnets

34
00:01:15,540 --> 00:01:18,660
that allow us to borrow bits from the original host portion

35
00:01:18,660 --> 00:01:20,880
and then we can add them into the network portion

36
00:01:20,880 --> 00:01:23,250
to make smaller networks for us.

37
00:01:23,250 --> 00:01:27,930
So, for example, if I had a network like 10.0.0.0/8

38
00:01:27,930 --> 00:01:30,210
that is a classful Class A subnet,

39
00:01:30,210 --> 00:01:32,970
and it has 16.7 million hosts,

40
00:01:32,970 --> 00:01:34,530
but I probably need something

41
00:01:34,530 --> 00:01:36,120
like a couple of hundred hosts,

42
00:01:36,120 --> 00:01:38,100
maybe 256 of them.

43
00:01:38,100 --> 00:01:39,180
Well, if I wanted to do that,

44
00:01:39,180 --> 00:01:43,050
I might use the Class C subnet mask of /24

45
00:01:43,050 --> 00:01:44,430
and use that instead.

46
00:01:44,430 --> 00:01:47,670
By using 10.0.0.0/24,

47
00:01:47,670 --> 00:01:51,330
that's going to give me 256 IPs in that subnet,

48
00:01:51,330 --> 00:01:53,370
and that means those other 16 million

49
00:01:53,370 --> 00:01:55,140
can be used by other people.

50
00:01:55,140 --> 00:01:57,000
Then, maybe I'm going to create a second subnet,

51
00:01:57,000 --> 00:01:59,803
like 10.0.1.0/24,

52
00:01:59,803 --> 00:02:01,980
and then I can create a third subnet

53
00:02:01,980 --> 00:02:05,130
with 10.0.2.0/24.

54
00:02:05,130 --> 00:02:08,910
And now, I've used three subnets of 256 IPs each,

55
00:02:08,910 --> 00:02:11,280
and I still have millions of leftover IPs

56
00:02:11,280 --> 00:02:13,110
that I can subnet out later.

57
00:02:13,110 --> 00:02:15,420
This is why it's really important to use subnets

58
00:02:15,420 --> 00:02:18,360
because it's an efficient use of the IP addresses you have

59
00:02:18,360 --> 00:02:20,940
instead of just using the classful default.

60
00:02:20,940 --> 00:02:23,820
Even in your home network, if you're using a Class C address

61
00:02:23,820 --> 00:02:28,710
of something like 192.168.1.0/24,

62
00:02:28,710 --> 00:02:31,290
this gives you 256 possibilities,

63
00:02:31,290 --> 00:02:33,210
but you probably only have 5 or 10 devices

64
00:02:33,210 --> 00:02:34,800
on your home network.

65
00:02:34,800 --> 00:02:36,060
Now, by doing subnets,

66
00:02:36,060 --> 00:02:37,230
this is going to allow us to create

67
00:02:37,230 --> 00:02:39,210
additional VLANs and subnets

68
00:02:39,210 --> 00:02:42,150
and allow separation of our networks for better security

69
00:02:42,150 --> 00:02:44,730
and giving us better bandwidth control.

70
00:02:44,730 --> 00:02:46,410
Here on the screen you can see a chart

71
00:02:46,410 --> 00:02:49,980
that has the addresses for Class A, B, and C subnets

72
00:02:49,980 --> 00:02:51,360
and their default masks,

73
00:02:51,360 --> 00:02:53,430
which should be a review for you at this point.

74
00:02:53,430 --> 00:02:54,690
Now, on the right side,

75
00:02:54,690 --> 00:02:57,270
you're going to see the assignable number of IP addresses,

76
00:02:57,270 --> 00:03:00,630
which is for class A of 16.7 million addresses,

77
00:03:00,630 --> 00:03:04,020
for Class B 65,000 plus IP addresses,

78
00:03:04,020 --> 00:03:07,770
and Class C 254 usable IP addresses.

79
00:03:07,770 --> 00:03:10,290
That is a lot of IP addresses.

80
00:03:10,290 --> 00:03:12,090
Now, we may want to start necking those down

81
00:03:12,090 --> 00:03:13,440
into usable chunks,

82
00:03:13,440 --> 00:03:15,960
and that is what we're going to use subnetting for.

83
00:03:15,960 --> 00:03:18,960
If we're using private IPs, this really isn't a big deal

84
00:03:18,960 --> 00:03:20,610
because they don't cost me anything,

85
00:03:20,610 --> 00:03:24,180
but with public IPs, every public IP I paid for,

86
00:03:24,180 --> 00:03:25,830
that's money out of my pocket

87
00:03:25,830 --> 00:03:26,850
and you want to minimize that

88
00:03:26,850 --> 00:03:28,620
to only getting the ones you need.

89
00:03:28,620 --> 00:03:33,270
For example, my ISP charges $5 per month for a static IP.

90
00:03:33,270 --> 00:03:35,220
If I need one, that's $5.

91
00:03:35,220 --> 00:03:37,470
If I need 10, that's $50.

92
00:03:37,470 --> 00:03:39,750
If I need 100, that's $500.

93
00:03:39,750 --> 00:03:41,940
And so, that can add up pretty quickly, right?

94
00:03:41,940 --> 00:03:44,370
By subnetting, it allows me to just get the things

95
00:03:44,370 --> 00:03:47,100
that I need and the fewer IPs that I need.

96
00:03:47,100 --> 00:03:48,510
Now, how do we do this?

97
00:03:48,510 --> 00:03:51,390
Well, that's what we use a subnet mask for.

98
00:03:51,390 --> 00:03:53,640
We talked about Class A, Class B, and Class C

99
00:03:53,640 --> 00:03:56,700
default subnet masks back when we talked about it before,

100
00:03:56,700 --> 00:03:58,710
and you'll see those on the screen in red.

101
00:03:58,710 --> 00:04:02,760
They are the /8, /16, and /24.

102
00:04:02,760 --> 00:04:04,500
Now, when you convert those to binary,

103
00:04:04,500 --> 00:04:06,810
you can see that they're filled by all the octets

104
00:04:06,810 --> 00:04:11,220
with either all 1s or all 0s, making them classful.

105
00:04:11,220 --> 00:04:12,930
Now, the ones on the bottom of the screen

106
00:04:12,930 --> 00:04:16,860
from 25 down to /30 are going to be smaller subnets.

107
00:04:16,860 --> 00:04:18,630
These are called classless subnets

108
00:04:18,630 --> 00:04:20,130
because they're going to use different things

109
00:04:20,130 --> 00:04:23,880
besides all 1s or all 0s in that octet.

110
00:04:23,880 --> 00:04:24,990
Now, as you can see,

111
00:04:24,990 --> 00:04:27,180
we're borrowing bits from the host portion

112
00:04:27,180 --> 00:04:29,670
and making all those 0s and taking some of those,

113
00:04:29,670 --> 00:04:32,730
adding them over into the network portion as well.

114
00:04:32,730 --> 00:04:35,430
And so, this borrowing is what we're doing with subnetting.

115
00:04:35,430 --> 00:04:36,930
If you don't get it yet, don't worry,

116
00:04:36,930 --> 00:04:38,190
we are going to dig deeper into it

117
00:04:38,190 --> 00:04:40,170
as we continue through this lesson.

118
00:04:40,170 --> 00:04:41,820
Now, let's take a look at some formulas

119
00:04:41,820 --> 00:04:43,170
that we're going to need to understand

120
00:04:43,170 --> 00:04:45,180
for calculating the number of subnets

121
00:04:45,180 --> 00:04:47,340
and the number of assignable hosts.

122
00:04:47,340 --> 00:04:49,500
If I'm calculating the number of subnets,

123
00:04:49,500 --> 00:04:51,750
the formula is 2 to the s power,

124
00:04:51,750 --> 00:04:54,990
where s is the number of borrowed bits from the host.

125
00:04:54,990 --> 00:04:57,090
So, when I start taking those 0s from the host

126
00:04:57,090 --> 00:04:58,590
and turning them to 1s

127
00:04:58,590 --> 00:05:01,020
to make them a part of the network portion,

128
00:05:01,020 --> 00:05:03,870
that is the s that we're talking about here.

129
00:05:03,870 --> 00:05:07,080
For instance, if I'm using a /25 as my network,

130
00:05:07,080 --> 00:05:09,240
I'm borrowing 1 bit from the host space

131
00:05:09,240 --> 00:05:11,460
and putting it into the network space.

132
00:05:11,460 --> 00:05:13,650
Now, this would make it 2 to the 1,

133
00:05:13,650 --> 00:05:15,360
and that would give me 2.

134
00:05:15,360 --> 00:05:19,380
And so, that tells me I can have 2 subnets by using a /25.

135
00:05:19,380 --> 00:05:20,310
Now, if I'm looking at the number

136
00:05:20,310 --> 00:05:21,990
of a assignable IP addresses,

137
00:05:21,990 --> 00:05:25,590
this is going to be 2 to the number of host bits minus 2.

138
00:05:25,590 --> 00:05:27,690
So, in my case of a /25 network,

139
00:05:27,690 --> 00:05:30,540
there are 32 total bits in the address.

140
00:05:30,540 --> 00:05:33,900
I have 25 of those being assigned for the network portion,

141
00:05:33,900 --> 00:05:36,210
leaving me with 7 host bits.

142
00:05:36,210 --> 00:05:38,430
So, if I take 2 to the 7th

143
00:05:38,430 --> 00:05:39,900
and then I'm minus 2,

144
00:05:39,900 --> 00:05:44,900
I get 128 minus 2, or 126 available.

145
00:05:44,940 --> 00:05:47,640
Now, why do I have to have that minus 2 there?

146
00:05:47,640 --> 00:05:49,650
This is a concept that a lot of students miss,

147
00:05:49,650 --> 00:05:51,720
so really pay attention to it.

148
00:05:51,720 --> 00:05:53,130
Every network out there

149
00:05:53,130 --> 00:05:56,250
has to have two IP addresses to be a network.

150
00:05:56,250 --> 00:05:58,170
The first is known as the network ID,

151
00:05:58,170 --> 00:06:01,440
and it's the first IP in the range for that network.

152
00:06:01,440 --> 00:06:03,450
And the other one is a broadcast ID,

153
00:06:03,450 --> 00:06:06,060
which is the last IP in the network.

154
00:06:06,060 --> 00:06:07,920
So, no matter what network you choose,

155
00:06:07,920 --> 00:06:11,220
you always have to sacrifice the first one and the last one.

156
00:06:11,220 --> 00:06:14,130
The first one is your network ID or network name,

157
00:06:14,130 --> 00:06:16,500
and your last one is your broadcast.

158
00:06:16,500 --> 00:06:19,650
Now, anytime you calculate this number of usable IPs,

159
00:06:19,650 --> 00:06:22,440
it's always going to be the number minus 2

160
00:06:22,440 --> 00:06:24,690
'cause you have to take away the network name

161
00:06:24,690 --> 00:06:26,490
and the broadcast name.

162
00:06:26,490 --> 00:06:29,910
Let's take a look at classful versus subnetting networks.

163
00:06:29,910 --> 00:06:31,470
A classful network, if you remember,

164
00:06:31,470 --> 00:06:35,700
are the ones like /8, /16, /24.

165
00:06:35,700 --> 00:06:40,590
And if I use the example of 192.168.1.0/24,

166
00:06:40,590 --> 00:06:43,380
this is a classful Class C network.

167
00:06:43,380 --> 00:06:46,710
There is one network here because it is 2 to the 0

168
00:06:46,710 --> 00:06:51,150
because I borrowed 0 bits because /24 is classful.

169
00:06:51,150 --> 00:06:53,550
This means that there is 2 to the 8

170
00:06:53,550 --> 00:06:55,710
minus 2 assignable IPs,

171
00:06:55,710 --> 00:06:58,920
which gives me 256 IPs minus 2,

172
00:06:58,920 --> 00:07:01,050
one for the broadcast, one for the network,

173
00:07:01,050 --> 00:07:04,320
and that gives me 254 usable IPs.

174
00:07:04,320 --> 00:07:05,790
As you can see here on the screen,

175
00:07:05,790 --> 00:07:08,790
we have all the network bits, all 24 of them,

176
00:07:08,790 --> 00:07:11,250
and therefore it is classful.

177
00:07:11,250 --> 00:07:13,320
Now, we have 8 bits of the host.

178
00:07:13,320 --> 00:07:15,720
And let's say that I wanted to make a smaller subnet.

179
00:07:15,720 --> 00:07:16,800
How could I do that?

180
00:07:16,800 --> 00:07:19,050
Well, I could borrow 2 bits from the host

181
00:07:19,050 --> 00:07:20,310
and create a subnet.

182
00:07:20,310 --> 00:07:22,920
This would make it a /26, for instance.

183
00:07:22,920 --> 00:07:25,110
So, if I borrow those 2 host bits,

184
00:07:25,110 --> 00:07:28,620
now it becomes 2 to the s or 2 to the second power,

185
00:07:28,620 --> 00:07:30,540
which gives me four networks,

186
00:07:30,540 --> 00:07:32,250
four subnets that I've created.

187
00:07:32,250 --> 00:07:34,080
So, if I consider those four networks,

188
00:07:34,080 --> 00:07:35,520
how many IPs can I have

189
00:07:35,520 --> 00:07:38,040
in each one of those four networks I just created?

190
00:07:38,040 --> 00:07:39,930
Well, in the original /24,

191
00:07:39,930 --> 00:07:43,830
I had 256 hosts total or IPs total.

192
00:07:43,830 --> 00:07:45,780
Now, I borrowed those 2 host bits

193
00:07:45,780 --> 00:07:47,100
and gave them to the network,

194
00:07:47,100 --> 00:07:49,860
and so now I have 2 to the 6th power,

195
00:07:49,860 --> 00:07:52,860
that's going to give me 64 IPs per subnet.

196
00:07:52,860 --> 00:07:56,700
So, if I have 64 plus 64 plus 64 plus 64,

197
00:07:56,700 --> 00:07:58,740
that equals 256.

198
00:07:58,740 --> 00:08:01,800
So, I took that one big network, that /24,

199
00:08:01,800 --> 00:08:05,850
and I turned it into four smaller networks, those /26s.

200
00:08:05,850 --> 00:08:09,630
But remember, each of those I have to give away two IPs,

201
00:08:09,630 --> 00:08:11,280
the first one and the last one.

202
00:08:11,280 --> 00:08:12,660
The first one is the network name,

203
00:08:12,660 --> 00:08:14,370
the last one is the broadcast.

204
00:08:14,370 --> 00:08:17,610
So, I only have 62 usable IPs

205
00:08:17,610 --> 00:08:19,470
that I can assign to a server,

206
00:08:19,470 --> 00:08:22,110
or a laptop, or a phone, or something like that.

207
00:08:22,110 --> 00:08:24,510
And so, for each of these four networks I've created,

208
00:08:24,510 --> 00:08:27,510
I now have 62 usable IPs,

209
00:08:27,510 --> 00:08:29,400
and I have four of those that were made up

210
00:08:29,400 --> 00:08:32,159
out of that original /24 network.

211
00:08:32,159 --> 00:08:33,960
Now, if you look at the blue at the bottom of this,

212
00:08:33,960 --> 00:08:37,110
you can see my original 256 possible IPs,

213
00:08:37,110 --> 00:08:39,809
which does include my broadcast and my network.

214
00:08:39,809 --> 00:08:42,809
If I subnet that down, I'm going to have 4 subnets

215
00:08:42,809 --> 00:08:44,610
or 2 to the 2nd power.

216
00:08:44,610 --> 00:08:47,280
Now, I'm going to have 62 possible IPs

217
00:08:47,280 --> 00:08:50,190
because each one was 2 to the 6th minus 2

218
00:08:50,190 --> 00:08:51,810
because I take away the first and the last

219
00:08:51,810 --> 00:08:53,820
for the network name and the broadcast.

220
00:08:53,820 --> 00:08:56,430
In our case, this is going to give us the four subnets

221
00:08:56,430 --> 00:09:00,690
as their name of 192.168.1.0,

222
00:09:00,690 --> 00:09:02,463
192.168.1.64,

223
00:09:03,777 --> 00:09:07,440
192.168.1.128,

224
00:09:07,440 --> 00:09:11,640
and 192.168.1.192.

225
00:09:11,640 --> 00:09:13,530
Those are my four network names.

226
00:09:13,530 --> 00:09:14,850
Now, for the broadcast,

227
00:09:14,850 --> 00:09:17,040
it's going to be the last IP of each subnet,

228
00:09:17,040 --> 00:09:20,197
so that's going to be the ones ending in .63,

229
00:09:20,197 --> 00:09:24,900
.127, .191, and .255.

230
00:09:24,900 --> 00:09:26,070
So, hopefully now you're starting to see

231
00:09:26,070 --> 00:09:28,380
how these subnets start to work together.

232
00:09:28,380 --> 00:09:30,300
If we want to calculate those IPs,

233
00:09:30,300 --> 00:09:33,300
we're going to do that based on those subnet masks.

234
00:09:33,300 --> 00:09:35,190
So, when we take those 32 bits,

235
00:09:35,190 --> 00:09:38,490
which is the total number of bits minus whatever our slash

236
00:09:38,490 --> 00:09:39,990
or CIDR notation is,

237
00:09:39,990 --> 00:09:41,640
in this case 26,

238
00:09:41,640 --> 00:09:44,310
we get that there are 6 host bits remaining.

239
00:09:44,310 --> 00:09:46,170
That would be 2 to the 6th minus 2,

240
00:09:46,170 --> 00:09:51,170
which is 64 minus 2, or 62 usable assignable IPs.

241
00:09:51,720 --> 00:09:53,040
Now, I'm hoping that all of this

242
00:09:53,040 --> 00:09:55,440
is starting to come together as we've gone through it.

243
00:09:55,440 --> 00:09:57,840
Subnetting is a very complex topic

244
00:09:57,840 --> 00:09:59,640
that a lot of students struggle with.

245
00:09:59,640 --> 00:10:01,080
I want you to keep practicing it

246
00:10:01,080 --> 00:10:02,730
and keep working through the problems

247
00:10:02,730 --> 00:10:04,410
because I guarantee on test day

248
00:10:04,410 --> 00:10:07,230
you're going to get some questions on subnetting.

249
00:10:07,230 --> 00:10:08,490
Now, some of these questions

250
00:10:08,490 --> 00:10:10,530
might ask you just to do the problem,

251
00:10:10,530 --> 00:10:13,140
but most of them are going to be more about troubleshooting.

252
00:10:13,140 --> 00:10:14,280
There's going to be some computers

253
00:10:14,280 --> 00:10:15,690
that aren't talking to another,

254
00:10:15,690 --> 00:10:17,550
and when you start looking at their IP addresses

255
00:10:17,550 --> 00:10:18,750
and their subnet mask,

256
00:10:18,750 --> 00:10:20,577
you're going to notice they're not on the same subnet.

257
00:10:20,577 --> 00:10:22,320
And if there's no router there,

258
00:10:22,320 --> 00:10:24,330
data won't go from one subnet to another,

259
00:10:24,330 --> 00:10:26,460
and so this is an important concept.

260
00:10:26,460 --> 00:10:29,370
Now, let's talk about how we list out these subnets.

261
00:10:29,370 --> 00:10:30,810
Let's keep going with our example

262
00:10:30,810 --> 00:10:35,100
of the 192.168.1.0/26,

263
00:10:35,100 --> 00:10:39,240
and those four subnets we created of 62 usable IPs each.

264
00:10:39,240 --> 00:10:41,880
Now, where does each network begin and end?

265
00:10:41,880 --> 00:10:43,290
We kind of already went over this

266
00:10:43,290 --> 00:10:45,090
by saying it was the .0,

267
00:10:45,090 --> 00:10:48,930
the .64, the .128, and the .192

268
00:10:48,930 --> 00:10:50,730
as our beginning of each network.

269
00:10:50,730 --> 00:10:52,590
Now, where did I come up with those?

270
00:10:52,590 --> 00:10:54,810
Well, I started with the original IP

271
00:10:54,810 --> 00:10:58,170
of 192.168.1.0.

272
00:10:58,170 --> 00:11:00,150
Now, zero is my first IP

273
00:11:00,150 --> 00:11:02,580
and it is going to be the name of that network.

274
00:11:02,580 --> 00:11:05,580
Each subnet we said was 64 IPs in length,

275
00:11:05,580 --> 00:11:09,450
so if I take 0 plus 64, I get .64.

276
00:11:09,450 --> 00:11:12,080
If I add another 64, I get .128.

277
00:11:12,080 --> 00:11:15,120
If I add another 64, I get .192.

278
00:11:15,120 --> 00:11:18,000
Now, how do I find the last IP for each of these?

279
00:11:18,000 --> 00:11:19,950
Well, that's going to be my broadcast address.

280
00:11:19,950 --> 00:11:23,370
All I need to do is add .63 to each of these numbers

281
00:11:23,370 --> 00:11:24,810
because there's 64 IPs,

282
00:11:24,810 --> 00:11:26,400
the first one is used for the name,

283
00:11:26,400 --> 00:11:30,660
the last one, the plus 63, gets me to that broadcast ID.

284
00:11:30,660 --> 00:11:32,715
And so, I get 63,

285
00:11:32,715 --> 00:11:36,060
127, 191, and 255.

286
00:11:36,060 --> 00:11:38,640
That's going to be the beginning and ending of each subnet.

287
00:11:38,640 --> 00:11:39,883
It goes from 0-63,

288
00:11:40,876 --> 00:11:45,370
64-127, 128-191, and 192-255.

289
00:11:46,710 --> 00:11:48,270
Everything in between those,

290
00:11:48,270 --> 00:11:50,790
for instance I might have something like 32,

291
00:11:50,790 --> 00:11:52,950
is going to be a usable IP.

292
00:11:52,950 --> 00:11:54,690
Those are things we're going to assign to clients,

293
00:11:54,690 --> 00:11:57,210
and servers, and tablets, and laptops, and desktops,

294
00:11:57,210 --> 00:11:58,740
and all those things.

295
00:11:58,740 --> 00:12:01,230
Now, when we do all of these, we write these out,

296
00:12:01,230 --> 00:12:02,070
we're going to write them out

297
00:12:02,070 --> 00:12:04,320
with what's known as the slash notation.

298
00:12:04,320 --> 00:12:09,208
So, we'd write 192.168.1.0

299
00:12:09,208 --> 00:12:13,410
/192.168.1.127

300
00:12:13,410 --> 00:12:14,700
That's pretty long to write that out

301
00:12:14,700 --> 00:12:16,350
for each of the four subnets.

302
00:12:16,350 --> 00:12:18,900
So, instead we have this shorthand notation

303
00:12:18,900 --> 00:12:20,580
called a CIDR notation,

304
00:12:20,580 --> 00:12:23,580
and this stands for the Classless Inter-Domain Routing.

305
00:12:23,580 --> 00:12:26,520
Instead of advertising multiple individual routes,

306
00:12:26,520 --> 00:12:29,340
we summarize all those as a single route.

307
00:12:29,340 --> 00:12:31,110
We do this through CIDR notation,

308
00:12:31,110 --> 00:12:34,110
and in this case we had the /26.

309
00:12:34,110 --> 00:12:36,330
So, I can consolidate all of those

310
00:12:36,330 --> 00:12:38,310
underneath them by doing a summary

311
00:12:38,310 --> 00:12:41,370
of the continuous networks using route aggregation.

312
00:12:41,370 --> 00:12:43,980
When I do this and I look at the /26,

313
00:12:43,980 --> 00:12:47,010
I notice that the first 26 bits are all equivalent,

314
00:12:47,010 --> 00:12:49,290
they're all the same for the subnet mask.

315
00:12:49,290 --> 00:12:51,000
So, by consolidating those,

316
00:12:51,000 --> 00:12:52,890
this allows me to put all those networks together

317
00:12:52,890 --> 00:12:56,700
in one slash notation and simply write them down this way.

318
00:12:56,700 --> 00:13:00,900
Next, we have a Variable-Length Subnet Mask, or VLSM.

319
00:13:00,900 --> 00:13:03,990
This allows subnets of various sizes to be used.

320
00:13:03,990 --> 00:13:06,390
Everything I've done so far has been equal.

321
00:13:06,390 --> 00:13:09,240
I took a big chunk of 256 IPs

322
00:13:09,240 --> 00:13:12,570
and broke them up into four equal 64-bit chunks,

323
00:13:12,570 --> 00:13:14,280
but we don't have to do that.

324
00:13:14,280 --> 00:13:15,570
I could actually break it up

325
00:13:15,570 --> 00:13:19,380
and have a 16 chunk, and a 32 chunk, and a 64 chunk,

326
00:13:19,380 --> 00:13:22,770
and that way I can do that to what's right for my network.

327
00:13:22,770 --> 00:13:24,750
Now, this is going to require a routing protocol

328
00:13:24,750 --> 00:13:28,050
that supports this, but all modern routing protocols do,

329
00:13:28,050 --> 00:13:29,670
including things like RIP,

330
00:13:29,670 --> 00:13:34,290
OSPF, IS-IS, EIGRP, and BGP.

331
00:13:34,290 --> 00:13:36,630
Basically, Variable-Length Subnet Masking

332
00:13:36,630 --> 00:13:38,760
is a subnetting of subnets.

333
00:13:38,760 --> 00:13:42,540
Without VLSM, all subnets would have to be the same size.

334
00:13:42,540 --> 00:13:44,430
But by using VLSM,

335
00:13:44,430 --> 00:13:47,070
I can break them up into whatever chunks I want.

336
00:13:47,070 --> 00:13:49,230
And I'm going to give you the key to subnetting here.

337
00:13:49,230 --> 00:13:50,490
When you look at this chart,

338
00:13:50,490 --> 00:13:52,740
this is your subnetting exam tip.

339
00:13:52,740 --> 00:13:54,600
Write this down in your notes.

340
00:13:54,600 --> 00:13:56,160
Now, the one I want you to memorize here

341
00:13:56,160 --> 00:13:58,260
is this small chart off to the right.

342
00:13:58,260 --> 00:14:00,060
You can do all the math on test day

343
00:14:00,060 --> 00:14:02,580
and spend a lot of time trying to do 2 to the s

344
00:14:02,580 --> 00:14:04,350
and 2 to the h-2,

345
00:14:04,350 --> 00:14:07,350
or you can memorize this small chart on the right.

346
00:14:07,350 --> 00:14:10,140
If you notice, it's going to start with /24,

347
00:14:10,140 --> 00:14:13,230
and you have that as your subnet as a classful Class C,

348
00:14:13,230 --> 00:14:14,820
you have 256 IPs.

349
00:14:14,820 --> 00:14:17,370
You know this because we've talked about this a lot, right?

350
00:14:17,370 --> 00:14:21,120
Now, if I add one to the CIDR notation, it becomes /25,

351
00:14:21,120 --> 00:14:23,370
I increased the number of networks.

352
00:14:23,370 --> 00:14:25,830
By adding 1, I borrowed a bit,

353
00:14:25,830 --> 00:14:28,290
that's going to give me two subnets,

354
00:14:28,290 --> 00:14:30,900
and that's going to take my 256 IPs

355
00:14:30,900 --> 00:14:33,900
and divide it by 2, giving me 128.

356
00:14:33,900 --> 00:14:36,690
Notice, I'm always going to have 256 IPs

357
00:14:36,690 --> 00:14:41,160
as I go from /24 downward all the way down to /30.

358
00:14:41,160 --> 00:14:43,950
So, every time my CIDR notation goes up by one,

359
00:14:43,950 --> 00:14:46,080
my number of networks goes up by one,

360
00:14:46,080 --> 00:14:49,020
and my number of IPs gets divided by two.

361
00:14:49,020 --> 00:14:51,000
If you can remember this chart on the right,

362
00:14:51,000 --> 00:14:52,590
this is going to help you on test day

363
00:14:52,590 --> 00:14:54,750
get through a lot of the questions on subnets,

364
00:14:54,750 --> 00:14:56,430
and it's really nice and easy.

365
00:14:56,430 --> 00:14:58,350
Now, the good thing is for Network+,

366
00:14:58,350 --> 00:15:00,810
they're not going to give you a lot of difficult subnets.

367
00:15:00,810 --> 00:15:02,610
Almost all the ones you're going to get

368
00:15:02,610 --> 00:15:05,250
are going to be /24 or higher.

369
00:15:05,250 --> 00:15:06,083
The most they're going to give you

370
00:15:06,083 --> 00:15:10,440
is something like a /23 maybe or a /22, but that's rare.

371
00:15:10,440 --> 00:15:14,700
Generally, it's going to be /25, 26, 27, 28, 29, and 30.

372
00:15:14,700 --> 00:15:16,170
That is the most common.

373
00:15:16,170 --> 00:15:18,840
So, if they ask you something like you have a /28,

374
00:15:18,840 --> 00:15:20,340
how many subnets are created?

375
00:15:20,340 --> 00:15:21,173
It's pretty easy.

376
00:15:21,173 --> 00:15:24,150
You look at this chart and you go, "Ah, the answer is 16."

377
00:15:24,150 --> 00:15:26,160
If I go from 24 up to 28,

378
00:15:26,160 --> 00:15:28,890
I keep doubling it, and I double it to get to 25,

379
00:15:28,890 --> 00:15:30,450
I double it again to get to 26,

380
00:15:30,450 --> 00:15:32,040
double it again to get to 27,

381
00:15:32,040 --> 00:15:34,470
double it again to get to 16, right?

382
00:15:34,470 --> 00:15:37,590
And that is where I get to /28 is 16

383
00:15:37,590 --> 00:15:41,250
because I went 2, 4, 8, 16, and there we go.

384
00:15:41,250 --> 00:15:43,350
Now, you might ask how many IPs you'd have in each subnet

385
00:15:43,350 --> 00:15:44,910
if you had a /30.

386
00:15:44,910 --> 00:15:46,560
Well, for a /30,

387
00:15:46,560 --> 00:15:48,660
that's what we'll use for point-to-point connections,

388
00:15:48,660 --> 00:15:50,280
and there's going to be four IPs,

389
00:15:50,280 --> 00:15:51,840
but only two of those are usable

390
00:15:51,840 --> 00:15:53,640
'cause again, our first one

391
00:15:53,640 --> 00:15:55,230
is always the name of the network,

392
00:15:55,230 --> 00:15:57,060
and the last one is always the broadcast.

393
00:15:57,060 --> 00:16:00,147
So, you have four IPs, two of which are usable.

394
00:16:00,147 --> 00:16:01,650
And if you remember this chart,

395
00:16:01,650 --> 00:16:04,740
you're going to be able to do great on subnetting on the exam.

396
00:16:04,740 --> 00:16:06,030
Now, before the test,

397
00:16:06,030 --> 00:16:08,970
I want you to take lots of practice subnetting problems,

398
00:16:08,970 --> 00:16:11,040
especially in your Class C range.

399
00:16:11,040 --> 00:16:14,580
Everything from /24 to /30 is really fair game

400
00:16:14,580 --> 00:16:16,140
for the Network+ exam.

401
00:16:16,140 --> 00:16:18,570
Memorizing these slash notations and the CIDR

402
00:16:18,570 --> 00:16:21,240
is going to help you answer any question they throw at you.

403
00:16:21,240 --> 00:16:23,130
But as we go through this section,

404
00:16:23,130 --> 00:16:24,540
I'm going to show you a shortcut

405
00:16:24,540 --> 00:16:26,730
that you can do just using your hands as well,

406
00:16:26,730 --> 00:16:28,110
and you're going to really like this,

407
00:16:28,110 --> 00:16:29,280
but having this chart memorized

408
00:16:29,280 --> 00:16:30,990
is going to help with that as well.

409
00:16:30,990 --> 00:16:32,190
Now, for the exam,

410
00:16:32,190 --> 00:16:34,230
something you may see is they might have you do

411
00:16:34,230 --> 00:16:36,660
a variable-length subnetting problem.

412
00:16:36,660 --> 00:16:38,910
Now, if they do a VLSM problem for you,

413
00:16:38,910 --> 00:16:42,990
it might be they gave you an IP address with 256 IPs

414
00:16:42,990 --> 00:16:44,730
because they're going to give you a /24,

415
00:16:44,730 --> 00:16:47,460
and then they might say, "Hey, you have an IT department

416
00:16:47,460 --> 00:16:49,350
that needs x number of IPs,

417
00:16:49,350 --> 00:16:52,080
you have a HR department needs x amount of IPs,

418
00:16:52,080 --> 00:16:55,260
you have a sales department that needs y amount of IPs,"

419
00:16:55,260 --> 00:16:57,600
and you'll have to go through and do the slash notations

420
00:16:57,600 --> 00:17:00,510
for each one based on the number of IPs they give you.

421
00:17:00,510 --> 00:17:02,940
That is a totally fair question on the exam

422
00:17:02,940 --> 00:17:04,560
and how you'd put this subnetting stuff

423
00:17:04,560 --> 00:17:06,032
to work in the real world.

