1

Everybody heared about the IPV4 getting consumed due alot of people in the world need it. But for this purpose, we have NAT, which do atchually port forwording to inside "unreal" ips.. (10.\196.168.).

In this article:

https://www.ccnahub.com/ip-fundamentals/understanding-classless-subnet-mask/

there is the next paragraph:

Because Class A, B, and C default Masks (255.0.0.0, 255.255.0.0, 255.255.255.0) respectively were not an efficient approach to identify Network bits. So, in the the beginning of the 90’s, the default Netmask approach was not efficient due to releasing BIG Blocks of IP Addresses to the Public. Using just default Masks would have made the IP Space consumed long time ago. Therefore, Subnet Masks were evolved to distribute the IP space more efficiently, hence, smaller Blocks can be released to save the rest of the IP Space, which made it possible to have the Internet available to everyone back then.

Which actually saies that subnet is what anwer the consuming IPV4 problem. Can you order my mind please?

With subnet I can devide inside network. but why it have any relation for saving ips?

1
  • Did any answer help you? If so, you should accept the answer so that the question doesn't keep popping up forever, looking for an answer. Alternatively, you could provide and accept your own answer.
    – Ron Maupin
    Commented Aug 17, 2017 at 3:56

4 Answers 4

3

Before 1993 the internet used classful networks, it meant that the full IPv4 scope was divide like this:

  • Class A: from 1.0.0.0 to 127.255.255.255 (netmask 255.0.0.0)

  • Class B: from 128.0.0.0 to 191.255.255.255 (netmask 255.255.0.0)

  • Class C: from 192.0.0.0 to 223.255.255.255 (netmask 255.255.255.0)

For example, in 1988 IBM asked for a range of IP addresses and the assigned range was 9.0.0.0. It is a Class A range, so it went from 9.0.0.0 to 9.255.255.255 (a range of 16777214 hosts). (source: wikipedia)

It's very likely that IBM never uses 16 millions of public addresses, so it becomes a waste of public addressses that can be used by other companies.

Then, in 1993 the Internet Engineering Task Force published RFC 1518 and RFC 1519. These RFCs defined a new concept called Classless Inter Domain Routing. The most important thing of those RFCs is that obsoletes the Classful Network where ranges where associated with classes with fixed netmasks.

So, from 1993 a range as 9.0.0.0 Class A becomes 9.0.0.0/8 and it can be segmented in multiple networks.

For example in 2 networks of more than 8 million hosts each one:

  • 9.0.0.0/9 (from 9.0.0.0 to 9.127.255.255) -Total hosts 8388608
  • 9.128.0.0/9 (from 9.128.0.0 to 9.255.255.255) - Total hosts 8388608

or a mix of different masks, for example::

  • 9.0.0.0/24 (from 9.0.0.0 to 9.0.0.255) - total hosts 256
  • 9.1.0.0/24 (from 9.1.0.0 to 9.1.0.255) - total hosts 256
  • 9.2.0.0/30 (from 9.2.0.0 to 9.2.0.3) - total hosts 4
  • 9.2.0.4/30 (from 9.2.0.4 to 9.2.0.7) -total hosts 4
  • 9.2.0.8/29 (from 9.2.0.8 to 9.2.0.15) - total hosts 8

This system allows to use the ranges in a more efficient way, and be as flexible as possible to avoid the waste of addresses.

2
  • Thanks man. I know this knowledge. but - Now days, the CIDR is activate on private networks (10.*.*.*\192.168.*.*), So there is only one ip which consumed from the IPV4 stock (the public one which the router tallk with the world with it) and the other inside ips in that network, are private and not consumed from the IPV4 stock (because NAT). So why subnetting is now days important for saving ips? Here is NAT for rescue and the subnet is within the NAT (active on private ips.)
    – user34838
    Commented Mar 1, 2017 at 10:20
  • @user34838 Your router has to communicate with another equipment (it means 2 public addresses, multiply it for each residential and business connection). On the ISP there are big routers, and each interface of each router uses a public adddress. Each public server means another public IP. (Google has more than 2 million of servers, Facebook and AWS must be around the same value). Most of the mobile phones use public addresses too.
    – jcbermu
    Commented Mar 1, 2017 at 10:47
