IP Class / Subnet Mask

surfthegeckosurfthegecko Member Posts: 149
Hi,

I am working my way through ICND1 material and just came across something I wasnt sure on (looks like a bit of a contradiction), I may well find the answer as I continue studying but thought it cant hurt to ask the question.

Anyway......

If you have the three different IP Classes

Class A: 1-126
Class B: 128-191
Class C: 192-223

Class B for instance could be an IP of 172.30.2.50
So I thought this would mean the subnet has to be 255.255.0.0 because Class B allows for 256 x 256 = 65536 Host addresses.

However I just saw somebodies IPConfig screen shot as the following:
172.30.2.50
255.255.255.0

Surely the third octet should be 0

Any explanations would be appreciated.

One slightly confused idividual.

Comments

  • hypnotoadhypnotoad Banned Posts: 915
    Hi,

    If you have the three different IP Classes
    Class A: 1-126
    Class B: 128-191
    Class C: 192-223
    Class B for instance could be an IP of 172.30.2.50
    So I thought this would mean the subnet has to be 255.255.0.0 because Class B allows for 256 x 256 = 65536 Host addresses.
    However I just saw somebodies IPConfig screen shot as the following:
    172.30.2.50
    255.255.255.0
    Surely the third octet should be 0
    Any explanations would be appreciated.

    Nope -- the whole point of the subnet mask is to differentiate networks. The default mask, 255.255.0.0 means the first 16 binary digits are this (class B) Network, the remainding 16 digits are for hosts. Many people don't need 65536 host addresses in one big chunk, so they will further subdivide the class B by making the mask 255.255.255.0, which means that each network only has 256 addresses, but they can have more networks.

    This might come in handy when you are working with a network in your office. Say you want to use the 172.16.0.0 network inside your LAN as your addressing scheme. Instead of using the whole 172.16.0.0 in one big lump, you could subnet it use to make building A be 172.16.1.0, building B be 172.16.2.0, etc. Your subnet mask of 255.255.255.0 keeps all those buildings seperate so each one can have it's own services and policies. They are all part of your class B 172.16.0.0 network, but they have their own sub-networks (hence subnetting) with 256 total available addresses each.
  • surfthegeckosurfthegecko Member Posts: 149
    Although that makes sense, the way classes were explained in a video I watched it seemed the classes are linked to a max range of networks/hosts using subnets:

    A = 16 million hosts / 255.0.0.0
    B = 65K hosts / 255.255.0.0
    C = 254 hosts / 255.255.255.0

    What is the point in using Class A if you are going to greatly reduce the amount of hosts available on the network?

    It just seems to me that you have 3 classes all of which designed to allow greater/fewer networks/hosts but you actually would never want 65K+ hosts on one network?

    Does this not make the whole point of classes redundant.

    Is there nothing stopping you from using one class in 3 different ways:
    192.1.1.1
    255.0.0.0

    or

    192.1.1.1
    255.255.0.0

    or

    192.1.1.1
    255.255.255.0

    Maybe im completely missing something here, more than likely.
  • hypnotoadhypnotoad Banned Posts: 915
    Although that makes sense, the way classes were explained in a video I watched it seemed the classes are linked to a max range of networks/hosts using subnets:

    A = 16 million hosts / 255.0.0.0
    B = 65K hosts / 255.255.0.0
    C = 254 hosts / 255.255.255.0

    What is the point in using Class A if you are going to greatly reduce the amount of hosts available on the network?

    It just seems to me that you have 3 classes all of which designed to allow greater/fewer networks/hosts but you actually would never want 65K+ hosts on one network?

    Does this not make the whole point of classes redundant.

    Is there nothing stopping you from using one class in 3 different ways:
    192.1.1.1
    255.0.0.0
    or
    192.1.1.1
    255.255.0.0
    or
    192.1.1.1
    255.255.255.0
    Maybe im completely missing something here, more than likely.

    Wasting private addresses isn't a big deal, since new subnets can be added fairly easily. However, the public address space is different (the same in theory, but conservation is more important)...

    Say I'm an ISP and my network is 142.24.0.0 with 255.255.0.0 subnet mask that i want to use on my clients. For my clients, I have to distribute IP addresses. Some clients need up to 32 addresses for their web servers, email servers, etc. Some clients only need 1 IP for their home router.

    If I subnet my 142.24.0.0 network into a network block size of 1 (for my point-to-point connections between my ISP's router and the customer's house), I will use a subnet mask of 255.255.255.254 -- so i dont waste any addresses. Each network will be exactly 2 IPs in size. This doesn't give them any room to plug in extra devices, but it allows me to service thousands of houses.

    My business clients want blocks of 32 addresses at a time. So for them, we use the mask 255.255.255.224. We give them that block, and they put their router on 142.24.52.1 (for example), their email server on 142.24.52.2, their web server on 142.24.52.3...all the way up to 142.24.52.30 -- the last usable address. 142.24.52.32-63 network can then go to another client.

    The example above was VLSM (Variable Length Subnet Masking). That is when subnetting gets fun because you can get more granular with dividing your network. The whole goal of subnetting is to find a balance between the number of networks and the number of hosts, so that you don't waste addresses but provide enough room for expansion.

    To answer your examples, there is nothing stopping you from using any of those 3 schemes. The first one is known as "supernetting" and is rare. It is covered in ICND2.
  • EdTheLadEdTheLad Member Posts: 2,111 ■■■■□□□□□□
    hypnotoad wrote: »
    To answer your examples, there is nothing stopping you from using any of those 3 schemes. The first one is known as "supernetting" and is rare. It is covered in ICND2.

    Try and deploy Rip with a supernet address.
    Networking, sometimes i love it, mostly i hate it.Its all about the $$$$
  • surfthegeckosurfthegecko Member Posts: 149
    Thanks hypnotoad, that makes a bit more sense.

    I suppose im used to looking at my own 192 home range and always seeing 255.255.255.0, so found it bizarre when I saw a written concept of using class a with 255.0.0.0 and then seeing a screenshot of somebody elses pc with a 172.x.x.x / 255.255.255.0.

    I guess it will all become clearer when I watch some more training videos in ICND1 and then onto ICND2.

    Thanks for your help.
Sign In or Register to comment.