cisco certified network associate day 3 welcome back iam imran rafai your trainer for entire series
as you know this is a free train series provided on YouTube
and if you think this video is helped you or if you think it could help colleague of yours
please do not hesitate to share this video on your social media platforms and of cource like this video
more you like more you promote this video and it could lot of people in our last video which is ccna day 2
we looked at the osi reference model and tc ip model.in todays video as you can see on the screen we would be dealing
with ip version 4.ip adress and subnetting go hand in hand and hence what have done is break day 3
into two parts.so i call this video day3(am) and we will deal exclusive about ip adress and structures
and we will create an another video called day 3(pm) and we include subnetting into that video.
allright without wasting much time let us get straight into this when we hear about IP address
and especially those people who do not understand IP address we get scared and we wonder what these
numbers really mean and we most of time really get worried because we don't understand the IP adresses
well trust me when I say this IP address very very easy concept to learn and once you finish this video
you would be wondering what was it so difficult that you have to be really really tense whenever you heard
about IP addresses and this what you see in the screen is nothing but an IP version 4 address and as
you know IP version 6 has been released and if you get scared looking at IP version 4 address I
would ask you to wait until you see IP version 6 an example of which is this dontworry dontworry IP
address is not that difficult once we understand the basics IP addressing is very very very easy just
because IP version 6 is comming do not neglect IP version 4 because I think personally IP version 4 is
going to be around for a very long time and like you know IP version 6 is included in the new syllabus
of CCNA so we would be dealing with IP version 6 but in the later video for now we would be dealing with
only IP version 4 IP as you know is nothing but Internet protocol and IP version 4 is the fourth version of
the protocol and the IP version 6 obviously is the sixth version and the latest version in the Internet
protocol IP is a connectionless protocol so IP let you know from the last video IP operates at layer 3
so the connection connection layers and known the data sequencing and all these things happen on
a layer 4 protocol called TCP which we learned in the last video. right let's let's go down and look at IP
four in detail the most of us have seen this screen of Windows user's would have seen screen that's on your left and the
Mac User would have seen the screen that's on your right this is where you do all your IP address configurations
and most of us just copied whatever addresses and subnetmask and default gateways is given
to us by an administrator or a colleague and really did know what those numbers really meant this video
today will explain what an IP addresses is and how they work an IP address is typically a number separated by
dots and when we talk about IP addresses three information that go hand-in-hand our IP address subnet mask and
gateway like you saw on the previous screen the gateway is sometimes also called as a router an IP address consists
of four octet now you might ask what is an octate.an octate is nothing but a group of eight so you might ask what group of
eight to understand that we need to understand what an IP address really is to a computer and to all the next devices and
IP address is seen like this .this is nothing but binary representation of the IP address but since humans like you and
I do not have the capacity to remember a number like this it is made easy for us by converting these binary numbers
to a decimal form like this so this form of representation of the IP address is called as the doted decimal presentation
so it is nothing but the binary octets here on the screen are converted to the respected decimal number so you might ask
how do they do that well it's very easy there are different ways of conversion converting binary numbers to decimal numbers
but easiest way is to have table like you see on the top of your screens it's a it's a eight column table starting from 1
from the right goes to 2 it keep doubling it 4 8 16 32 64 and 128 now take one of these octet so let's assume we take the
first octet which is nothing but 11000000 and put it here if you put 1 bit at the time and you put all those bits here you
would get something like this now where ever there is a one take the number about that and add so in this case you just add
128 and 64 so 128+64 is 192 so we could replace this 11000000 to 192 which is nothing but decimal representation
of that number and it's a much easier number for us to remember. similarly we could convert the next octet that is 10101000 which is nothing
but if you add 128+32+8 so 128+32+8 is nothing but 168 and we can repressent this octate as 168 similarly if you follow the same procedure
you could convert all these numbers to the decimal equivalent so an IP address is four octates
long so as we already saw you have four octates separated by a dot IP address is also a 32-bit number so as we saw you have 32-bits in every
IP address with every octot as eight so 12345678 8-bits into four so it's 32-bit address alright next it says IP address can take numbers
from 0 to 255 so you might ask 255 is that number come well if you look at the table again if all the bits in the octates
are zero the decimal number is a zero if all the bits octet are once the decimal number is 255 so each of these octets can take values
from zero or the maximum 255 if you see a number in the IP address which is more than 255 that's an invalid IP address next we deal with
the host and network concept every IP address has two information it has a network field and it has a host field.how do you identify which part
of the IP address is a network part and which part is the host part when we do that with the help of subnetmask so we see on the screen the
subnet mask will always be a series of one followed by a series of zeros .so if you look at the subnetmask the transition from ones to
zeros happen at the place which separates the network part and the host part in this example 192.168.100 is the network
bit let me just take another color all right so so in this case this is the network part and this is the hostpart so in this case IP addresses
from 192.168.100.0 to 100.255 is one big network to understand this let's assume that I'm in New York today and the I'm staying at the
Hilton so I called a friend of mine who is also in New York that day and I tell them to come and see me so I i Phone and I tell him that
Im at the Hilton in room number 2002014 since 2014 and he's also new to New York I tell them that the Hilton is on the sixth
Avenue between Street 53 and 54 now if you compare it to an IP address the address of the hotel is the network path and the room number is the
host part now when I when I told him that he is he tells
me that there is a very very nice restaurants near his hotel and I must instead go to downtown where he is staying .he is staying at the Marriott downtown and
this beautiful restaurant called the liberty cross the street and he said let's go for lunch that now when he tells me that I need
to go to Marriott one thing I know that marriottt is not in Hilton so I know that for me to reach Marriott I need to exit through my main
gate so similarly if an IP address is not part of the same network you can know that by comparing the network bit it's a different
network bit it is like it's a different hotel so like in the hotel's analogy for me to exit the hotel and go to a different hotel I need
to exit through the main gate similarly if an IP address has to communicate with onother network IP address it has to go through the
gate way in this case the gateway is 192.168.100.1 always remember the IP address and the gateway needs to be in the same
network if this change then the network is not valid next is the Classes so to look at that we look at this light IP addresses have different
classes the class of an IP address is decided by the first octet so let's assume the first octet of the IP address is between 1
and 126 in that case it is a clause A IP address if the first octet is between 128 to 191 it is clause B IP address. if the first octet is between
192 to 223 it is clause C and between 224 to 239 in is class D.240 to 255 it is class e.for all practical purposes and for the scope of
CCNA we would be only dealing with class A B and C class D is used for multi-cost and class E is reserved for experimental purposes
if you see we skipped one number between classA and class B that's 127 so any IP address starting with 127 is a loopback
IP address so 127 is used for loop back right let's look at class C IP address if you remember from the previous slide the class of an
IP address is decided by the first octet in this case 192 if you look at the stable 192 is class C so this is a
class C Ip adress we spoke about this subnet mask deciding between network and hosts but I'm sure you must have ask how do we know what subnet
mask is with some mask is decided by the class so for class C IP address the subnet mask is 255.255.255.0 so if you represent the submnet
mask in binary form it would be this and like we already know this separation separates the network and the host bit so in this case 192 168.100
is the network part and 225 is the host part an another way of representing this IP address is by putting a / .when i say 192.168.100.225/24 it means
that the submit mask has 24 ones so 24 ones is nothing but clause C IP address also when the host is zero that is the first IP address in the network
it is called the network ID and if the Hostbit goes to all once that is 255 it becomes the broadcast IDs in this case 192.168.100.0 is
the network ID and 192.168.100.255 which is the last IP in this network is the broadcast IDs are valid IP addresses and was network are from 1 to 254
so to know how many are valid IP addresses are there in this network we use the formula 2 to the power number off host bits and this case number of
host bits are the number of zeros in this case it is 2 to the power 8-2 is nothing but 254 host or valid rooms in the case of the hotel and if you take the
hotel analogy it is like a hotel with 254 rooms so this is room number 225 so there was another room calles 26 we can communicate with each
other because they are part of the same building also remember like we discussed earlier the gateway has to be part of the same network or same hotel in our hotel
analogy so if gateways 192.168.99.1 or 102.1 this will not work the IP address and the gateway should have the same network alright now lets look at class B
class B again if you look at the first octet of IP address it's 172 and from the table we know 172 is a clause B IP address so class
B IP address will have a submit mask 255.255.0.0 if you remember from class C class C had three 255's but class b has two 255 so we convert the submit mask into
the binary form this is how it looks like we discussed earlier this is represented as/16 because it has 16 once and the againe like we already know the
separation happens here so 172.123 is the network bit and 100.225 is the host bit. so the network ID is nothing but making
the host ID zero so 172.123.0.0 is the network ID and the broadcast ID is by making the host bits all once so brodcast ID is nothing but
172.123.255.255 valid IP's are between 172.123.0.0 to 172.123.255.254 how do we know how many IP addresses are their thats valid we use the same formula
so number of host bits are 16 so 2to the power of 16-2 is 65,534 that's a very very big number so if you go with the hotel analogy we see that to have 65,534 rooms
it is going to be very difficult to manage and that is exactly why we have a concept called submitting which is nothing but taking a massive network and breaking
it into small manageable forms Cisco sayss the ideal number of host or network should not be more than 500 because they say anything more than 500
the broadcast traffic is going to be so massive that the network is going to be very very inefficient so that's why we use submitting and we
break this massive network the smaller segments we learn about submitting in detail in the next review but I'm just giving you a heads up the
reason we need submitting now we go to class a again with the same rule we look at the first octet we see this 100 and we know 100 is a
part of class A so class A will have a submit mask of 255 if you remember class B had 255.255 and class C had 255.255.255 so
class A has only one 255 the first octet is to 255 and if you converted to binary it looks something like this so as we know from what we know so
far this will be the separation between network and host so anything with 100 is part of this network and this is also represented as/8
network's because it has eight bits as ones in the subnet mask again if you look at the network ID which is nothing bud making all the net
work bits in the IP address has zeros when this case it's 100.0.0.0 as the first IP address of this network and the broadcast ID is nothing but
making all the host bits as ones so it is 100.255.255.255 is the broadcast ID valid IP's are between 100.0.0.1 to 100.255.255.254
so if you know the IP address will go from 100.0.0.1 to 0.2,0.3,0.4 and it goes up to 0.255 and then it'll carry over so they become 100.0.1.0
the it will become 1.1,1.2,1.3,1.4 and it goes up to 1.255 again one will be carried over so it will get 2.0,2.1,2.2,2.3 it goes
on,on on and on until it gets 255.255.254 to know how many valid IP addresses are ther in this range
we use the same formula the number of zeros so 2 to the power of number of zero which is about
nothing but 200 ah which is nothing but 2to the power of 24-2 to deduct this first and the last IP and we get a number 2,097,150 which is nothing
but a massive massive massive massive network of well even if you compare it with our hotel analogy it is absolutely in possible to control hotel of the
size so similarly in if to controlled network of this size having 2,097,150 devices of host it is very very inefficient and
that is exactly why we will you submnet like you would see in the next video you so again gateway will be anything with 100 and only if it is
part of the same network it can communicate to the gateway and like we already discussed gateway is use to go to a different
network so if this ip adress 100.something needs to go to another address called 99.something it has to first communicate
the gateway and the gateway using the routers and other devices in between will route the packet to 99.something address we will learn about
routers in in the latest part of the series but remember if you have to communicate with a different IP address you have to go through the gateway like an
example of the hotel that when I had to go out of my hotel to visit my friend who is in a different hotel I had to exit through my maingate in my mind my
maingate as part of my hotel and that is why gateway also needs to be part of the same network that makes sense and thats a lot of information I'm sure
I have tried to put it very very very simple but you can always write to me or you can comment on the on the section below if you have any doubts and
we can always discuss and I'm expecting a lot of questions for this video because let's be honest IP address is easy but it's not not straightforward
and it is confusing but once you get the concepts right it's very very easy you can do almost everything in you mind right now it's a time to test your
knowledge look at this IP address and look at that gateway. I want all of you all to take five seconds 10 seconds you can pause this video and tell me if it is valid look at
the gateway may be the gateway is wrong or may be the IP address itself is wrong have a look and tell if it is valid so how do we do that I'm hoping that you already paused
and you have an answer in your mind but let me exlain how to do it first we look at the first octet so we see 133.133 is class D if it is class B
this is the division's is this the division this part has to be seen with the gateway is it same with the gateway no the gateway is in a different network so
it is wrong so if you see this is the first ID this is the last ID on network ID and broadcast id and the valid IP addresses are between these ranges but a network
but our gateway is wrong and it is not valid brilliant now let's look at another example 192.168.100.315 192.168.100.1 pause this video and let me know
if it is valid 192 is a clause C IP address very good if it is class C IP address the division is here – so is it same if you check 192.168.100 6800 is same so
that's all right but is this a valid host what did I say IP addresses can take from 0 to 255 but this 315 is not a valid IP address and iam sure Most of
Them already catch That Write i Thing That's about All the Information I Want to Share in This video go to this cloud map and see if you understud all the concepts
mentioned here Please Feel free to watch this video as many time as you Wants and like I Mentioned in This
Video Helped You or Any of These video Helped You Please Do Not forget to Share with Your Social Media contacts Social Media Platforms Please like our video Subscribe to Our
youtube channel and the more activities you do on our video channel it will promote our video and lot of people get benefit
If You Have Any Doubts like i mentioned do not hesitate to write in to me i will prefer if you comment on this Comment Section below Because
It's Going to help lot of people who come and have the same doubts instead of me have to reply same query i could answer that query ones in the comment
section and all the people can just read it.so Have a Nice Day happy newyear Once Again to all of you all and thank you so much for watching.