2

Classful addressing was a fixed scheme in which a network was strictly defined and with a limited number of networks of fixed size.

there was 128 class A networks, 16,384 class B networks, and 2,097,152 class C networks.

2,097,152 seems a lot, but those are small networks of 253 hosts each, not suitable for many organizations.

Even the class B networks with 65,533 hosts were not big enough for some companies.

On the reverse, a class A network with 16,777,213 usable address is too big for most companies, and some of those network were given to companies that only ever used a small fraction of it.

So you had a very limited number of usable networks, only 3 possible size which most of the time didn't fit the actual need.

To solve those issue and allow allocation of networks tailored to the actual needs, Classless Inter Domain Rouging (CIDR) was introduced.

Basically CIDR allow to create a network of custom size. Networks still have to respect boundaries, since it is based on binary, so in practice you have 32 different sizes, from /1 (/0 is not relevant, 0.0.0.0/0 is the whole Internet) to /32 (a single host).

Subnetting is a different process that consist in cutting a given network in smaller parts to use in different place.

For example, as a Local Internet Registry, my company was assigned a /21 network, and we can do what you want with it:
* We use a subnet, a /24 for out internal use on a site
* we use another /24 subnet on another site
* we assigned another /24 network to a customer
* we assigned a /27 to another customer
* etc...

So this somewhat alleviate the waste of address space by giving a network of appropriate size.

7
  • Thanks man. I know this knowledge. but - Now days, the CIDR is activate on private networks (10.*.*.*\192.168.*.*), So there is only one ip which consumed from the IPV4 stock (the public one which the router tallk with the world with it) and the other inside ips in that network, are private and not consumed from the IPV4 stock (because NAT). So why subnetting is now days important for saving ips? Here is NAT for rescue and the subnet is within the NAT (active on private ips.)
    – user34838
    Commented Mar 1, 2017 at 10:20
  • NAT doesn't solve everything, there's a limited amount of things that can be put behind a single public IP. If you have 2 different emails servers, since they have to listen both on TCP port 25 for incoming emails, you need 2 different public IPs , for example
    – JFL
    Commented Mar 1, 2017 at 10:24
  • For this kind of things we manipulate the network somehow (e.g. port 25 will forword to a server which know by the content of the packet to where it should go, and send it there within the private LAN by ARP or however...).
    – user34838
    Commented Mar 1, 2017 at 10:27
  • then you have a single point of failure that defait the purpose of having a redundant setup.
    – JFL
    Commented Mar 1, 2017 at 10:29
  • So you prefer to waste another IPV4 ip for just having less headach? you selfish ;)
    – user34838
    Commented Mar 1, 2017 at 10:36
0

It has nothing to do with NAT. NAT helps multiple devices with local IPs share the same valid IP to get access to internet. by doing so, limited number of valid IPv4 addresses can support many more people.

subnet is a whole different story. suppose a company needs 32768 IP addresses. A class 'C' subnet holds only 256 IP address(which is not enough). A class 'B' subnet on the other hand holds 65536. if we assign this company a class 'B' subnet we would waste 65536-32768=32768 IP addresses. by using CIDR(Classless Inter-Domain Routing) we can define a subnet like this: 192.168.0.0-192.168.15.256 and the subnet mask of this network is 255.255.128.0 . and therefor we would not waste any IP addresses.

2
  • And what do we care about wasting ips that not consume any ip from the IPV4 stock? what do I care if I have (as a company owner) more 10000000 ips not used?
    – user34838
    Commented Mar 1, 2017 at 10:30
  • if you are the network engineer of a company IT IS your concern not to waste IPs. because IPs cost money. for example if a company needs 3000 IPs, you should not go and buy a class B IP address range. because that would cost a lot of money.
    – ashkan
    Commented May 30, 2017 at 7:32
0

IP addresses are provided by IANA authority.Large companies or ISPs have to buy IP addresses form IANA so to reduce the wastage and provide only the required IP address it has to be subnetted.In case of private IP adresses subnetting is done to divide the networks. NAT maps many private IPs into a single public IP address

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.