Web Hosting Talk







View Full Version : How is site on HD actually found?


WonderMonkey
11-02-2002, 11:32 PM
Meaning someone types in a site, say www.Henrynet.com . That name is resolved to an ip and off it goes to a Data Center somewhere. It hits that Data Center and it gets to your server then to the directory where your site is hosted. Sort of....

What basic steps are taken? I am sure I left many things out. I am especially interested from the the point where it gets to your server and finds the directory your site is on. How does that go?

Acronym BOY
11-03-2002, 12:22 AM
type pico /usr/local/apache/conf/httpd.conf and scroll to the bottom, thats where the settings are.

Yes you are missing several steps, including how a name resolves to an IP and things like that, and other basic how the internet works sort of things.

allera
11-03-2002, 12:53 AM
Basically:

- Client requests www.yahoo.com
- Client's DNS cache (ISP or otherwise) doesn't know the IP for www.yahoo.com, so it hits the nameservers specified by yahoo.com and asks for the IP
- The web browser then hits the IP address with the proper request (GET or whatever).
- The web server (Apache, IIS, Zeus, etc) attached to that IP address receives the request and looks at the headers -- finds "www.yahoo.com" as the hostname
- The web server then looks up in its own configuration for the properties attached to "www.yahoo.com." That configuration points the web server to a specific directory and tells the web server how to treat the data in that directory.
- The web server then finds the information the client's request is looking for and sends that information back to the client
- The client's web browser receives that information, processes it, and displays a pretty little web page with lots of ads sprawled all over it

That's pretty much the basics (assuming HTTP 1.1). There's a bunch of little steps all mixed in there, but that's the jist. If I missed something vital, I'm sure someone will correct me. :)

bobcares
11-03-2002, 11:04 AM
Quite a good explaination allera... :)

I generally ask this question when I take interviews.
"What happens when one writes http://www.yahoo.com on the browser"

Everybody generally gets confused with the name servers part. They all say it goes to the name server close to search for the IP... :)

The top level name servers say on which name server the domain is listed. There the query gives the IP and the IP goes to the machine where the domain is located. From there the webserver (apache) does the work

Have a great day :)

regards
amar

WonderMonkey
11-03-2002, 04:31 PM
I've got most of that but at this point:

"- The web server then looks up in its own configuration for the properties attached to "www.yahoo.com." That configuration points the web server to a specific directory and tells the web server how to treat the data in that directory. "

is where I am mostly wondering. I will be running IIS and am wondering where these settings are. My ISP will be giving me a script which will do everything for me and when I get it I will examing it but I want to know now.

allera
11-03-2002, 04:38 PM
Originally posted by WonderMonkey
[web server configuration] is where I am mostly wondering. I will be running IIS and am wondering where these settings are. My ISP will be giving me a script which will do everything for me and when I get it I will examing it but I want to know now.

You'll need to read the documentation for IIS and find out how to configure it. We could start a huge thread on how to configure IIS, but it'd be a waste since there is already documentation out there on how to do it. Cruise around Google for a while and see what you come up with. :)

davidb
11-03-2002, 04:53 PM
of course you forgot a lot about the switches and the routers, but still a great answer :)

trif
11-03-2002, 06:52 PM
Originally posted by bobcares
Quite a good explaination allera... :)
Everybody generally gets confused with the name servers part. They all say it goes to the name server close to search for the IP... :)

The top level name servers say on which name server the domain is listed. There the query gives the IP and the IP goes to the machine where the domain is located. From there the webserver (apache) does the work


Erm, I'm confused. Any DNS query you make does go to your local nameserver.

Are you missing competent people because you don't know what you're talking about?

WonderMonkey
11-03-2002, 07:05 PM
Yeah lets not go into the routers, etc. Explaining each detailed step would take forever. I think I'll just take the advice and go look up specifics to IIS.

Thanks all.

bobcares
11-04-2002, 12:30 AM
Hi!
What is the confusion. Now if the local name server does not have the record what does it do next ?

Amar

Originally posted by trif


Erm, I'm confused. Any DNS query you make does go to your local nameserver.

Are you missing competent people because you don't know what you're talking about?

trif
11-04-2002, 05:49 AM
Originally posted by bobcares
Hi!
What is the confusion. Now if the local name server does not have the record what does it do next ?

Amar



Depending on what it has cached, the local nameserver will go to a root nameserver, a TLD nameserver, and/or a domain nameserver, all of which the browser has no knowledge of (nor needs to). From the perspective of the browser, it queries the local nameserver and receives a reply from the local nameserver. Perhaps your interviewees are not understanding that you want the full particulars of how the DNS system works, and think you just mean what the browser/webserver do. Do you expect them to fill in the routing details too, including a full blown description of BGP and routing policies?

bobcares
11-05-2002, 01:17 AM
That is correct. When I am taking interviews for engineers we expect them to know how name servers work. We do the same questioning.
They start by saying from the ISP's name server. Then my question goes like "say I do not have the domain in my name server". And so on. This way you get to see the extent to which the engineer know the working of internet servers and names...

You are correct wrt to the browser but we expect our engineers to know more, hence the question...

Regards
Amar