Domain names assigned with IP

322 Views Asked by At

I have a doubt on how domain names are assigned to IP address.

According to ICANN evey domain will be assigned to IP address which will be globally accessed.

Lets say there are 3 different domains hosted on 1 reseller account

"example.com"
"example.org"
"againexample.com"

If we query this domains for there IP address, we get same IP address!

How is it possible?

It should be different IP address for each right?

Can anybody explain the login here?

2

There are 2 best solutions below

2
On

When you type in address www.example.com in your browser, a request is sent to DNS (Domain Name Server). DNS Server responds with the IP address associated with that domain.

Your browser then sends a request to the server located at the IP address provided, which then, based on domain requested, server appropriate content.

Basically, on the server side, it is configured as follows:

example.com -> /var/www/example.com/
otherdomain.example -> /var/www/otherdomain.example/
admin.example -> /var/www/admin/

Which means, for the requested domain, serve content from the specified folder. For example if you type example.com you will get site located in /var/www/example.com/.

0
On

You are using shared hosting, what means you will share the server with other websites. If you need a dedicated IP adres, you should ask your webhosting provider to assign several different IP adreses to your websites. Usually you have to pay extra for this.