Want to protect your cyber security and still get fast solutions? Ask a secure question today.Go Premium

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 408
  • Last Modified:

Math Question: number of possible IP addresses

Somebody told me that the world would soon run out of IP addresses.  But I think there must be a humongous number of available IP addresses out there...

Just exactly how many potential numbers are there?

I think it must be 255 factorial to the fourth power but I could be wrong.... I always sucked at math.

0
hankknight
Asked:
hankknight
6 Solutions
 
Kent OlsenData Warehouse Architect / DBACommented:
Hi hankknight,

roughly 2^32, but there are a significant number of quasi-reserved addresses, like anything that ends in 0.

An IP-4 address is 4 8-bit bytes.  So the address range would be all numbers that can be respresented in 32 bits.



Good Luck,
Kent
0
 
Infinity08Commented:
0
 
Sinoj SebastianCTO & OpenERP Project managerCommented:
look at the table
http://en.wikipedia.org/wiki/IP_address#IPv4_specifics

A Class     126 X 16,777,214   =  2,113,928,964
B Class    16,384 X 65,534      =  1,073,709,056
C Class    2,097,151 X 254      = 532,676,354
                                               ----------------------
                                                     3,720,314,374
0
VIDEO: THE CONCERTO CLOUD FOR HEALTHCARE

Modern healthcare requires a modern cloud. View this brief video to understand how the Concerto Cloud for Healthcare can help your organization.

 
Darr247Commented:
But that's more than what's really ''avaialble.''

3,720,314,374
-  16,581,375 IPs from class A private addresses
-   1,040,400 IPs from class B private addresses
-      65,025 IPs from class C private addresses
-----------------
3,702,627,574 or just 1 IP for every 1.78 persons on earth.

I'm not sure if the 65,025 from the 169.254.xxx.xxx range also reserved by IANA should be included or not.

Some companies are rather wasteful with their IPv4 addresses... using public ranges they've acquired to address devices that will never communicate outside their LAN. But IPv6 should make owning a range of IPs cheaper than buying a router.  Then we can all assign IPs wastefully. ;)
0
 
SunBowCommented:
IMO you go for the wrong answer ("I think it must be") (like " all numbers that can be respresented in 32 bits.") when answer is more of: "2^32, but there are a significant number of quasi-reserved addresses, like anything that ends in 0." I'll initially ditto Kdo, but here is the simpler (rough) answer, the 32 bits are made more convenient to humans (supposedly) by the use of 'octets' (three digit code, but decimal not octal). in dotted notation each up to 256 (0-255) but you cannot count either the zero or the 255 or a handful of others for the purpose of the question (running out of numbers to call home). 256 decimal is 100 hexidecimal, if you permit zero then that is 00-FF in hex notation. Largest number would then be FF.FF.FF.FF or FFFFFFFF or (plus one) a total space of 100000000 (eight zeroes) in hexadecimal. With Windows so predominant, take its 'calc' program, enter 100000000 hex then press decimal and result is 4294967296, adding commas 4,294,967,296 or roughly four billion, similar enough to the results of sinoj and Darr247 in my opinion. Businesses hog a lot of addresses, so the space for real humans is much less.

The rules do not permit either all zeroes or all ones, one for network the other for broadcast. so instead of up to 256 per octet you get trimmed right off to only 254, even before the overheads of the networking equipment such as routers, or for subnetting (further breakdown of any of the 256's) not to mention multicasting and numerous reservations. You cannot do a 10.x.x.x (military) for example, but many will.

255 factorial to the fourth power but I could be wrong

try just erasing the 'factorial' term and you got it, the set of numbers is 256 to the fourth power, and eliminating the all zero or all one condition by octet gives range of 254, or FD.FD.FD.FD (hex).

256 is 2 ^ 8 or 2 ** 8 (two to the eighth power)

FDFDFDFD hex is a decimal 4261281277 in calc, 4,261,281,277 with the commas. Take the initial 4294967296 and subtract 4261281277 and see that 33,686,019 addresses are unavailable before even introducing the other issues for subnetting and networking and special reservation. While that can be like losing a country from the internet, when considering the range available as in the billions, the running out of addresses is not so bad yet. A problem can come when some company reserves addresses in big blocks (major example of class A address you'll not be getting for yourself) and not even bothering to use half of them, and by such a disabling of over half of addresses  available to regular people is much more dramatic impact than the broadcasting omissions.

Any mis-typos are my own and not the fault of MicrSoft's calculator

> Somebody told me that the world would soon run out of IP addresses
> Just exactly how many potential numbers are there?

The numbers are there, not every human needs a personal one, and given the nature of not all of us using it at the same time, DHCP, ability to share addresses, the numbers are there, what is needed is the management of the addresses to reduce, if not eliminate all the waste.
0
 
TalmashCommented:
the world is upgrading to IPv6 standard:
2^128 = 2^(8*16) = (2^8)^16 = ((256)^4)^4 = (256^4)^4

the OLD 2^32 standard, will be used only in some LANs (local nets)

although there are again "available" intervals (subnets, illegal addresses etc..) but this is going to be sufficient for a long time.

few years ago, one of the TCP-IP consortium announced that "with the IPv6, we can give IP address to every particle in the universe.."

tal
0
 
dragonjimCommented:
Yep, with IPv6 there are plenty of addresses.
The concern you've read about deals with the current standard.

Actually, the result is nowhere close to 255 factorial.

An IP address is formatted (xxx.xxx.xxx.xxx) where a xxx generally ranges from 0 to 255. Ignoring loop-backs, broadcasts, and any subneting. The limitation is 2^32.

I'm not sure IPv6 could assign an IP to each particle in the universe, but its definitely enough for our planet, and any future colonization we may endeavor into the foreseeable future.  
0

Featured Post

Free Tool: Subnet Calculator

The subnet calculator helps you design networks by taking an IP address and network mask and returning information such as network, broadcast address, and host range.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now