Real Domain Names Question?

I took a computer class and when the intstructor was talking about the internet, he said that the domain names you type in are the real and that every domain name has a number

for instance instead of typing straightdope.com into your browser you could type in http://208.100.26.200/ and that is the same because the straightdope.com is just an alias.

My question is I would think there are billions of domain names doesn’t seem like there is enough numbers. Since all have to be formated like that.

How many numbers could you get from that format? (xxx.xxx.xx.xxx)

IPv4 addresses are four bytes long, meaning there are a maximum of 2[sup]32[/sup] = 4,294,967,296 addresses. However, not all of those are useable.

For what it’s worth, the vast majority of those addresses don’t have domain names associated with them; they are used for plain old client computers which are connected to the internet but don’t run any server software. On the other hand, many large web servers host hundreds or even thousands of domains on the same IP address.

Remember too that there’s no requirement for each domain name to resolve to a unique IP address.

In other words, www.BrickerRocks.com might resolve to 190.14.71.5.

And www.BrickerIsTheBest.com, www.BrickerRulz.com, www.BrickerChangedMyLife.info, and www.BrickerPleaseFatherMyBabies.biz may all ALSO resolve to 190.14.71.5.

In addition, domain names for high-traffic sites may resolve to different IPs for load balancing purposes. Some domain servers will try to provide an IP for the closest mirror server (network-wise). Others will cycle through a list at random.

Sure – although it’s fair to say, too, that often load balancing is handled “on the back end” by a virtual IP that manages connections to multiple actual machines. All depends on the requirements of the app, whether you need to preserve session state, etc.

And it’s fair to point out that once you leave the world of web services behind, there are even more wrinkles. An SMTP server trying to send mail to BrickerRocks.com will be querying DNS for the MX record for that domain and the IP address for the MX server.

FWIW, it’s NOT enough. The world should be phasing to IPV6 over the next few years.

Eventually, literal IPs in your URLs will look something like:

http://[2001:0db8:85a3:08d3:1319:8a2e:0370:7344]/

Shorthands exist for the current IPV4 space:

I just hit GoDaddy and registered all of those. How much are you going to give me for them?

I didn’t see this answered and maybe it is obvious, but each possible domain name doesn’t necessarily have an IP associated with it. A basic domain name can be up to 255 characters and it can consist of the English letters a-z, digits 0-9, a dash, and a period – 38 choices. So just considering domain names that are 255 characters long, there are roughly 38[sup]255[/sup] possibilities[sup]*[/sup]. Compare that with friedo’s 2[sup]32[/sup] = 4,294,967,296 IP addresses.

As an aside: How do you represent the total number of possibilities? It would be the sum of 38[sup]n[/sup] where n is between 4 and 255.

  • The actual value is less since there are rules that restrict which characters can be used in various positions. On the other hand, there are standards in progress to support international characters instead of just English letters, so in these cases the actual value is greater.